diff options
Diffstat (limited to 'bpmn/MSOInfrastructureBPMN/src/main/groovy')
2 files changed, 25 insertions, 5 deletions
diff --git a/bpmn/MSOInfrastructureBPMN/src/main/groovy/org/openecomp/mso/bpmn/infrastructure/scripts/DoDeleteE2EServiceInstance.groovy b/bpmn/MSOInfrastructureBPMN/src/main/groovy/org/openecomp/mso/bpmn/infrastructure/scripts/DoDeleteE2EServiceInstance.groovy index 003210f602..98a1a43035 100644 --- a/bpmn/MSOInfrastructureBPMN/src/main/groovy/org/openecomp/mso/bpmn/infrastructure/scripts/DoDeleteE2EServiceInstance.groovy +++ b/bpmn/MSOInfrastructureBPMN/src/main/groovy/org/openecomp/mso/bpmn/infrastructure/scripts/DoDeleteE2EServiceInstance.groovy @@ -337,12 +337,13 @@ public class DoDeleteE2EServiceInstance extends AbstractServiceTaskProcessor { try { utils.log("DEBUG", " ***** Inside prepareDecomposeService of create generic e2e service ***** ", isDebugEnabled) - String modelInvariantUuid = execution.getVariable("model-invariant-id") + String modelInvariantUuid = execution.getVariable("model-invariant-id-original") + String modelVersionId = execution.getVariable("model-version-id-original") //here modelVersion is not set, we use modelUuid to decompose the service. String serviceModelInfo = """{ "modelInvariantUuid":"${modelInvariantUuid}", - "modelUuid":"${modelUuid}", - "modelVersion":"" + "modelUuid":"", + "modelVersion":"${modelVersionId}" }""" execution.setVariable("serviceModelInfo", serviceModelInfo) @@ -357,16 +358,18 @@ public class DoDeleteE2EServiceInstance extends AbstractServiceTaskProcessor { public void postDecomposeService(DelegateExecution execution) { def isDebugEnabled=execution.getVariable("isDebugLogEnabled") - utils.log("DEBUG", " ***** Inside processDecomposition() of create generic e2e service flow ***** ", isDebugEnabled) + utils.log("DEBUG", " ***** Inside processDecomposition() of delete generic e2e service flow ***** ", isDebugEnabled) try { ServiceDecomposition serviceDecomposition = execution.getVariable("serviceDecomposition") List<Resource> deleteResourceList = serviceDecomposition.getServiceResources() execution.setVariable("deleteResourceList", deleteResourceList) + execution.setVariable("resourceInstanceIDs", execution.getVariable("serviceRelationShip")) } catch (Exception ex) { String exceptionMessage = "Bpmn error encountered in create generic e2e service flow. processDecomposition() - " + ex.getMessage() utils.log("DEBUG", exceptionMessage, isDebugEnabled) exceptionUtil.buildAndThrowWorkflowException(execution, 7000, exceptionMessage) } + utils.log("DEBUG", " ***** exit processDecomposition() of delete generic e2e service flow ***** ", isDebugEnabled) } public void preInitResourcesOperStatus(DelegateExecution execution){ diff --git a/bpmn/MSOInfrastructureBPMN/src/main/groovy/org/openecomp/mso/bpmn/infrastructure/scripts/DoDeleteResourcesV1.groovy b/bpmn/MSOInfrastructureBPMN/src/main/groovy/org/openecomp/mso/bpmn/infrastructure/scripts/DoDeleteResourcesV1.groovy index 6c150df754..38dca886b4 100644 --- a/bpmn/MSOInfrastructureBPMN/src/main/groovy/org/openecomp/mso/bpmn/infrastructure/scripts/DoDeleteResourcesV1.groovy +++ b/bpmn/MSOInfrastructureBPMN/src/main/groovy/org/openecomp/mso/bpmn/infrastructure/scripts/DoDeleteResourcesV1.groovy @@ -41,6 +41,23 @@ import org.openecomp.mso.bpmn.infrastructure.properties.BPMNProperties import static org.apache.commons.lang3.StringUtils.isBlank import static org.apache.commons.lang3.StringUtils.isBlank + +/** + * input for script : + * msoRequestId + * isDebugLogEnabled + * globalSubscriberId + * serviceType + * serviceInstanceId + * URN_mso_workflow_sdncadapter_callback + * serviceInputParams + * deleteResourceList + * resourceInstanceIDs + * + * output from script: + * + */ + public class DoDeleteResourcesV1 extends AbstractServiceTaskProcessor { String Prefix="DDR_" @@ -132,7 +149,7 @@ public class DoDeleteResourcesV1 extends AbstractServiceTaskProcessor { List<String> resourceSequence = new ArrayList<String>() // get delete resource list and order list - List<Resource> delResourceList = execution.getVariable("delResourceList") + List<Resource> delResourceList = execution.getVariable("deleteResourceList") // existing resource list List<ServiceInstance> existResourceList = execution.getVariable("realNSRessources") |