summaryrefslogtreecommitdiffstats
path: root/bpmn/MSOInfrastructureBPMN/src
diff options
context:
space:
mode:
authorsubhash kumar singh <subhash.kumar.singh@huawei.com>2018-04-25 15:41:57 +0000
committersubhash kumar singh <subhash.kumar.singh@huawei.com>2018-04-25 15:41:57 +0000
commit4168307276ccf6c7eb0c06c46e6033a693c29bf4 (patch)
treed56dd075ee1a86b99dca1914fd17d7717a02d6c9 /bpmn/MSOInfrastructureBPMN/src
parentb75aa7d6f1c9ab667b6a5b5526eb4676e36649fb (diff)
Fix VFCNS termination invocation
Fix VFCNS termination invocation Change-Id: Ib30f0a3e4365e215f6da0a693f78825d5a2d32c9 Issue-ID: SO-422 Signed-off-by: subhash kumar singh <subhash.kumar.singh@huawei.com>
Diffstat (limited to 'bpmn/MSOInfrastructureBPMN/src')
-rw-r--r--bpmn/MSOInfrastructureBPMN/src/main/groovy/org/openecomp/mso/bpmn/infrastructure/scripts/DeleteVFCNSResource.groovy18
-rw-r--r--bpmn/MSOInfrastructureBPMN/src/main/groovy/org/openecomp/mso/bpmn/infrastructure/scripts/DoDeleteResourcesV1.groovy2
2 files changed, 20 insertions, 0 deletions
diff --git a/bpmn/MSOInfrastructureBPMN/src/main/groovy/org/openecomp/mso/bpmn/infrastructure/scripts/DeleteVFCNSResource.groovy b/bpmn/MSOInfrastructureBPMN/src/main/groovy/org/openecomp/mso/bpmn/infrastructure/scripts/DeleteVFCNSResource.groovy
index e9d51b2965..9ebd1fa0ba 100644
--- a/bpmn/MSOInfrastructureBPMN/src/main/groovy/org/openecomp/mso/bpmn/infrastructure/scripts/DeleteVFCNSResource.groovy
+++ b/bpmn/MSOInfrastructureBPMN/src/main/groovy/org/openecomp/mso/bpmn/infrastructure/scripts/DeleteVFCNSResource.groovy
@@ -20,6 +20,8 @@
*/
package org.openecomp.mso.bpmn.infrastructure.scripts
+import com.fasterxml.jackson.databind.ObjectMapper
+import org.openecomp.mso.bpmn.common.recipe.ResourceInput
import org.openecomp.mso.bpmn.common.scripts.AbstractServiceTaskProcessor
import org.camunda.bpm.engine.delegate.DelegateExecution
import org.openecomp.mso.bpmn.core.json.JsonUtils
@@ -36,6 +38,22 @@ public class DeleteVFCNSResource extends AbstractServiceTaskProcessor {
def isDebugEnabled = execution.getVariable("isDebugLogEnabled")
utils.log("INFO"," ***** start preProcessRequest *****", isDebugEnabled)
+ String resourceInputStr = execution.getVariable("resourceInput")
+ ResourceInput resourceInput = new ObjectMapper().readValue(resourceInputStr, ResourceInput.class)
+
+ String globalSubscriberId = resourceInput.getGlobalSubscriberId()
+ String serviceType = execution.getVariable("serviceType")
+ String operationId = resourceInput.getOperationId()
+ String resourceModeluuid = resourceInput.getResourceModelInfo().getModelCustomizationUuid()
+ String resourceInstanceId = resourceInput.getResourceInstancenUuid()
+
+
+ execution.setVariable("globalSubscriberId",globalSubscriberId)
+ execution.setVariable("serviceType", serviceType)
+ execution.setVariable("operationId", operationId)
+ execution.setVariable("resourceTemplateId", resourceModeluuid)
+ execution.setVariable("resourceInstanceId", resourceInstanceId)
+
utils.log("INFO"," ***** end preProcessRequest *****", isDebugEnabled)
}
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 b2a7bb6fdf..8508f07765 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
@@ -242,6 +242,8 @@ public class DoDeleteResourcesV1 extends AbstractServiceTaskProcessor {
ResourceInput resourceInput = new ResourceInput();
resourceInput.setServiceInstanceId(serviceInstanceId)
resourceInput.setResourceInstanceName(currentResource.getResourceInstanceName())
+ resourceInput.setResourceInstancenUuid(currentResource.getResourceId())
+ resourceInput.setOperationId(execution.getVariable("operationId"))
String globalSubscriberId = execution.getVariable("globalSubscriberId")
resourceInput.setGlobalSubscriberId(globalSubscriberId)
resourceInput.setResourceModelInfo(currentResource.getModelInfo());