Merge "New controller support from BRMSGW"
diff --git a/BRMSGateway/config.properties b/BRMSGateway/config.properties
index fa5f919..b17804b 100644
--- a/BRMSGateway/config.properties
+++ b/BRMSGateway/config.properties
@@ -47,13 +47,11 @@
policyKeyID = controller
## GroupNames can be comma separated values.
-groupNames = default, vFW , vDNS
+groupNames = default, amsterdam
default.groupID = org.onap.policy-engine
default.artifactID = drlPDPGroup
-vFW.groupID= org.onap.policy-engine.drools.vFW
-vFW.artifactID= policy-vFW-rules
-vDNS.groupID= org.onap.policy-engine.drools.vDNS
-vDNS.artifactID= policy-vDNS-rules
+amsterdam.groupID= org.onap.policy-engine.drools.amsterdam
+amsterdam.artifactID= policy-amsterdam-rules
#Integrity Monitor values
#database driver for Integrity Monitor
diff --git a/BRMSGateway/dependency.json b/BRMSGateway/dependency.json
index a883cc9..f758db0 100644
--- a/BRMSGateway/dependency.json
+++ b/BRMSGateway/dependency.json
@@ -1,33 +1,102 @@
{
- "dependencies": {
- "default": [{
- "groupId": "org.onap.policy.drools-applications",
- "artifactId": "demo",
- "version": "1.1.0-SNAPSHOT"
- }, {
- "groupId": "org.onap.policy.drools-applications",
- "artifactId": "events",
- "version": "1.1.0-SNAPSHOT"
- }, {
- "groupId": "org.onap.policy.drools-applications",
- "artifactId": "rest",
- "version": "1.1.0-SNAPSHOT"
- }, {
- "groupId": "org.onap.policy.drools-applications",
- "artifactId": "appc",
- "version": "1.1.0-SNAPSHOT"
- }, {
- "groupId": "org.onap.policy.drools-applications",
- "artifactId": "aai",
- "version": "1.1.0-SNAPSHOT"
- }, {
- "groupId": "org.onap.policy.drools-applications",
- "artifactId": "mso",
- "version": "1.1.0-SNAPSHOT"
- }, {
- "groupId": "org.onap.policy.drools-applications",
- "artifactId": "trafficgenerator",
- "version": "1.1.0-SNAPSHOT"
- }]
- }
+ "dependencies": {
+ "default": [{
+ "groupId": "org.onap.policy.drools-applications",
+ "artifactId": "demo",
+ "version": "1.1.0-SNAPSHOT"
+ }, {
+ "groupId": "org.onap.policy.drools-applications",
+ "artifactId": "events",
+ "version": "1.1.0-SNAPSHOT"
+ }, {
+ "groupId": "org.onap.policy.drools-applications",
+ "artifactId": "rest",
+ "version": "1.1.0-SNAPSHOT"
+ }, {
+ "groupId": "org.onap.policy.drools-applications",
+ "artifactId": "appc",
+ "version": "1.1.0-SNAPSHOT"
+ }, {
+ "groupId": "org.onap.policy.drools-applications",
+ "artifactId": "aai",
+ "version": "1.1.0-SNAPSHOT"
+ }, {
+ "groupId": "org.onap.policy.drools-applications",
+ "artifactId": "mso",
+ "version": "1.1.0-SNAPSHOT"
+ }, {
+ "groupId": "org.onap.policy.drools-applications",
+ "artifactId": "trafficgenerator",
+ "version": "1.1.0-SNAPSHOT"
+ }],
+ "amsterdam": [{
+ "groupId": "org.onap.policy.drools-applications",
+ "artifactId": "events",
+ "version": "1.1.0-SNAPSHOT"
+ }, {
+ "groupId": "org.onap.policy.drools-applications",
+ "artifactId": "appc",
+ "version": "1.1.0-SNAPSHOT"
+ }, {
+ "groupId": "org.onap.policy.drools-applications",
+ "artifactId": "appclcm",
+ "version": "1.1.0-SNAPSHOT"
+ }, {
+ "groupId": "org.onap.policy.drools-applications",
+ "artifactId": "vfc",
+ "version": "1.1.0-SNAPSHOT"
+ }, {
+ "groupId": "org.onap.policy.drools-applications",
+ "artifactId": "so",
+ "version": "1.1.0-SNAPSHOT"
+ }, {
+ "groupId": "org.onap.policy.drools-applications",
+ "artifactId": "aai",
+ "version": "1.1.0-SNAPSHOT"
+ }, {
+ "groupId": "org.onap.policy.drools-applications",
+ "artifactId": "sdc",
+ "version": "1.1.0-SNAPSHOT"
+ }, {
+ "groupId": "org.onap.policy.drools-applications",
+ "artifactId": "trafficgenerator",
+ "version": "1.1.0-SNAPSHOT"
+ }, {
+ "groupId": "org.onap.policy.drools-applications",
+ "artifactId": "eventmanager",
+ "version": "1.1.0-SNAPSHOT"
+ }, {
+ "groupId": "org.onap.policy.drools-applications",
+ "artifactId": "guard",
+ "version": "1.1.0-SNAPSHOT"
+ }, {
+ "groupId": "org.onap.policy.drools-applications",
+ "artifactId": "actorServiceProvider",
+ "version": "1.1.0-SNAPSHOT"
+ }, {
+ "groupId": "org.onap.policy.drools-applications",
+ "artifactId": "actor.appc",
+ "version": "1.1.0-SNAPSHOT"
+ }, {
+ "groupId": "org.onap.policy.drools-applications",
+ "artifactId": "actor.appclcm",
+ "version": "1.1.0-SNAPSHOT"
+ }, {
+ "groupId": "org.onap.policy.drools-applications",
+ "artifactId": "actor.so",
+ "version": "1.1.0-SNAPSHOT"
+ }, {
+ "groupId": "org.onap.policy.drools-applications",
+ "artifactId": "actor.vfc",
+ "version": "1.1.0-SNAPSHOT"
+ }, {
+ "groupId": "org.onap.policy.drools-applications",
+ "artifactId": "policy-yaml",
+ "version": "1.1.0-SNAPSHOT"
+ }, {
+ "groupId": "com.att.research.xacml",
+ "artifactId": "xacml-pdp",
+ "version": "1.0.0"
+ }]
+ }
}
\ No newline at end of file
diff --git a/BRMSGateway/src/main/java/org/onap/policy/brmsInterface/BRMSPush.java b/BRMSGateway/src/main/java/org/onap/policy/brmsInterface/BRMSPush.java
index 6e8588a..266e090 100644
--- a/BRMSGateway/src/main/java/org/onap/policy/brmsInterface/BRMSPush.java
+++ b/BRMSGateway/src/main/java/org/onap/policy/brmsInterface/BRMSPush.java
@@ -109,6 +109,7 @@
private static final String[] GOALS = { "clean", "deploy" };
private static final String DEFAULT_VERSION = "1.1.0-SNAPSHOT";
private static final String DEPENDENCY_FILE = "dependency.json";
+ private static final String BRMSPERSISTENCE = "brmsEclipselink.persistencexml";
private static Map<String, String> modifiedGroups = new HashMap<>();
private static IntegrityMonitor im;
@@ -188,8 +189,10 @@
} catch (Exception e) {
LOGGER.error("Error starting BackUpMonitor: " + e);
}
- if(!config.containsKey(PersistenceUnitProperties.ECLIPSELINK_PERSISTENCE_XML)){
+ if(!config.containsKey(BRMSPERSISTENCE)){
config.setProperty(PersistenceUnitProperties.ECLIPSELINK_PERSISTENCE_XML, "META-INF/persistenceBRMS.xml");
+ } else {
+ config.setProperty(PersistenceUnitProperties.ECLIPSELINK_PERSISTENCE_XML, config.getProperty(BRMSPERSISTENCE,"META-INF/persistenceBRMS.xml"));
}
EntityManagerFactory emf = Persistence.createEntityManagerFactory("BRMSGW", config);
em = emf.createEntityManager();
diff --git a/BRMSGateway/src/test/resources/config.properties b/BRMSGateway/src/test/resources/config.properties
index 4f9e013..8c46ec2 100644
--- a/BRMSGateway/src/test/resources/config.properties
+++ b/BRMSGateway/src/test/resources/config.properties
@@ -65,7 +65,7 @@
#database password for Integrity Monitor
javax.persistence.jdbc.password=
#persistence xml
-eclipselink.persistencexml=META-INF/persistenceBRMStest.xml
+brmsEclipselink.persistencexml=META-INF/persistenceBRMStest.xml
#resource name
RESOURCE_NAME=site_1.brmsgw_1
#***Properties for IntegrityMonitor integration defined in IntegrityMonitorProperties.java***
diff --git a/packages/base/src/files/install/servers/brmsgw/config.properties b/packages/base/src/files/install/servers/brmsgw/config.properties
index 9e95ed7..f56e87c 100644
--- a/packages/base/src/files/install/servers/brmsgw/config.properties
+++ b/packages/base/src/files/install/servers/brmsgw/config.properties
@@ -54,14 +54,12 @@
policyKeyID = controller
## GroupNames can be comma separated values.
-groupNames = default, vFW , vDNS
+groupNames = default, amsterdam
default.groupID = ${{groupID}}
default.artifactID = ${{artifactID}}
-vFW.groupID= ${{VFW_GROUP_ID}}
-vFW.artifactID= ${{VFW_ARTIFACT_ID}}
-vDNS.groupID= ${{VDNS_GROUP_ID}}
-vDNS.artifactID= ${{VDNS_ARTIFACT_ID}}
+amsterdam.groupID= ${{AMSTERDAM_GROUP_ID}}
+amsterdam.artifactID= ${{AMSTERDAM_ARTIFACT_ID}}
#Integrity Monitor values
#database driver for Integrity Monitor
diff --git a/packages/base/src/files/install/servers/brmsgw/dependency.json b/packages/base/src/files/install/servers/brmsgw/dependency.json
index 9c25c74..ffd368e 100644
--- a/packages/base/src/files/install/servers/brmsgw/dependency.json
+++ b/packages/base/src/files/install/servers/brmsgw/dependency.json
@@ -28,6 +28,75 @@
"groupId": "org.onap.policy.drools-applications",
"artifactId": "trafficgenerator",
"version": "${{BRMS_DEPENDENCY_VERSION}}"
- }]
- }
+ }],
+ "amsterdam": [{
+ "groupId": "org.onap.policy.drools-applications",
+ "artifactId": "events",
+ "version": "${{BRMS_DEPENDENCY_VERSION}}"
+ }, {
+ "groupId": "org.onap.policy.drools-applications",
+ "artifactId": "appc",
+ "version": "${{BRMS_DEPENDENCY_VERSION}}"
+ }, {
+ "groupId": "org.onap.policy.drools-applications",
+ "artifactId": "appclcm",
+ "version": "${{BRMS_DEPENDENCY_VERSION}}"
+ }, {
+ "groupId": "org.onap.policy.drools-applications",
+ "artifactId": "vfc",
+ "version": "${{BRMS_DEPENDENCY_VERSION}}"
+ }, {
+ "groupId": "org.onap.policy.drools-applications",
+ "artifactId": "so",
+ "version": "${{BRMS_DEPENDENCY_VERSION}}"
+ }, {
+ "groupId": "org.onap.policy.drools-applications",
+ "artifactId": "aai",
+ "version": "${{BRMS_DEPENDENCY_VERSION}}"
+ }, {
+ "groupId": "org.onap.policy.drools-applications",
+ "artifactId": "sdc",
+ "version": "${{BRMS_DEPENDENCY_VERSION}}"
+ }, {
+ "groupId": "org.onap.policy.drools-applications",
+ "artifactId": "trafficgenerator",
+ "version": "${{BRMS_DEPENDENCY_VERSION}}"
+ }, {
+ "groupId": "org.onap.policy.drools-applications",
+ "artifactId": "eventmanager",
+ "version": "${{BRMS_DEPENDENCY_VERSION}}"
+ }, {
+ "groupId": "org.onap.policy.drools-applications",
+ "artifactId": "guard",
+ "version": "${{BRMS_DEPENDENCY_VERSION}}"
+ }, {
+ "groupId": "org.onap.policy.drools-applications",
+ "artifactId": "actorServiceProvider",
+ "version": "${{BRMS_DEPENDENCY_VERSION}}"
+ }, {
+ "groupId": "org.onap.policy.drools-applications",
+ "artifactId": "actor.appc",
+ "version": "${{BRMS_DEPENDENCY_VERSION}}"
+ }, {
+ "groupId": "org.onap.policy.drools-applications",
+ "artifactId": "actor.appclcm",
+ "version": "${{BRMS_DEPENDENCY_VERSION}}"
+ }, {
+ "groupId": "org.onap.policy.drools-applications",
+ "artifactId": "actor.so",
+ "version": "${{BRMS_DEPENDENCY_VERSION}}"
+ }, {
+ "groupId": "org.onap.policy.drools-applications",
+ "artifactId": "actor.vfc",
+ "version": "${{BRMS_DEPENDENCY_VERSION}}"
+ }, {
+ "groupId": "org.onap.policy.drools-applications",
+ "artifactId": "policy-yaml",
+ "version": "${{BRMS_DEPENDENCY_VERSION}}"
+ }, {
+ "groupId": "com.att.research.xacml",
+ "artifactId": "xacml-pdp",
+ "version": "1.0.0"
+ }]
+ }
}
\ No newline at end of file
diff --git a/packages/install/src/files/brmsgw.conf b/packages/install/src/files/brmsgw.conf
index 36cf414..2c91ff4 100644
--- a/packages/install/src/files/brmsgw.conf
+++ b/packages/install/src/files/brmsgw.conf
@@ -28,10 +28,8 @@
groupID=org.onap.policy-engine
artifactID=drlPDPGroup
-VFW_GROUP_ID=org.onap.policy-engine.drools.vFW
-VFW_ARTIFACT_ID=policy-vFW-rules
-VDNS_GROUP_ID=org.onap.policy-engine.drools.vDNS
-VDNS_ARTIFACT_ID=policy-vDNS-rules
+AMSTERDAM_GROUP_ID=org.onap.policy-engine.drools.amsterdam
+AMSTERDAM_ARTIFACT_ID=policy-amsterdam-rules
# the java property is RESOURCE_NAME (uppercase), but the conf parameter is lowercase
resource_name=brmsgw_1