aboutsummaryrefslogtreecommitdiffstats
path: root/asdc-controller
diff options
context:
space:
mode:
authorBenjamin, Max (mb388a) <mb388a@us.att.com>2019-02-20 16:50:13 -0500
committerBenjamin, Max (mb388a) <mb388a@us.att.com>2019-02-20 16:50:29 -0500
commit15d5534416832bdad9afe3e7d1640f68d64bb9fe (patch)
tree34a24995f9ef744f632ff0133a81a0d81ab2047e /asdc-controller
parent860edae04456562fd7cf249968cd54b30b1f7f12 (diff)
Fix for when Customization already exists
- When the Customization already exists associate the new NetworkResource with it. Change-Id: Ia4d89a04d020dd2f2ba4a2f2d330bda9bff6da14 Issue-ID: SO-1540 Signed-off-by: Benjamin, Max (mb388a) <mb388a@us.att.com>
Diffstat (limited to 'asdc-controller')
-rw-r--r--asdc-controller/src/main/java/org/onap/so/asdc/installer/heat/ToscaResourceInstaller.java12
1 files changed, 11 insertions, 1 deletions
diff --git a/asdc-controller/src/main/java/org/onap/so/asdc/installer/heat/ToscaResourceInstaller.java b/asdc-controller/src/main/java/org/onap/so/asdc/installer/heat/ToscaResourceInstaller.java
index d13fff4801..10b8ba7c16 100644
--- a/asdc-controller/src/main/java/org/onap/so/asdc/installer/heat/ToscaResourceInstaller.java
+++ b/asdc-controller/src/main/java/org/onap/so/asdc/installer/heat/ToscaResourceInstaller.java
@@ -1060,7 +1060,17 @@ public class ToscaResourceInstaller {
}
- if(networkResourceCustomization==null || !networkUUIDsMatch){
+ if (networkResourceCustomization!=null && !networkUUIDsMatch){
+
+ NetworkResource networkResource = createNetworkResource(networkNodeTemplate, toscaResourceStructure, heatTemplate,
+ aicMax, aicMin);
+
+ networkResourceCustomization.setNetworkResource(networkResource);
+
+ networkCustomizationRepo.saveAndFlush(networkResourceCustomization);
+
+ }
+ else if(networkResourceCustomization==null){
networkResourceCustomization = createNetworkResourceCustomization(networkNodeTemplate,
toscaResourceStructure);