summaryrefslogtreecommitdiffstats
path: root/asdc-controller
diff options
context:
space:
mode:
authorBenjamin, Max (mb388a) <mb388a@us.att.com>2018-09-17 11:14:35 -0400
committerBenjamin, Max (mb388a) <mb388a@us.att.com>2018-09-17 12:01:30 -0400
commit08c27a288e961c1ffd4151384ef0f609bb855e10 (patch)
tree5a139d4624226dcf543e14afeef284dec352be70 /asdc-controller
parent184e1ed3e83effc39b6f7f92c9f4b9d874c4cfe7 (diff)
more stability fixes
Remove conditional to not check VNF topology add empty string verification for serviceName field Add junits for CNRCR and NtwkAdptr changes. Add search in new CollNtwkResCust tbl to get NtwkResource. - Updated test data files to include 'pre-load' flag in both VfModuleOperation and NetworkOperation json test data files. - MSO to not to send <preload>boolean</from-preload> to SDNC in network-topology-opertion and vf-module-topology-operation. Updated GeneralTopologyObjectMapper to set 'from-preload' to null so that elements with Nulls are not sent to SDNC. Updated buildNetworkInformation() and buildVfModuleInformation() methods. update flow stats to not cause bpmn flow to crash Fix headers so SDNC does not return XML Add implementation of deleteVolumeGroupResponse parsing; fix JUnits that worked by accident. Change-Id: Ia96d552d731e112505fcf739029a6fd4d0134546 Issue-ID: SO-1061 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.java10
-rw-r--r--asdc-controller/src/main/java/org/onap/so/asdc/util/ASDCNotificationLogging.java71
2 files changed, 64 insertions, 17 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 1fca9d3ff2..970cb0bf50 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
@@ -488,13 +488,11 @@ public class ToscaResourceInstaller {
.getSdcCsarHelper().getVfModulesByVf(vfCustomizationUUID);
IVfModuleData vfMetadata = vfModuleStructure.getVfModuleMetadata();
- logger.debug("Comparing VFModule Metadata CustomizationUUID : " + vfMetadata.getVfModuleModelCustomizationUUID());
- for(Group group : vfGroups){
- logger.debug("To Group VFModuleModelCustomizationUUID " + group.getMetadata().getValue("vfModuleModelCustomizationUUID"));
- }
+ logger.debug("Comparing VFModuleMetadata CustomizationUUID : " + vfMetadata.getVfModuleModelCustomizationUUID());
- Optional<org.onap.sdc.toscaparser.api.Group> matchingObject = vfGroups.stream().
- filter(group -> group.getMetadata().getValue("vfModuleModelCustomizationUUID").equals(vfMetadata.getVfModuleModelCustomizationUUID())).
+ Optional<org.onap.sdc.toscaparser.api.Group> matchingObject = vfGroups.stream()
+ .peek(group -> logger.debug("To Csar Group VFModuleModelCustomizationUUID " + group.getMetadata().getValue("vfModuleModelCustomizationUUID")))
+ .filter(group -> group.getMetadata().getValue("vfModuleModelCustomizationUUID").equals(vfMetadata.getVfModuleModelCustomizationUUID())).
findFirst();
if(matchingObject.isPresent()){
VfModuleCustomization vfModuleCustomization = createVFModuleResource(matchingObject.get(), nodeTemplate, toscaResourceStruct,
diff --git a/asdc-controller/src/main/java/org/onap/so/asdc/util/ASDCNotificationLogging.java b/asdc-controller/src/main/java/org/onap/so/asdc/util/ASDCNotificationLogging.java
index 54977104ff..ab9c359b7f 100644
--- a/asdc-controller/src/main/java/org/onap/so/asdc/util/ASDCNotificationLogging.java
+++ b/asdc-controller/src/main/java/org/onap/so/asdc/util/ASDCNotificationLogging.java
@@ -201,11 +201,6 @@ public class ASDCNotificationLogging {
}
}
- buffer.append(System.lineSeparator());
- buffer.append(System.lineSeparator());
- buffer.append("VNF Level Properties:");
- buffer.append(System.lineSeparator());
-
List<NodeTemplate> vfNodeTemplatesList = toscaResourceStructure.getSdcCsarHelper().getServiceVfList();
for (NodeTemplate vfNodeTemplate : vfNodeTemplatesList) {
@@ -287,17 +282,16 @@ public class ASDCNotificationLogging {
}
-
-
- buffer.append(System.lineSeparator());
- buffer.append("VF Module Properties:");
- buffer.append(System.lineSeparator());
+
List<Group> vfGroups = toscaResourceStructure.getSdcCsarHelper().getVfModulesByVf(testNull(vfNodeTemplate.getMetaData().getValue(SdcPropertyNames.PROPERTY_NAME_CUSTOMIZATIONUUID)));
for(Group group : vfGroups){
Metadata vfMetadata = group.getMetadata();
+ buffer.append(System.lineSeparator());
+ buffer.append("VF Module Properties:");
+ buffer.append(System.lineSeparator());
buffer.append("ModelInvariantUuid:");
buffer.append(testNull(toscaResourceStructure.getSdcCsarHelper().getMetadataPropertyValue(vfMetadata, SdcPropertyNames.PROPERTY_NAME_VFMODULEMODELINVARIANTUUID)));
buffer.append(System.lineSeparator());
@@ -314,7 +308,62 @@ public class ASDCNotificationLogging {
buffer.append(testNull(toscaResourceStructure.getSdcCsarHelper().getMetadataPropertyValue(vfMetadata, SdcPropertyNames.PROPERTY_NAME_DESCRIPTION)));
buffer.append(System.lineSeparator());
}
-
+
+ List<NodeTemplate> cvfcList = toscaResourceStructure.getSdcCsarHelper().getNodeTemplateBySdcType(vfNodeTemplate, SdcTypes.CVFC);
+
+ for(NodeTemplate cvfcTemplate : cvfcList) {
+
+ buffer.append(System.lineSeparator());
+ buffer.append("CVNFC Properties:");
+ buffer.append(System.lineSeparator());
+ buffer.append("ModelCustomizationUuid:");
+ buffer.append(testNull(cvfcTemplate.getMetaData().getValue(SdcPropertyNames.PROPERTY_NAME_CUSTOMIZATIONUUID)));
+ buffer.append(System.lineSeparator());
+ buffer.append("ModelInvariantUuid:");
+ buffer.append(testNull(cvfcTemplate.getMetaData().getValue(SdcPropertyNames.PROPERTY_NAME_INVARIANTUUID)));
+ buffer.append(System.lineSeparator());
+ buffer.append("ModelName:");
+ buffer.append(testNull(cvfcTemplate.getMetaData().getValue(SdcPropertyNames.PROPERTY_NAME_NAME)));
+ buffer.append(System.lineSeparator());
+ buffer.append("ModelUuid:");
+ buffer.append(testNull(cvfcTemplate.getMetaData().getValue(SdcPropertyNames.PROPERTY_NAME_UUID)));
+ buffer.append(System.lineSeparator());
+ buffer.append("ModelVersion:");
+ buffer.append(testNull(cvfcTemplate.getMetaData().getValue(SdcPropertyNames.PROPERTY_NAME_VERSION)));
+ buffer.append(System.lineSeparator());
+ buffer.append("Description:");
+ buffer.append(testNull(cvfcTemplate.getMetaData().getValue(SdcPropertyNames.PROPERTY_NAME_DESCRIPTION)));
+ buffer.append(System.lineSeparator());
+
+
+ List<NodeTemplate> vfcList = toscaResourceStructure.getSdcCsarHelper().getNodeTemplateBySdcType(cvfcTemplate, SdcTypes.VFC);
+
+ for(NodeTemplate vfcTemplate : vfcList) {
+ buffer.append(System.lineSeparator());
+ buffer.append("VNFC Properties:");
+ buffer.append(System.lineSeparator());
+ buffer.append("ModelCustomizationUuid:");
+ buffer.append(testNull(vfcTemplate.getMetaData().getValue(SdcPropertyNames.PROPERTY_NAME_CUSTOMIZATIONUUID)));
+ buffer.append(System.lineSeparator());
+ buffer.append("ModelInvariantUuid:");
+ buffer.append(testNull(vfcTemplate.getMetaData().getValue(SdcPropertyNames.PROPERTY_NAME_INVARIANTUUID)));
+ buffer.append(System.lineSeparator());
+ buffer.append("ModelName:");
+ buffer.append(testNull(vfcTemplate.getMetaData().getValue(SdcPropertyNames.PROPERTY_NAME_NAME)));
+ buffer.append(System.lineSeparator());
+ buffer.append("ModelUuid:");
+ buffer.append(testNull(vfcTemplate.getMetaData().getValue(SdcPropertyNames.PROPERTY_NAME_UUID)));
+ buffer.append(System.lineSeparator());
+ buffer.append("ModelVersion:");
+ buffer.append(testNull(vfcTemplate.getMetaData().getValue(SdcPropertyNames.PROPERTY_NAME_VERSION)));
+ buffer.append(System.lineSeparator());
+ buffer.append("Description:");
+ buffer.append(testNull(vfcTemplate.getMetaData().getValue(SdcPropertyNames.PROPERTY_NAME_DESCRIPTION)));
+ buffer.append(System.lineSeparator());
+
+ }
+
+ }
}