aboutsummaryrefslogtreecommitdiffstats
path: root/src/main/java/org/onap/clamp/loop/CsarInstaller.java
diff options
context:
space:
mode:
Diffstat (limited to 'src/main/java/org/onap/clamp/loop/CsarInstaller.java')
-rw-r--r--src/main/java/org/onap/clamp/loop/CsarInstaller.java13
1 files changed, 1 insertions, 12 deletions
diff --git a/src/main/java/org/onap/clamp/loop/CsarInstaller.java b/src/main/java/org/onap/clamp/loop/CsarInstaller.java
index 022b0e28a..c0cfac960 100644
--- a/src/main/java/org/onap/clamp/loop/CsarInstaller.java
+++ b/src/main/java/org/onap/clamp/loop/CsarInstaller.java
@@ -183,21 +183,10 @@ public class CsarInstaller {
return newSet;
}
- private static String createPolicyAcronym(String policyType) {
- String[] policyNameArray = policyType.split("\\.");
- return policyNameArray[policyNameArray.length - 1];
- }
-
- private PolicyModel createPolicyModel(BlueprintMicroService microService) throws InterruptedException {
- return new PolicyModel(microService.getModelType(),
- policyEngineServices.downloadOnePolicy(microService.getModelType(), microService.getModelVersion()),
- microService.getModelVersion(), createPolicyAcronym(microService.getModelType()));
- }
-
private PolicyModel getPolicyModel(BlueprintMicroService microService) throws InterruptedException {
return policyModelsRepository
.findById(new PolicyModelId(microService.getModelType(), microService.getModelVersion()))
- .orElse(createPolicyModel(microService));
+ .orElse(policyEngineServices.createPolicyModelFromPolicyEngine(microService));
}
/**