aboutsummaryrefslogtreecommitdiffstats
path: root/integrity-monitor/src/main
diff options
context:
space:
mode:
Diffstat (limited to 'integrity-monitor/src/main')
-rw-r--r--integrity-monitor/src/main/java/org/onap/policy/common/im/IntegrityMonitor.java4
-rw-r--r--integrity-monitor/src/main/resources/META-INF/persistenceIM.xml (renamed from integrity-monitor/src/main/resources/META-INF/persistence.xml)0
2 files changed, 4 insertions, 0 deletions
diff --git a/integrity-monitor/src/main/java/org/onap/policy/common/im/IntegrityMonitor.java b/integrity-monitor/src/main/java/org/onap/policy/common/im/IntegrityMonitor.java
index 3cb708e2..d12a9bde 100644
--- a/integrity-monitor/src/main/java/org/onap/policy/common/im/IntegrityMonitor.java
+++ b/integrity-monitor/src/main/java/org/onap/policy/common/im/IntegrityMonitor.java
@@ -44,6 +44,7 @@ import javax.persistence.LockModeType;
import javax.persistence.Persistence;
import javax.persistence.Query;
import org.apache.commons.lang3.StringUtils;
+import org.eclipse.persistence.config.PersistenceUnitProperties;
import org.onap.policy.common.im.jmx.ComponentAdmin;
import org.onap.policy.common.im.jmx.ComponentAdminMBean;
import org.onap.policy.common.im.jmx.JmxAgentConnection;
@@ -229,6 +230,9 @@ public class IntegrityMonitor {
//
// Create the entity manager factory
//
+ if (!properties.containsKey(PersistenceUnitProperties.ECLIPSELINK_PERSISTENCE_XML)) {
+ properties.setProperty(PersistenceUnitProperties.ECLIPSELINK_PERSISTENCE_XML, "META-INF/persistenceIM.xml");
+ }
emf = Persistence.createEntityManagerFactory(getPersistenceUnit(), properties);
//
// Did it get created?
diff --git a/integrity-monitor/src/main/resources/META-INF/persistence.xml b/integrity-monitor/src/main/resources/META-INF/persistenceIM.xml
index 7aff9219..7aff9219 100644
--- a/integrity-monitor/src/main/resources/META-INF/persistence.xml
+++ b/integrity-monitor/src/main/resources/META-INF/persistenceIM.xml