Merge "[CLAMP-26] upgrade org.onap.policy"
diff --git a/pom.xml b/pom.xml
index 801b2ee..b853ccf 100644
--- a/pom.xml
+++ b/pom.xml
@@ -316,7 +316,7 @@
</dependency>
<!-- CSI Logging End -->
<dependency>
- <groupId>org.openecomp.policy.engine</groupId>
+ <groupId>org.onap.policy.engine</groupId>
<artifactId>PolicyEngineAPI</artifactId>
<version>1.1.0-SNAPSHOT</version>
<exclusions>
@@ -335,8 +335,8 @@
</exclusions>
</dependency>
<dependency>
- <groupId>org.openecomp.policy.common</groupId>
- <artifactId>ECOMP-Logging</artifactId>
+ <groupId>org.onap.policy.common</groupId>
+ <artifactId>ONAP-Logging</artifactId>
<version>1.1.0-SNAPSHOT</version>
<exclusions>
<exclusion>
@@ -354,7 +354,7 @@
</exclusions>
</dependency>
<dependency>
- <groupId>org.openecomp.policy.engine</groupId>
+ <groupId>org.onap.policy.engine</groupId>
<artifactId>ControlloopPolicy</artifactId>
<version>1.1.0-SNAPSHOT</version>
<exclusions>
diff --git a/src/main/java/org/onap/clamp/clds/client/OperationalPolicyDelegate.java b/src/main/java/org/onap/clamp/clds/client/OperationalPolicyDelegate.java
index fc3ea2a..2b7b066 100644
--- a/src/main/java/org/onap/clamp/clds/client/OperationalPolicyDelegate.java
+++ b/src/main/java/org/onap/clamp/clds/client/OperationalPolicyDelegate.java
@@ -26,7 +26,7 @@
import org.onap.clamp.clds.client.req.OperationalPolicyReq;
import org.onap.clamp.clds.model.prop.ModelProperties;
import org.onap.clamp.clds.model.refprop.RefProp;
-import org.openecomp.policy.api.AttributeType;
+import org.onap.policy.api.AttributeType;
import org.camunda.bpm.engine.delegate.DelegateExecution;
import org.camunda.bpm.engine.delegate.JavaDelegate;
import org.springframework.beans.factory.annotation.Autowired;
diff --git a/src/main/java/org/onap/clamp/clds/client/PolicyClient.java b/src/main/java/org/onap/clamp/clds/client/PolicyClient.java
index 95e60ea..d19c216 100644
--- a/src/main/java/org/onap/clamp/clds/client/PolicyClient.java
+++ b/src/main/java/org/onap/clamp/clds/client/PolicyClient.java
@@ -25,7 +25,7 @@
import org.onap.clamp.clds.model.prop.ModelProperties;
import org.onap.clamp.clds.model.refprop.RefProp;
-import org.openecomp.policy.api.*;
+import org.onap.policy.api.*;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.beans.factory.annotation.Value;
import org.springframework.context.ApplicationContext;
@@ -106,7 +106,7 @@
// Set Policy Type
policyParameters.setPolicyConfigType(PolicyConfigType.MicroService);
- policyParameters.setEcompName(refProp.getStringValue("policy.ecomp.name"));
+ policyParameters.setOnapName(refProp.getStringValue("policy.onap.name"));
policyParameters.setPolicyName(prop.getCurrentPolicyScopeAndPolicyName());
policyParameters.setConfigBody(policyJson);
@@ -339,4 +339,4 @@
return responseMessage;
}
-}
\ No newline at end of file
+}
diff --git a/src/main/java/org/onap/clamp/clds/client/req/OperationalPolicyReq.java b/src/main/java/org/onap/clamp/clds/client/req/OperationalPolicyReq.java
index 90b9ff8..17e6061 100644
--- a/src/main/java/org/onap/clamp/clds/client/req/OperationalPolicyReq.java
+++ b/src/main/java/org/onap/clamp/clds/client/req/OperationalPolicyReq.java
@@ -27,17 +27,17 @@
import org.onap.clamp.clds.model.prop.ModelProperties;
import org.onap.clamp.clds.model.prop.Policy;
import org.onap.clamp.clds.model.prop.PolicyItem;
-import org.openecomp.policy.controlloop.policy.TargetType;
-import org.openecomp.policy.controlloop.policy.PolicyResult;
-import org.openecomp.policy.controlloop.policy.Target;
-import org.openecomp.policy.controlloop.policy.builder.BuilderException;
-import org.openecomp.policy.controlloop.policy.builder.ControlLoopPolicyBuilder;
-import org.openecomp.policy.controlloop.policy.builder.Message;
-import org.openecomp.policy.controlloop.policy.builder.Results;
-import org.openecomp.policy.api.AttributeType;
-import org.openecomp.policy.asdc.Resource;
-import org.openecomp.policy.asdc.ResourceType;
-import org.openecomp.policy.asdc.Service;
+import org.onap.policy.controlloop.policy.TargetType;
+import org.onap.policy.controlloop.policy.PolicyResult;
+import org.onap.policy.controlloop.policy.Target;
+import org.onap.policy.controlloop.policy.builder.BuilderException;
+import org.onap.policy.controlloop.policy.builder.ControlLoopPolicyBuilder;
+import org.onap.policy.controlloop.policy.builder.Message;
+import org.onap.policy.controlloop.policy.builder.Results;
+import org.onap.policy.api.AttributeType;
+import org.onap.policy.asdc.Resource;
+import org.onap.policy.asdc.ResourceType;
+import org.onap.policy.asdc.Service;
import org.onap.clamp.clds.model.refprop.RefProp;
import org.jboss.resteasy.spi.BadRequestException;
@@ -155,10 +155,10 @@
builder.addResource(vfcResources);
// process each policy
- HashMap<String, org.openecomp.policy.controlloop.policy.Policy> policyObjMap = new HashMap<>();
+ HashMap<String, org.onap.policy.controlloop.policy.Policy> policyObjMap = new HashMap<>();
List<PolicyItem> policyItemList = orderParentFirst(policy.getPolicyItems());
for (int i = 0; i < policyItemList.size(); i++) {
- org.openecomp.policy.controlloop.policy.Policy policyObj;
+ org.onap.policy.controlloop.policy.Policy policyObj;
PolicyItem policyItem = policyItemList.get(i);
String policyName = policyItem.getRecipe() + " Policy";
if (i == 0) {
@@ -173,7 +173,7 @@
policyItem.getMaxRetries(),
policyItem.getRetryTimeLimit());
} else {
- org.openecomp.policy.controlloop.policy.Policy parentPolicyObj = policyObjMap.get(policyItem.getParentPolicy());
+ org.onap.policy.controlloop.policy.Policy parentPolicyObj = policyObjMap.get(policyItem.getParentPolicy());
String policyDescription = policyItem.getRecipe() + " Policy - triggered conditionally by " + parentPolicyObj.getName() + " - created by CLDS";
policyObj = builder.setPolicyForPolicyResult(
policyName,
@@ -296,4 +296,4 @@
return prArray;
}
-}
\ No newline at end of file
+}
diff --git a/src/test/java/org/onap/clamp/clds/it/PolicyClientIT.java b/src/test/java/org/onap/clamp/clds/it/PolicyClientIT.java
index 61ee185..d0fcf42 100644
--- a/src/test/java/org/onap/clamp/clds/it/PolicyClientIT.java
+++ b/src/test/java/org/onap/clamp/clds/it/PolicyClientIT.java
@@ -36,7 +36,7 @@
import org.onap.clamp.clds.AbstractIT;
import org.onap.clamp.clds.model.CldsEvent;
import org.onap.clamp.clds.model.prop.ModelProperties;
-import org.openecomp.policy.api.AttributeType;
+import org.onap.policy.api.AttributeType;
import org.springframework.boot.test.context.SpringBootTest;
import org.springframework.boot.test.context.SpringBootTest.WebEnvironment;
import org.springframework.test.context.junit4.SpringRunner;