From 19efd68c8f8babdaf8a2eb7f78b4522940339da2 Mon Sep 17 00:00:00 2001 From: Elena Kuleshov Date: Wed, 28 Mar 2018 11:25:31 -0400 Subject: ControllerType update for CM flows Change-Id: I42c60ba45baaf29fa5fe54a8bb7ffc0aab5622c7 Signed-off-by: Elena Kuleshov Issue-ID: SO-526 --- .../mso/bpmn/infrastructure/scripts/ReplaceVnfInfra.groovy | 8 +++++++- .../mso/bpmn/infrastructure/scripts/UpdateVnfInfra.groovy | 8 +++++++- .../mso/bpmn/infrastructure/scripts/VnfConfigUpdate.groovy | 10 ++++++++-- .../mso/bpmn/infrastructure/scripts/VnfInPlaceUpdate.groovy | 8 +++++++- 4 files changed, 29 insertions(+), 5 deletions(-) (limited to 'bpmn/MSOInfrastructureBPMN/src/main/groovy/org/openecomp') diff --git a/bpmn/MSOInfrastructureBPMN/src/main/groovy/org/openecomp/mso/bpmn/infrastructure/scripts/ReplaceVnfInfra.groovy b/bpmn/MSOInfrastructureBPMN/src/main/groovy/org/openecomp/mso/bpmn/infrastructure/scripts/ReplaceVnfInfra.groovy index c84c73cb96..a9cc776ab6 100644 --- a/bpmn/MSOInfrastructureBPMN/src/main/groovy/org/openecomp/mso/bpmn/infrastructure/scripts/ReplaceVnfInfra.groovy +++ b/bpmn/MSOInfrastructureBPMN/src/main/groovy/org/openecomp/mso/bpmn/infrastructure/scripts/ReplaceVnfInfra.groovy @@ -76,6 +76,7 @@ public class ReplaceVnfInfra extends VnfCmBase { execution.setVariable('vnfInputs', null) execution.setVariable('tenantId', null) execution.setVariable('vnfParams', null) + execution.setVariable('controllerType', null) execution.setVariable('cloudConfiguration', null) execution.setVariable('ReplaceVnfSuccessIndicator', false) execution.setVariable('serviceType', null) @@ -164,7 +165,12 @@ public class ReplaceVnfInfra extends VnfCmBase { logDebug("vnfModelInvariantUuid: " + vnfModelInvariantUuid, isDebugLogEnabled) def vnfType = execution.getVariable('vnfType') - execution.setVariable('vnfType', vnfType) + execution.setVariable('vnfType', vnfType) + + def controllerType = reqMap.requestDetails?.requestParameters?.controllerType + execution.setVariable('controllerType', controllerType) + + utils.log("DEBUG", 'Controller Type: ' + controllerType, isDebugLogEnabled) def userParams = reqMap.requestDetails?.requestParameters?.userParams diff --git a/bpmn/MSOInfrastructureBPMN/src/main/groovy/org/openecomp/mso/bpmn/infrastructure/scripts/UpdateVnfInfra.groovy b/bpmn/MSOInfrastructureBPMN/src/main/groovy/org/openecomp/mso/bpmn/infrastructure/scripts/UpdateVnfInfra.groovy index b6af0a5a6b..0b6ddb8ad2 100644 --- a/bpmn/MSOInfrastructureBPMN/src/main/groovy/org/openecomp/mso/bpmn/infrastructure/scripts/UpdateVnfInfra.groovy +++ b/bpmn/MSOInfrastructureBPMN/src/main/groovy/org/openecomp/mso/bpmn/infrastructure/scripts/UpdateVnfInfra.groovy @@ -74,7 +74,8 @@ public class UpdateVnfInfra extends VnfCmBase { execution.setVariable('source', null) execution.setVariable('vnfInputs', null) execution.setVariable('tenantId', null) - execution.setVariable('vnfParams', null) + execution.setVariable('vnfParams', null) + execution.setVariable('controllerType', null) execution.setVariable('UpdateVnfSuccessIndicator', false) execution.setVariable('serviceType', null) execution.setVariable('nfRole', null) @@ -154,6 +155,11 @@ public class UpdateVnfInfra extends VnfCmBase { def vnfType = execution.getVariable('vnfType') execution.setVariable('vnfType', vnfType) + def controllerType = reqMap.requestDetails?.requestParameters?.controllerType + execution.setVariable('controllerType', controllerType) + + utils.log("DEBUG", 'Controller Type: ' + controllerType, isDebugLogEnabled) + def userParams = reqMap.requestDetails?.requestParameters?.userParams Map userParamsMap = [:] diff --git a/bpmn/MSOInfrastructureBPMN/src/main/groovy/org/openecomp/mso/bpmn/infrastructure/scripts/VnfConfigUpdate.groovy b/bpmn/MSOInfrastructureBPMN/src/main/groovy/org/openecomp/mso/bpmn/infrastructure/scripts/VnfConfigUpdate.groovy index 13016a5ae4..aa3320044d 100644 --- a/bpmn/MSOInfrastructureBPMN/src/main/groovy/org/openecomp/mso/bpmn/infrastructure/scripts/VnfConfigUpdate.groovy +++ b/bpmn/MSOInfrastructureBPMN/src/main/groovy/org/openecomp/mso/bpmn/infrastructure/scripts/VnfConfigUpdate.groovy @@ -75,7 +75,8 @@ public class VnfConfigUpdate extends VnfCmBase { public void initProcessVariables(DelegateExecution execution) { execution.setVariable('prefix', 'VnfCU_') execution.setVariable('Request', null) - execution.setVariable('source', null) + execution.setVariable('source', null) + execution.setVariable('controllerType', null) execution.setVariable('UpdateVnfSuccessIndicator', false) execution.setVariable('serviceType', null) execution.setVariable('nfRole', null) @@ -128,7 +129,12 @@ public class VnfConfigUpdate extends VnfCmBase { execution.setVariable('serviceType', 'Mobility') execution.setVariable('payload', "") execution.setVariable('actionHealthCheck', Action.HealthCheck) - execution.setVariable('actionConfigModify', Action.ConfigModify) + execution.setVariable('actionConfigModify', Action.ConfigModify) + + def controllerType = reqMap.requestDetails?.requestParameters?.controllerType + execution.setVariable('controllerType', controllerType) + + utils.log("DEBUG", 'Controller Type: ' + controllerType, isDebugLogEnabled) def payload = reqMap.requestDetails?.requestParameters?.payload execution.setVariable('payload', payload) diff --git a/bpmn/MSOInfrastructureBPMN/src/main/groovy/org/openecomp/mso/bpmn/infrastructure/scripts/VnfInPlaceUpdate.groovy b/bpmn/MSOInfrastructureBPMN/src/main/groovy/org/openecomp/mso/bpmn/infrastructure/scripts/VnfInPlaceUpdate.groovy index 4a64ab058b..64894563bf 100644 --- a/bpmn/MSOInfrastructureBPMN/src/main/groovy/org/openecomp/mso/bpmn/infrastructure/scripts/VnfInPlaceUpdate.groovy +++ b/bpmn/MSOInfrastructureBPMN/src/main/groovy/org/openecomp/mso/bpmn/infrastructure/scripts/VnfInPlaceUpdate.groovy @@ -80,7 +80,8 @@ public class VnfInPlaceUpdate extends VnfCmBase { execution.setVariable('source', null) execution.setVariable('vnfInputs', null) execution.setVariable('tenantId', null) - execution.setVariable('vnfParams', null) + execution.setVariable('vnfParams', null) + execution.setVariable('controllerType', null) execution.setVariable('UpdateVnfSuccessIndicator', false) execution.setVariable('serviceType', null) execution.setVariable('nfRole', null) @@ -140,6 +141,11 @@ public class VnfInPlaceUpdate extends VnfCmBase { execution.setVariable('actionUpgradeBackup', Action.UpgradeBackup) execution.setVariable('actionUpgradeSoftware', Action.UpgradeSoftware) execution.setVariable('actionResumeTraffic', Action.ResumeTraffic) + + def controllerType = reqMap.requestDetails?.requestParameters?.controllerType + execution.setVariable('controllerType', controllerType) + + utils.log("DEBUG", 'Controller Type: ' + controllerType, isDebugLogEnabled) def payload = reqMap.requestDetails?.requestParameters?.payload execution.setVariable('payload', payload) -- cgit 1.2.3-korg