rename rule template from beijing to casablanca 91/58791/2
authorJim Hahn <jrh3@att.com>
Thu, 2 Aug 2018 20:40:41 +0000 (16:40 -0400)
committerJim Hahn <jrh3@att.com>
Fri, 3 Aug 2018 17:39:58 +0000 (13:39 -0400)
Changed assertTrue to assertEquals in CasablancaFeatureTest.

Change-Id: I3bec009ddde2f10468575b4b7bf9c08c24748aae
Issue-ID: POLICY-955
Signed-off-by: Jim Hahn <jrh3@att.com>
41 files changed:
controlloop/common/controller-beijing/.gitignore [deleted file]
controlloop/common/controller-casablanca/.gitignore [new file with mode: 0644]
controlloop/common/controller-casablanca/pom.xml [moved from controlloop/common/controller-beijing/pom.xml with 96% similarity]
controlloop/common/controller-casablanca/src/main/resources/META-INF/kmodule.xml [moved from controlloop/common/controller-beijing/src/main/resources/META-INF/kmodule.xml with 96% similarity]
controlloop/common/feature-controlloop-beijing/src/main/resources/META-INF/services/org.onap.policy.drools.features.PolicyEngineFeatureAPI [deleted file]
controlloop/common/feature-controlloop-casablanca/pom.xml [moved from controlloop/common/feature-controlloop-beijing/pom.xml with 98% similarity]
controlloop/common/feature-controlloop-casablanca/src/assembly/assemble_zip.xml [moved from controlloop/common/feature-controlloop-beijing/src/assembly/assemble_zip.xml with 95% similarity]
controlloop/common/feature-controlloop-casablanca/src/main/feature/config/casablanca-controller.properties [moved from controlloop/common/feature-controlloop-beijing/src/main/feature/config/beijing-controller.properties with 98% similarity]
controlloop/common/feature-controlloop-casablanca/src/main/java/org/onap/policy/drools/apps/controlloop/feature/casablanca/CasablancaFeature.java [moved from controlloop/common/feature-controlloop-beijing/src/main/java/org/onap/policy/drools/apps/controlloop/feature/beijing/BeijingFeature.java with 85% similarity]
controlloop/common/feature-controlloop-casablanca/src/main/resources/META-INF/services/org.onap.policy.drools.features.PolicyEngineFeatureAPI [new file with mode: 0644]
controlloop/common/feature-controlloop-casablanca/src/test/java/org/onap/policy/drools/apps/controlloop/feature/casablanca/CasablancaFeatureTest.java [moved from controlloop/common/feature-controlloop-beijing/src/test/java/org/onap/policy/drools/apps/controlloop/feature/beijing/BeijingFeatureTest.java with 77% similarity]
controlloop/common/pom.xml
controlloop/packages/apps-controlloop/pom.xml
controlloop/packages/apps-controlloop/src/files/apps-controlloop-installer
controlloop/packages/basex-controlloop/src/files/bin/create-cl-casablanca [moved from controlloop/packages/basex-controlloop/src/files/bin/create-cl-beijing with 98% similarity]
controlloop/packages/basex-controlloop/src/files/bin/push-policies-casablanca [moved from controlloop/packages/basex-controlloop/src/files/bin/push-policies-beijing with 99% similarity]
controlloop/templates/archetype-cl-casablanca/pom.xml [moved from controlloop/templates/archetype-cl-beijing/pom.xml with 95% similarity]
controlloop/templates/archetype-cl-casablanca/src/main/resources/META-INF/maven/archetype-metadata.xml [moved from controlloop/templates/archetype-cl-beijing/src/main/resources/META-INF/maven/archetype-metadata.xml with 100% similarity]
controlloop/templates/archetype-cl-casablanca/src/main/resources/archetype-resources/pom.xml [moved from controlloop/templates/archetype-cl-beijing/src/main/resources/archetype-resources/pom.xml with 98% similarity]
controlloop/templates/archetype-cl-casablanca/src/main/resources/archetype-resources/src/main/config/VoLTE.yaml [moved from controlloop/templates/archetype-cl-beijing/src/main/resources/archetype-resources/src/main/config/VoLTE.yaml with 100% similarity]
controlloop/templates/archetype-cl-casablanca/src/main/resources/archetype-resources/src/main/config/__artifactId__-controller.properties [moved from controlloop/templates/archetype-cl-beijing/src/main/resources/archetype-resources/src/main/config/__artifactId__-controller.properties with 100% similarity]
controlloop/templates/archetype-cl-casablanca/src/main/resources/archetype-resources/src/main/config/__artifactId__-controller.rest.json [moved from controlloop/templates/archetype-cl-beijing/src/main/resources/archetype-resources/src/main/config/__artifactId__-controller.rest.json with 100% similarity]
controlloop/templates/archetype-cl-casablanca/src/main/resources/archetype-resources/src/main/config/appc.lcm.success.json [moved from controlloop/templates/archetype-cl-beijing/src/main/resources/archetype-resources/src/main/config/appc.lcm.success.json with 100% similarity]
controlloop/templates/archetype-cl-casablanca/src/main/resources/archetype-resources/src/main/config/appc.legacy.success.json [moved from controlloop/templates/archetype-cl-beijing/src/main/resources/archetype-resources/src/main/config/appc.legacy.success.json with 100% similarity]
controlloop/templates/archetype-cl-casablanca/src/main/resources/archetype-resources/src/main/config/dcae.vcpe.abatement.json [moved from controlloop/templates/archetype-cl-beijing/src/main/resources/archetype-resources/src/main/config/dcae.vcpe.abatement.json with 100% similarity]
controlloop/templates/archetype-cl-casablanca/src/main/resources/archetype-resources/src/main/config/dcae.vcpe.onset.json [moved from controlloop/templates/archetype-cl-beijing/src/main/resources/archetype-resources/src/main/config/dcae.vcpe.onset.json with 100% similarity]
controlloop/templates/archetype-cl-casablanca/src/main/resources/archetype-resources/src/main/config/dcae.vdns.onset.json [moved from controlloop/templates/archetype-cl-beijing/src/main/resources/archetype-resources/src/main/config/dcae.vdns.onset.json with 100% similarity]
controlloop/templates/archetype-cl-casablanca/src/main/resources/archetype-resources/src/main/config/dcae.vfw.onset.json [moved from controlloop/templates/archetype-cl-beijing/src/main/resources/archetype-resources/src/main/config/dcae.vfw.onset.json with 100% similarity]
controlloop/templates/archetype-cl-casablanca/src/main/resources/archetype-resources/src/main/config/dcae.volte.onset.json [moved from controlloop/templates/archetype-cl-beijing/src/main/resources/archetype-resources/src/main/config/dcae.volte.onset.json with 100% similarity]
controlloop/templates/archetype-cl-casablanca/src/main/resources/archetype-resources/src/main/config/so.success.json [moved from controlloop/templates/archetype-cl-beijing/src/main/resources/archetype-resources/src/main/config/so.success.json with 100% similarity]
controlloop/templates/archetype-cl-casablanca/src/main/resources/archetype-resources/src/main/config/vCPE.yaml [moved from controlloop/templates/archetype-cl-beijing/src/main/resources/archetype-resources/src/main/config/vCPE.yaml with 100% similarity]
controlloop/templates/archetype-cl-casablanca/src/main/resources/archetype-resources/src/main/config/vDNS.yaml [moved from controlloop/templates/archetype-cl-beijing/src/main/resources/archetype-resources/src/main/config/vDNS.yaml with 100% similarity]
controlloop/templates/archetype-cl-casablanca/src/main/resources/archetype-resources/src/main/config/vFW.yaml [moved from controlloop/templates/archetype-cl-beijing/src/main/resources/archetype-resources/src/main/config/vFW.yaml with 100% similarity]
controlloop/templates/archetype-cl-casablanca/src/main/resources/archetype-resources/src/main/config/vcpe.brmsgw.params.json [moved from controlloop/templates/archetype-cl-beijing/src/main/resources/archetype-resources/src/main/config/vcpe.brmsgw.params.json with 100% similarity]
controlloop/templates/archetype-cl-casablanca/src/main/resources/archetype-resources/src/main/config/vdns.brmsgw.params.json [moved from controlloop/templates/archetype-cl-beijing/src/main/resources/archetype-resources/src/main/config/vdns.brmsgw.params.json with 100% similarity]
controlloop/templates/archetype-cl-casablanca/src/main/resources/archetype-resources/src/main/config/vfw.brmsgw.params.json [moved from controlloop/templates/archetype-cl-beijing/src/main/resources/archetype-resources/src/main/config/vfw.brmsgw.params.json with 100% similarity]
controlloop/templates/archetype-cl-casablanca/src/main/resources/archetype-resources/src/main/config/volte.brmsgw.params.json [moved from controlloop/templates/archetype-cl-beijing/src/main/resources/archetype-resources/src/main/config/volte.brmsgw.params.json with 100% similarity]
controlloop/templates/archetype-cl-casablanca/src/main/resources/archetype-resources/src/main/resources/META-INF/kmodule.xml [moved from controlloop/templates/archetype-cl-beijing/src/main/resources/archetype-resources/src/main/resources/META-INF/kmodule.xml with 96% similarity]
controlloop/templates/archetype-cl-casablanca/src/main/resources/archetype-resources/src/main/resources/__closedLoopControlName__.drl [moved from controlloop/templates/archetype-cl-beijing/src/main/resources/archetype-resources/src/main/resources/__closedLoopControlName__.drl with 100% similarity]
controlloop/templates/archetype-cl-casablanca/src/test/resources/projects/basic/archetype.properties [moved from controlloop/templates/archetype-cl-beijing/src/test/resources/projects/basic/archetype.properties with 100% similarity]
controlloop/templates/pom.xml

diff --git a/controlloop/common/controller-beijing/.gitignore b/controlloop/common/controller-beijing/.gitignore
deleted file mode 100644 (file)
index 2e1b114..0000000
+++ /dev/null
@@ -1 +0,0 @@
-src/main/resources/beijing.drl
diff --git a/controlloop/common/controller-casablanca/.gitignore b/controlloop/common/controller-casablanca/.gitignore
new file mode 100644 (file)
index 0000000..f4e9656
--- /dev/null
@@ -0,0 +1 @@
+src/main/resources/casablanca.drl
         <version>1.3.0-SNAPSHOT</version>
     </parent>
 
-    <artifactId>controller-beijing</artifactId>
+    <artifactId>controller-casablanca</artifactId>
     <packaging>kjar</packaging>
 
     <name>${project.artifactId}</name>
-    <description>Beijing Experimental Controller</description>
+    <description>Casablanca Experimental Controller</description>
 
     <properties>
         <maven.compiler.source>1.8</maven.compiler.source>
@@ -62,9 +62,9 @@
                         </goals>
                         <configuration>
                             <sourceFile>
-                                ../../templates/archetype-cl-beijing/src/main/resources/archetype-resources/src/main/resources/__closedLoopControlName__.drl
+                                ../../templates/archetype-cl-casablanca/src/main/resources/archetype-resources/src/main/resources/__closedLoopControlName__.drl
                             </sourceFile>
-                            <destinationFile>src/main/resources/beijing.drl</destinationFile>
+                            <destinationFile>src/main/resources/casablanca.drl</destinationFile>
                         </configuration>
                     </execution>
                 </executions>
diff --git a/controlloop/common/feature-controlloop-beijing/src/main/resources/META-INF/services/org.onap.policy.drools.features.PolicyEngineFeatureAPI b/controlloop/common/feature-controlloop-beijing/src/main/resources/META-INF/services/org.onap.policy.drools.features.PolicyEngineFeatureAPI
deleted file mode 100644 (file)
index 9343948..0000000
+++ /dev/null
@@ -1 +0,0 @@
-org.onap.policy.drools.apps.controlloop.feature.beijing.BeijingFeature
         <version>1.3.0-SNAPSHOT</version>
     </parent>
 
-    <artifactId>feature-controlloop-beijing</artifactId>
+    <artifactId>feature-controlloop-casablanca</artifactId>
 
     <description>
-        Load Experimental Beijing Control Loop Use Cases Controller as a feature.
+        Load Experimental Casablanca Control Loop Use Cases Controller as a feature.
     </description>
 
     <properties>
@@ -24,7 +24,7 @@
        xmlns="http://maven.apache.org/plugins/maven-assembly-plugin/assembly/1.1.0"
        xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
        xsi:schemaLocation="http://maven.apache.org/plugins/maven-assembly-plugin/assembly/1.1.0 http://maven.apache.org/xsd/assembly-1.1.0.xsd">
-       <id>feature-controlloop-beijing-package</id>
+       <id>feature-controlloop-casablanca-package</id>
        <formats>
                <format>zip</format>
        </formats>
@@ -36,7 +36,7 @@
                        <directory>target</directory>
                        <outputDirectory>lib/feature</outputDirectory>
                        <includes>
-                               <include>feature-controlloop-beijing-${project.version}.jar</include>
+                               <include>feature-controlloop-casablanca-${project.version}.jar</include>
                        </includes>
                </fileSet>
                <fileSet>
@@ -18,7 +18,7 @@
 # ============LICENSE_END=========================================================
 ###
 
-controller.name=beijing
+controller.name=casablanca
 
 ueb.source.topics=${{PDPD_CONFIGURATION_TOPIC}},${{DCAE_TOPIC}},APPC-CL,APPC-LCM-WRITE
 
@@ -71,5 +71,5 @@ ueb.sink.topics.POLICY-CL-MGT.events=org.onap.policy.controlloop.VirtualControlL
 ueb.sink.topics.POLICY-CL-MGT.events.custom.gson=org.onap.policy.controlloop.util.Serialization,gsonPretty
 
 rules.groupId=${project.groupId}
-rules.artifactId=controller-beijing
+rules.artifactId=controller-casablanca
 rules.version=${project.version}
  * ============LICENSE_END=========================================================
  */
 
-package org.onap.policy.drools.apps.controlloop.feature.beijing;
+package org.onap.policy.drools.apps.controlloop.feature.casablanca;
 
 import org.onap.policy.drools.features.PolicyEngineFeatureAPI;
 
 /**
- * Beijing installation as a feature saves time
- * loading the Beijing controller at runtime over the
+ * Casablanca installation as a feature saves time
+ * loading the Casablanca controller at runtime over the
  * usual installation from nexus.  It also reduces
  * potential for errors in the pom.xml generated in
  * the brmsgw side.
@@ -36,7 +36,7 @@ import org.onap.policy.drools.features.PolicyEngineFeatureAPI;
  * functionality
  *
  */
-public class BeijingFeature implements PolicyEngineFeatureAPI {
+public class CasablancaFeature implements PolicyEngineFeatureAPI {
 
     public static final int SEQNO = 1000;
 
diff --git a/controlloop/common/feature-controlloop-casablanca/src/main/resources/META-INF/services/org.onap.policy.drools.features.PolicyEngineFeatureAPI b/controlloop/common/feature-controlloop-casablanca/src/main/resources/META-INF/services/org.onap.policy.drools.features.PolicyEngineFeatureAPI
new file mode 100644 (file)
index 0000000..5252ca1
--- /dev/null
@@ -0,0 +1 @@
+org.onap.policy.drools.apps.controlloop.feature.casablanca.CasablancaFeature
  * limitations under the License.
  * ============LICENSE_END=========================================================
  */
-package org.onap.policy.drools.apps.controlloop.feature.beijing;
+package org.onap.policy.drools.apps.controlloop.feature.casablanca;
 
-import static org.junit.Assert.*;
+import static org.junit.Assert.assertEquals;
 
-import org.onap.policy.drools.apps.controlloop.feature.beijing.BeijingFeature;
-
-public class BeijingFeatureTest {
+public class CasablancaFeatureTest {
 
     @org.junit.Test
     public void getSequenceNumber() {
-        assertTrue(new BeijingFeature().getSequenceNumber() == BeijingFeature.SEQNO);
+        assertEquals(CasablancaFeature.SEQNO, new CasablancaFeature().getSequenceNumber());
     }
 }
index ae318d6..5e3b3de 100644 (file)
     <module>model-impl</module>
     <module>policy-yaml</module>
     <module>simulators</module>
-    <module>controller-beijing</module>
+    <module>controller-casablanca</module>
     <module>feature-controlloop-utils</module>
     <module>feature-controlloop-trans</module>
     <module>feature-controlloop-amsterdam</module>
-    <module>feature-controlloop-beijing</module>
+    <module>feature-controlloop-casablanca</module>
     <module>msb</module>
   </modules>
 
index d345d8f..9773ee6 100644 (file)
@@ -90,7 +90,7 @@
     </dependency>
     <dependency>
       <groupId>org.onap.policy.drools-applications.controlloop.common</groupId>
-      <artifactId>feature-controlloop-beijing</artifactId>
+      <artifactId>feature-controlloop-casablanca</artifactId>
       <version>${project.version}</version>
       <type>zip</type>
     </dependency>
index b50f6ef..4d75ec8 100644 (file)
@@ -37,7 +37,7 @@ source ${POLICY_HOME}/etc/build.info
 
 features install controlloop-trans
 features install controlloop-amsterdam
-features install controlloop-beijing
+features install controlloop-casablanca
 
 features enable controlloop-trans
 features enable controlloop-amsterdam
 
 source "${POLICY_HOME}"/etc/build.info
 
-echo "Control Loop CLI Generator for R2 Beijing Release"
+echo "Control Loop CLI Generator for R2 Casablanca Release"
 echo "---------------------------------------------------"
 echo
 
-GROUP_ID="org.onap.policy.rules.beijing"
-ARTIFACT_ID="beijing"
+GROUP_ID="org.onap.policy.rules.casablanca"
+ARTIFACT_ID="casablanca"
 VERSION="${version:-1.2.0}"
-PACKAGE="org.onap.policy.rules.beijing"
+PACKAGE="org.onap.policy.rules.casablanca"
 
 # vCPE Policy Parameters
 VCPE_CONTROL_LOOP_NAME="ControlLoop-vCPE-48f0c2c3-a172-4192-9ae3-052274181b6e"
@@ -55,7 +55,7 @@ VOLTE_POLICY_NAME="volte"
 VOLTE_CONTROL_LOOP_YAML="controlLoop%3A%0D%0A++version%3A+2.0.0%0D%0A++controlLoopName%3A+ControlLoop-VOLTE-2179b738-fd36-4843-a71a-a8c24c70c55b%0D%0A++trigger_policy%3A+unique-policy-id-1-restart%0D%0A++timeout%3A+3600%0D%0A++abatement%3A+false%0D%0A+%0D%0Apolicies%3A%0D%0A++-+id%3A+unique-policy-id-1-restart%0D%0A++++name%3A+Restart+the+VM%0D%0A++++description%3A%0D%0A++++actor%3A+VFC%0D%0A++++recipe%3A+Restart%0D%0A++++target%3A%0D%0A++++++type%3A+VM%0D%0A++++retry%3A+3%0D%0A++++timeout%3A+1200%0D%0A++++success%3A+final_success%0D%0A++++failure%3A+final_failure%0D%0A++++failure_timeout%3A+final_failure_timeout%0D%0A++++failure_retries%3A+final_failure_retries%0D%0A++++failure_exception%3A+final_failure_exception%0D%0A++++failure_guard%3A+final_failure_guard"
 
 # Generic Scope and Version
-POLICY_SCOPE="beijing"
+POLICY_SCOPE="casablanca"
 POLICY_VERSION="v0.0.1"
 
 BRMSGW_TOPIC="BRMSGW-POLICY"
@@ -196,7 +196,7 @@ if [ ! -w "${DIR_TMP}" ]; then
 fi
 
 ARCHETYPE_GROUP_ID="org.onap.policy.drools-applications.controlloop.templates"
-ARCHETYPE_ARTIFACT_ID="archetype-cl-beijing"
+ARCHETYPE_ARTIFACT_ID="archetype-cl-casablanca"
 ARCHETYPE_VERSION="${VERSION}"
 
 if [ -d "${DIR_TMP}/${ARTIFACT_ID}/" ]; then
@@ -310,7 +310,7 @@ echo "1. copy ${DIR_TMP}/${ARTIFACT_ID}/${ARTIFACT_ID}-controller.properties und
 echo "   and restart the pdp-d (policy stop; policy start)"
 echo "2. cd ${DIR_TMP}/${ARTIFACT_ID}/; rest-add-controller ${ARTIFACT_ID}"
 echo 
-echo "Once this Control Loop is deployed, you can run the push-policies-beijing script"
+echo "Once this Control Loop is deployed, you can run the push-policies-casablanca script"
 echo "to automatically insert the policies for all use cases supported in this release"
 echo
 )
@@ -119,4 +119,4 @@ echo "Policy insertions completed."
 echo
 
 echo "The working memory is now: "
-curl --silent --user @1b3rt:31nst31n -X GET http://localhost:9696/policy/pdp/engine/controllers/${CONTROLLER_NAME}/drools/facts/beijing | python -m json.tool
+curl --silent --user @1b3rt:31nst31n -X GET http://localhost:9696/policy/pdp/engine/controllers/${CONTROLLER_NAME}/drools/facts/casablanca | python -m json.tool
     <version>1.3.0-SNAPSHOT</version>
   </parent>
 
-  <artifactId>archetype-cl-beijing</artifactId>
+  <artifactId>archetype-cl-casablanca</artifactId>
 
   <name>${project.artifactId}</name>
-  <description>Archetype to generate a yaml based control loop for ONAP Beijing release</description>
+  <description>Archetype to generate a yaml based control loop for ONAP Casablanca release</description>
 
   <build>
     <extensions>
@@ -29,7 +29,7 @@
   <packaging>kjar</packaging>
 
   <name>${artifactId}</name>
-  <description>Control Loop Beijing Release Rules</description>
+  <description>Control Loop Casablanca Release Rules</description>
 
   <properties>
     <maven.compiler.source>1.8</maven.compiler.source>
index a614ade..10a4a24 100644 (file)
@@ -35,7 +35,7 @@
   <modules>
     <module>template.demo</module>
     <module>archetype-cl-amsterdam</module>
-    <module>archetype-cl-beijing</module>
+    <module>archetype-cl-casablanca</module>
   </modules>