From b4eec19d67a562762b5198f0c9d8dc283f66511b Mon Sep 17 00:00:00 2001 From: subhash kumar singh Date: Mon, 6 May 2019 10:37:09 +0530 Subject: Invoke prepare instance resource list from bpmn Invoke prepare instance resource list from bpmn. Change-Id: I9a116eaee3800bfc061f986e0e5aea75d2f88598 Issue-ID: SO-1393 Signed-off-by: subhash kumar singh --- .../bpmn/infrastructure/scripts/DoCreateResources.groovy | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) (limited to 'bpmn/so-bpmn-infrastructure-common/src/main/groovy/org/onap') diff --git a/bpmn/so-bpmn-infrastructure-common/src/main/groovy/org/onap/so/bpmn/infrastructure/scripts/DoCreateResources.groovy b/bpmn/so-bpmn-infrastructure-common/src/main/groovy/org/onap/so/bpmn/infrastructure/scripts/DoCreateResources.groovy index 0240beab9a..fd698d486f 100644 --- a/bpmn/so-bpmn-infrastructure-common/src/main/groovy/org/onap/so/bpmn/infrastructure/scripts/DoCreateResources.groovy +++ b/bpmn/so-bpmn-infrastructure-common/src/main/groovy/org/onap/so/bpmn/infrastructure/scripts/DoCreateResources.groovy @@ -209,11 +209,11 @@ public class DoCreateResources extends AbstractServiceTaskProcessor{ public void getCurrentResoure(DelegateExecution execution){ logger.trace("Start getCurrentResoure Process ") def currentIndex = execution.getVariable("currentResourceIndex") - List sequencedResourceList = execution.getVariable("sequencedResourceList") - Resource currentResource = sequencedResourceList.get(currentIndex) + List instanceResourceList = execution.getVariable("instanceResourceList") + Resource currentResource = instanceResourceList.get(currentIndex) execution.setVariable("resourceType", currentResource.getModelInfo().getModelName()) - logger.info("Now we deal with resouce:" + currentResource.getModelInfo().getModelName()) - logger.trace("COMPLETED getCurrentResoure Process ") + logger.info("Now we deal with resource:" + currentResource.getModelInfo().getModelName()) + logger.trace("COMPLETED getCurrentResource Process ") } public void parseNextResource(DelegateExecution execution){ @@ -221,8 +221,8 @@ public class DoCreateResources extends AbstractServiceTaskProcessor{ def currentIndex = execution.getVariable("currentResourceIndex") def nextIndex = currentIndex + 1 execution.setVariable("currentResourceIndex", nextIndex) - List sequencedResourceList = execution.getVariable("sequencedResourceList") - if(nextIndex >= sequencedResourceList.size()){ + List instanceResourceList = execution.getVariable("instanceResourceList") + if(nextIndex >= instanceResourceList.size()){ execution.setVariable("allResourceFinished", "true") }else{ execution.setVariable("allResourceFinished", "false") @@ -249,7 +249,7 @@ public class DoCreateResources extends AbstractServiceTaskProcessor{ resourceInput.setOperationId(operationId) resourceInput.setOperationType(operationType); def currentIndex = execution.getVariable("currentResourceIndex") - List sequencedResourceList = execution.getVariable("sequencedResourceList") + List sequencedResourceList = execution.getVariable("instanceResourceList") Resource currentResource = sequencedResourceList.get(currentIndex) resourceInput.setResourceModelInfo(currentResource.getModelInfo()); ServiceDecomposition serviceDecomposition = execution.getVariable("serviceDecomposition") -- cgit 1.2.3-korg