Set policy scope

Change policy scope to CLAMP in policy code and tests

Issue-ID: CLAMP-153
Change-Id: I4376e4d1d603033d0b3355d1115a21026d48beec
Signed-off-by: Determe, Sebastien (sd378r) <sd378r@intl.att.com>
diff --git a/src/main/java/org/onap/clamp/clds/client/req/tca/TcaRequestFormatter.java b/src/main/java/org/onap/clamp/clds/client/req/tca/TcaRequestFormatter.java
index f514691..282da98 100644
--- a/src/main/java/org/onap/clamp/clds/client/req/tca/TcaRequestFormatter.java
+++ b/src/main/java/org/onap/clamp/clds/client/req/tca/TcaRequestFormatter.java
@@ -72,7 +72,6 @@
             ObjectNode rootNode = (ObjectNode) refProp.getJsonTemplate("tca.policy.template", service);
             String policyName = modelProperties.getCurrentPolicyScopeAndPolicyName();
             rootNode.put("policyName", policyName);
-            rootNode.put("description", "MicroService vCPE Policy");
             ((ObjectNode) rootNode.get("content")).replace("tca_policy",
                     createPolicyContent(refProp, modelProperties, service, policyName, tca));
             String tcaPolicyReq = rootNode.toString();
diff --git a/src/main/resources/clds/templates/dcae-template.json b/src/main/resources/clds/templates/dcae-template.json
index b7cfb23..3316297 100644
--- a/src/main/resources/clds/templates/dcae-template.json
+++ b/src/main/resources/clds/templates/dcae-template.json
@@ -16,7 +16,7 @@
 				"closedLoopControlName": "",
 				"closedLoopEventClient": "configuration.dcae.microservice.tca.xml",
 				"policyName": "",
-				"policyScope": "service=vSCP;resource=F5;type=configuration",
+				"policyScope": "CLAMP",
 				"policyVersion": "v0.0.1",
 				"serviceConfigurations": {
 				}
diff --git a/src/main/resources/clds/templates/tca-policy-template.json b/src/main/resources/clds/templates/tca-policy-template.json
index eca4d46..275b6a4 100644
--- a/src/main/resources/clds/templates/tca-policy-template.json
+++ b/src/main/resources/clds/templates/tca-policy-template.json
@@ -1,12 +1,11 @@
 {
 	"service": "tca_policy",
-	"version": "1.0.0",
+	"version": "1.1.0",
 	"location": "SampleServiceLocation",
 	"configName": "SampleConfigName",
 	"uuid": "test",
-	"policyScope": "resource=SampleResource,service=SampleService,type=SampleType,closedLoopControlName=ControlLoop-vCPE-48f0c2c3-a172-4192-9ae3-052274181b6e",
 	"templateVersion": "OpenSource.version.1",
-	"policyName": "MicroServicevCPE",
+	"policyName": "MicroService",
 	"description": "MicroService Policy",
 	"priority": "1",
 	"riskType": "SampleRiskType",
diff --git a/src/main/resources/clds/templates/tca-template.json b/src/main/resources/clds/templates/tca-template.json
index 892fc0d..d2c04bf 100644
--- a/src/main/resources/clds/templates/tca-template.json
+++ b/src/main/resources/clds/templates/tca-template.json
@@ -4,7 +4,7 @@
 		{
 			"eventName": "???",
 			"controlLoopSchemaType": "VNF",
-			"policyScope": "DCAE",
+			"policyScope": "CLAMP",
 			"policyName": "???",
 			"policyVersion": "v0.0.1",
 			"thresholds": [
diff --git a/src/test/resources/clds/templates/dcae-template.json b/src/test/resources/clds/templates/dcae-template.json
index b7cfb23..3316297 100644
--- a/src/test/resources/clds/templates/dcae-template.json
+++ b/src/test/resources/clds/templates/dcae-template.json
@@ -16,7 +16,7 @@
 				"closedLoopControlName": "",
 				"closedLoopEventClient": "configuration.dcae.microservice.tca.xml",
 				"policyName": "",
-				"policyScope": "service=vSCP;resource=F5;type=configuration",
+				"policyScope": "CLAMP",
 				"policyVersion": "v0.0.1",
 				"serviceConfigurations": {
 				}
diff --git a/src/test/resources/clds/templates/tca-policy-template.json b/src/test/resources/clds/templates/tca-policy-template.json
index eca4d46..275b6a4 100644
--- a/src/test/resources/clds/templates/tca-policy-template.json
+++ b/src/test/resources/clds/templates/tca-policy-template.json
@@ -1,12 +1,11 @@
 {
 	"service": "tca_policy",
-	"version": "1.0.0",
+	"version": "1.1.0",
 	"location": "SampleServiceLocation",
 	"configName": "SampleConfigName",
 	"uuid": "test",
-	"policyScope": "resource=SampleResource,service=SampleService,type=SampleType,closedLoopControlName=ControlLoop-vCPE-48f0c2c3-a172-4192-9ae3-052274181b6e",
 	"templateVersion": "OpenSource.version.1",
-	"policyName": "MicroServicevCPE",
+	"policyName": "MicroService",
 	"description": "MicroService Policy",
 	"priority": "1",
 	"riskType": "SampleRiskType",
diff --git a/src/test/resources/clds/templates/tca-template.json b/src/test/resources/clds/templates/tca-template.json
index 892fc0d..d2c04bf 100644
--- a/src/test/resources/clds/templates/tca-template.json
+++ b/src/test/resources/clds/templates/tca-template.json
@@ -4,7 +4,7 @@
 		{
 			"eventName": "???",
 			"controlLoopSchemaType": "VNF",
-			"policyScope": "DCAE",
+			"policyScope": "CLAMP",
 			"policyName": "???",
 			"policyVersion": "v0.0.1",
 			"thresholds": [
diff --git a/src/test/resources/example/tca-policy-req/blueprint-expected.yaml b/src/test/resources/example/tca-policy-req/blueprint-expected.yaml
index 8739bb2..e0b14f3 100644
--- a/src/test/resources/example/tca-policy-req/blueprint-expected.yaml
+++ b/src/test/resources/example/tca-policy-req/blueprint-expected.yaml
@@ -30,7 +30,7 @@
         subscriberMessageLimit: '-1', subscriberPollingInterval: '20000', subscriberProtocol: https,
         subscriberTimeoutMS: '-1', subscriberTopicName: org.onap.dcae.dmaap.mtnje2.DcaeTestVESSub,
         subscriberUserName: m00502@tca.af.dcae.onap.org, subscriberUserPassword: Te5021abc,
-        tca_policy: '{"domain":"measurementsForVfScaling","metricsPerEventName":[{"eventName":"vFirewallBroadcastPackets","controlLoopSchemaType":"VNF","policyScope":"DCAE","policyName":"example_model01.ClosedLoop_FRWL_SIG_fad4dcae_e498_11e6_852e_0050568c4ccf_TCA_1jy9to4","policyVersion":"v0.0.1","thresholds":[{"closedLoopControlName":"ClosedLoop_FRWL_SIG_fad4dcae_e498_11e6_852e_0050568c4ccf_null","version":"1.0.2","fieldPath":"$.event.measurementsForVfScalingFields.vNicPerformanceArray[*].receivedDiscardedPacketsDelta","thresholdValue":123,"direction":"GREATER_OR_EQUAL","severity":"MAJOR","closedLoopEventStatus":"ONSET"},{"closedLoopControlName":"ClosedLoop_FRWL_SIG_fad4dcae_e498_11e6_852e_0050568c4ccf_null","version":"1.0.2","fieldPath":"$.event.measurementsForVfScalingFields.vNicPerformanceArray[*].receivedDiscardedPacketsDelta","thresholdValue":123,"direction":"GREATER_OR_EQUAL","severity":"MAJOR","closedLoopEventStatus":"ONSET"}]}]}'}
+        tca_policy: '{"domain":"measurementsForVfScaling","metricsPerEventName":[{"eventName":"vFirewallBroadcastPackets","controlLoopSchemaType":"VNF","policyScope":"CLAMP","policyName":"example_model01.ClosedLoop_FRWL_SIG_fad4dcae_e498_11e6_852e_0050568c4ccf_TCA_1jy9to4","policyVersion":"v0.0.1","thresholds":[{"closedLoopControlName":"ClosedLoop_FRWL_SIG_fad4dcae_e498_11e6_852e_0050568c4ccf_null","version":"1.0.2","fieldPath":"$.event.measurementsForVfScalingFields.vNicPerformanceArray[*].receivedDiscardedPacketsDelta","thresholdValue":123,"direction":"GREATER_OR_EQUAL","severity":"MAJOR","closedLoopEventStatus":"ONSET"},{"closedLoopControlName":"ClosedLoop_FRWL_SIG_fad4dcae_e498_11e6_852e_0050568c4ccf_null","version":"1.0.2","fieldPath":"$.event.measurementsForVfScalingFields.vNicPerformanceArray[*].receivedDiscardedPacketsDelta","thresholdValue":123,"direction":"GREATER_OR_EQUAL","severity":"MAJOR","closedLoopEventStatus":"ONSET"}]}]}'}
       artifact_name: dcae-analytics-tca
       artifact_version: 1.0.0
       connections:
diff --git a/src/test/resources/example/tca-policy-req/tca-policy-expected.json b/src/test/resources/example/tca-policy-req/tca-policy-expected.json
index b71328d..a04e223 100644
--- a/src/test/resources/example/tca-policy-req/tca-policy-expected.json
+++ b/src/test/resources/example/tca-policy-req/tca-policy-expected.json
@@ -1,13 +1,12 @@
 {
   "service": "tca_policy",
-  "version": "1.0.0",
+  "version": "1.1.0",
   "location": "SampleServiceLocation",
   "configName": "SampleConfigName",
   "uuid": "test",
-  "policyScope": "resource=SampleResource,service=SampleService,type=SampleType,closedLoopControlName=ControlLoop-vCPE-48f0c2c3-a172-4192-9ae3-052274181b6e",
   "templateVersion": "OpenSource.version.1",
   "policyName": "example_model01.ClosedLoop_FRWL_SIG_fad4dcae_e498_11e6_852e_0050568c4ccf_TCA_1jy9to4",
-  "description": "MicroService vCPE Policy",
+  "description": "MicroService Policy",
   "priority": "1",
   "riskType": "SampleRiskType",
   "riskLevel": "1",
@@ -19,7 +18,7 @@
         {
           "eventName": "vFirewallBroadcastPackets",
           "controlLoopSchemaType": "VNF",
-          "policyScope": "DCAE",
+          "policyScope": "CLAMP",
           "policyName": "example_model01.ClosedLoop_FRWL_SIG_fad4dcae_e498_11e6_852e_0050568c4ccf_TCA_1jy9to4",
           "policyVersion": "v0.0.1",
           "thresholds": [