From ec58a8ee5972fb53b19eaa6f3a1d99f4da7b312c Mon Sep 17 00:00:00 2001 From: subhash kumar singh Date: Fri, 19 Apr 2019 12:15:43 +0530 Subject: Add missing lines for CCVPN Add missing lines to create request input in vnfcustomization. Change-Id: If7bced1f5af1ce8a899ef33435582aa420fc6d8b Issue-ID: SO-1800 Signed-off-by: subhash kumar singh --- .../onap/so/asdc/installer/heat/ToscaResourceInstaller.java | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-) (limited to 'asdc-controller/src/main') 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 e61aafac2e..3bfcd2f8d5 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 @@ -122,7 +122,6 @@ import org.onap.so.db.catalog.data.repository.ServiceRepository; import org.onap.so.db.catalog.data.repository.TempNetworkHeatTemplateRepository; import org.onap.so.db.catalog.data.repository.VFModuleCustomizationRepository; import org.onap.so.db.catalog.data.repository.VFModuleRepository; -import org.onap.so.db.catalog.data.repository.VnfCustomizationRepository; import org.onap.so.db.catalog.data.repository.VnfResourceRepository; import org.onap.so.db.catalog.data.repository.VnfcCustomizationRepository; import org.onap.so.db.catalog.data.repository.VnfcInstanceGroupCustomizationRepository; @@ -2167,19 +2166,24 @@ public class ToscaResourceInstaller { } protected VnfResourceCustomization createVnfResource(NodeTemplate vfNodeTemplate, - ToscaResourceStructure toscaResourceStructure, Service service) { + ToscaResourceStructure toscaResourceStructure, Service service) throws ArtifactInstallerException { VnfResourceCustomization vnfResourceCustomization = null; if (vnfResourceCustomization == null) { VnfResource vnfResource = findExistingVnfResource(service, vfNodeTemplate.getMetaData().getValue(SdcPropertyNames.PROPERTY_NAME_UUID)); - if (vnfResource == null) + if (vnfResource == null) { vnfResource = createVnfResource(vfNodeTemplate); + } vnfResourceCustomization = createVnfResourceCustomization(vfNodeTemplate, toscaResourceStructure, vnfResource); vnfResourceCustomization.setVnfResources(vnfResource); vnfResourceCustomization.setService(service); + + // setting resource input for vnf customization + vnfResourceCustomization.setResourceInput( + getResourceInput(toscaResourceStructure, vnfResourceCustomization.getModelCustomizationUUID())); vnfResource.getVnfResourceCustomizations().add(vnfResourceCustomization); } -- cgit 1.2.3-korg