aboutsummaryrefslogtreecommitdiffstats
path: root/bpmn/MSOCommonBPMN/src/main
diff options
context:
space:
mode:
authorsreejatechm <sg00744975@techmahindra.com>2022-01-10 12:26:46 +0530
committersreejatechm <sg00744975@techmahindra.com>2022-01-10 12:27:26 +0530
commitf65448561b7c062c73c5d562e196c82b0e94e207 (patch)
tree7d4da800af3c89aadbf74412079ecb530f9461e7 /bpmn/MSOCommonBPMN/src/main
parent5a7f29ce2848842246a53c9dbc883d12be4ded40 (diff)
CNF Healthcheck query based on helm status
-Enhancement of CNFO model with helm upgrade -Included code changes with respect to HealthCheckBB Issue-ID: SO-3814 Signed-off-by: sreejatechm <sg00744975@techmahindra.com> Change-Id: I44f11f156c132d713f42f0a855adb6730b7c6abe
Diffstat (limited to 'bpmn/MSOCommonBPMN/src/main')
-rw-r--r--bpmn/MSOCommonBPMN/src/main/java/org/onap/so/bpmn/servicedecomposition/tasks/BBInputSetup.java27
1 files changed, 26 insertions, 1 deletions
diff --git a/bpmn/MSOCommonBPMN/src/main/java/org/onap/so/bpmn/servicedecomposition/tasks/BBInputSetup.java b/bpmn/MSOCommonBPMN/src/main/java/org/onap/so/bpmn/servicedecomposition/tasks/BBInputSetup.java
index d39da5ee37..603e11d458 100644
--- a/bpmn/MSOCommonBPMN/src/main/java/org/onap/so/bpmn/servicedecomposition/tasks/BBInputSetup.java
+++ b/bpmn/MSOCommonBPMN/src/main/java/org/onap/so/bpmn/servicedecomposition/tasks/BBInputSetup.java
@@ -1250,7 +1250,7 @@ public class BBInputSetup implements JavaDelegate {
|| requestAction.equalsIgnoreCase("activateFabricConfiguration")
|| requestAction.equalsIgnoreCase("recreateInstance")
|| requestAction.equalsIgnoreCase("replaceInstance")
- || requestAction.equalsIgnoreCase("upgradeInstance")) {
+ || requestAction.equalsIgnoreCase("upgradeInstance") || requestAction.equalsIgnoreCase("healthCheck")) {
return getGBBMacroExistingService(executeBB, lookupKeyMap, bbName, requestAction,
requestDetails.getCloudConfiguration());
}
@@ -1564,6 +1564,9 @@ public class BBInputSetup implements JavaDelegate {
break;
}
}
+ } else if (bbName.equals("HealthCheckBB")
+ && (VNF).equalsIgnoreCase(executeBB.getBuildingBlock().getBpmnScope())) {
+ this.setisHelmforHealthCheckBB(service, serviceInstance, gBB);
}
if (executeBB.getWorkflowResourceIds() != null) {
parameter.setResourceId(executeBB.getWorkflowResourceIds().getNetworkCollectionId());
@@ -2112,6 +2115,28 @@ public class BBInputSetup implements JavaDelegate {
return collection;
}
+ private void setisHelmforHealthCheckBB(Service service, ServiceInstance serviceInstance, GeneralBuildingBlock gBB) {
+ for (GenericVnf vnf : serviceInstance.getVnfs()) {
+ for (VfModule vfModule : vnf.getVfModules()) {
+ String vnfModelCustomizationUUID =
+ this.bbInputSetupUtils.getAAIGenericVnf(vnf.getVnfId()).getModelCustomizationId();
+ ModelInfo vnfModelInfo = new ModelInfo();
+ vnfModelInfo.setModelCustomizationUuid(vnfModelCustomizationUUID);
+ this.mapCatalogVnf(vnf, vnfModelInfo, service);
+ String vfModuleCustomizationUUID = this.bbInputSetupUtils
+ .getAAIVfModule(vnf.getVnfId(), vfModule.getVfModuleId()).getModelCustomizationId();
+ ModelInfo vfModuleModelInfo = new ModelInfo();
+ vfModuleModelInfo.setModelCustomizationId(vfModuleCustomizationUUID);
+ this.mapCatalogVfModule(vfModule, vfModuleModelInfo, service, vnfModelCustomizationUUID);
+ if (vfModule.getModelInfoVfModule() != null && vfModule.getModelInfoVfModule().getModelName() != null
+ && vfModule.getModelInfoVfModule().getModelName().contains("helm")) {
+ gBB.getRequestContext().setIsHelm(true);
+ break;
+ }
+ }
+ }
+ }
+
protected void mapL3Networks(List<AAIResourceUri> list, List<L3Network> l3Networks) {
for (AAIResourceUri aaiResourceUri : list) {
l3Networks.add(this.mapL3Network(aaiResourceUri));