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 +++++++- .../src/main/resources/process/ReplaceVnfInfra.bpmn | 11 +++++++++-- .../src/main/resources/process/UpdateVnfInfra.bpmn | 9 ++++++++- .../src/main/resources/process/VnfConfigUpdate.bpmn | 7 ++++++- .../src/main/resources/process/VnfInPlaceUpdate.bpmn | 13 ++++++++++++- .../src/main/resources/subprocess/RollbackVnf.bpmn | 5 ++++- .../__files/InfrastructureFlows/ConfigVnf_VID_request.json | 1 + .../__files/InfrastructureFlows/ReplaceVnf_VID_request.json | 1 + .../__files/InfrastructureFlows/UpdateVnf_VID_request.json | 1 + .../InfrastructureFlows/VnfInPlaceUpdate_VID_request.json | 1 + .../src/test/resources/mso.bpmn.urn.properties | 4 +++- 14 files changed, 75 insertions(+), 12 deletions(-) (limited to 'bpmn/MSOInfrastructureBPMN/src') 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) diff --git a/bpmn/MSOInfrastructureBPMN/src/main/resources/process/ReplaceVnfInfra.bpmn b/bpmn/MSOInfrastructureBPMN/src/main/resources/process/ReplaceVnfInfra.bpmn index c15c391558..0e849a8a7b 100644 --- a/bpmn/MSOInfrastructureBPMN/src/main/resources/process/ReplaceVnfInfra.bpmn +++ b/bpmn/MSOInfrastructureBPMN/src/main/resources/process/ReplaceVnfInfra.bpmn @@ -1,5 +1,5 @@ - + SequenceFlow_5 @@ -109,6 +109,7 @@ uvfm.postProcessRollback(execution)]]> + SequenceFlow_0msgw6c SequenceFlow_0uhssvq @@ -394,7 +395,8 @@ uvfm.prepDoCreateVnfAndModules(execution)]]> - + + SequenceFlow_1bkhs8m SequenceFlow_1qfjlt7 @@ -414,6 +416,7 @@ uvfm.prepDoCreateVnfAndModules(execution)]]> + SequenceFlow_0qy68ib SequenceFlow_0x7iupc @@ -431,6 +434,7 @@ uvfm.prepDoCreateVnfAndModules(execution)]]> + SequenceFlow_0q0qan8 SequenceFlow_0hp0w6k @@ -448,6 +452,7 @@ uvfm.prepDoCreateVnfAndModules(execution)]]> + SequenceFlow_04zwhw4 SequenceFlow_1lrbndo @@ -467,6 +472,7 @@ uvfm.prepDoCreateVnfAndModules(execution)]]> + SequenceFlow_162mm0m SequenceFlow_14mblvp @@ -574,6 +580,7 @@ uvfm.prepDoCreateVnfAndModules(execution)]]> + SequenceFlow_197t3qk SequenceFlow_18e0jz0 diff --git a/bpmn/MSOInfrastructureBPMN/src/main/resources/process/UpdateVnfInfra.bpmn b/bpmn/MSOInfrastructureBPMN/src/main/resources/process/UpdateVnfInfra.bpmn index fa58c0b21b..4b805f87ab 100644 --- a/bpmn/MSOInfrastructureBPMN/src/main/resources/process/UpdateVnfInfra.bpmn +++ b/bpmn/MSOInfrastructureBPMN/src/main/resources/process/UpdateVnfInfra.bpmn @@ -1,5 +1,5 @@ - + SequenceFlow_5 @@ -109,6 +109,7 @@ uvfm.postProcessRollback(execution)]]> + SequenceFlow_0a0lfh8 SequenceFlow_0r0o5yt @@ -366,6 +367,7 @@ uvfm.prepDoUpdateVnfAndModules(execution)]]> + SequenceFlow_1bkhs8m SequenceFlow_0qmpjgv @@ -385,6 +387,7 @@ uvfm.prepDoUpdateVnfAndModules(execution)]]> + SequenceFlow_0qy68ib SequenceFlow_0tld38t @@ -402,6 +405,7 @@ uvfm.prepDoUpdateVnfAndModules(execution)]]> + SequenceFlow_0q0qan8 SequenceFlow_08dyt3l @@ -419,6 +423,7 @@ uvfm.prepDoUpdateVnfAndModules(execution)]]> + SequenceFlow_04zwhw4 SequenceFlow_0ye8oij @@ -438,6 +443,7 @@ uvfm.prepDoUpdateVnfAndModules(execution)]]> + SequenceFlow_162mm0m SequenceFlow_08kn9ok @@ -454,6 +460,7 @@ uvfm.prepDoUpdateVnfAndModules(execution)]]> + SequenceFlow_197t3qk SequenceFlow_02uiht9 diff --git a/bpmn/MSOInfrastructureBPMN/src/main/resources/process/VnfConfigUpdate.bpmn b/bpmn/MSOInfrastructureBPMN/src/main/resources/process/VnfConfigUpdate.bpmn index 5915b9b592..01307b35b7 100644 --- a/bpmn/MSOInfrastructureBPMN/src/main/resources/process/VnfConfigUpdate.bpmn +++ b/bpmn/MSOInfrastructureBPMN/src/main/resources/process/VnfConfigUpdate.bpmn @@ -1,5 +1,5 @@ - + SequenceFlow_5 @@ -109,6 +109,7 @@ uvfm.postProcessRollback(execution)]]> + SequenceFlow_1vxpbd0 SequenceFlow_03ayqeh @@ -562,6 +563,7 @@ uvfm.setClosedLoopDisabledInAAI(execution, false) + SequenceFlow_1cjiv6i SequenceFlow_1colra4 @@ -581,6 +583,7 @@ uvfm.setClosedLoopDisabledInAAI(execution, false) + SequenceFlow_16igl7b SequenceFlow_0q1skau @@ -597,6 +600,7 @@ uvfm.setClosedLoopDisabledInAAI(execution, false) + SequenceFlow_188a7lk SequenceFlow_1wqinjh @@ -644,6 +648,7 @@ execution.getVariable(retryVariableName) < execution.getVariable("maxRetryCount" + SequenceFlow_1qr8msw SequenceFlow_18lemf9 diff --git a/bpmn/MSOInfrastructureBPMN/src/main/resources/process/VnfInPlaceUpdate.bpmn b/bpmn/MSOInfrastructureBPMN/src/main/resources/process/VnfInPlaceUpdate.bpmn index b6361aaa20..362eb1ac05 100644 --- a/bpmn/MSOInfrastructureBPMN/src/main/resources/process/VnfInPlaceUpdate.bpmn +++ b/bpmn/MSOInfrastructureBPMN/src/main/resources/process/VnfInPlaceUpdate.bpmn @@ -1,5 +1,5 @@ - + SequenceFlow_5 @@ -95,6 +95,7 @@ uvfm.falloutHandlerPrep(execution, 'FalloutHandlerRequest') + SequenceFlow_0hvg70o SequenceFlow_1qnzi6i @@ -718,6 +719,7 @@ uvfm.setClosedLoopDisabledInAAI(execution, false) + SequenceFlow_1c0vdki SequenceFlow_0if6xj4 @@ -734,6 +736,7 @@ uvfm.setClosedLoopDisabledInAAI(execution, false) + SequenceFlow_1cjiv6i SequenceFlow_1ood2pr @@ -750,6 +753,7 @@ uvfm.setClosedLoopDisabledInAAI(execution, false) + SequenceFlow_1q3bwlt SequenceFlow_1hwtq9x @@ -767,6 +771,7 @@ uvfm.setClosedLoopDisabledInAAI(execution, false) + SequenceFlow_0qy68ib SequenceFlow_16t9vai @@ -784,6 +789,7 @@ uvfm.setClosedLoopDisabledInAAI(execution, false) + SequenceFlow_162mm0m SequenceFlow_16igl7b @@ -842,6 +848,7 @@ execution.getVariable(retryVariableName) < execution.getVariable("maxRetryCount" + SequenceFlow_1qr8msw SequenceFlow_0syfgbo @@ -860,6 +867,7 @@ execution.getVariable(retryVariableName) < execution.getVariable("maxRetryCount" + SequenceFlow_0q0qan8 SequenceFlow_1urt6le @@ -877,6 +885,7 @@ execution.getVariable(retryVariableName) < execution.getVariable("maxRetryCount" + SequenceFlow_1fuaq5k SequenceFlow_1v59be9 @@ -894,6 +903,7 @@ execution.getVariable(retryVariableName) < execution.getVariable("maxRetryCount" + SequenceFlow_0txgesu SequenceFlow_1colra4 @@ -912,6 +922,7 @@ execution.getVariable(retryVariableName) < execution.getVariable("maxRetryCount" + SequenceFlow_1c2xyhk SequenceFlow_0yja56j diff --git a/bpmn/MSOInfrastructureBPMN/src/main/resources/subprocess/RollbackVnf.bpmn b/bpmn/MSOInfrastructureBPMN/src/main/resources/subprocess/RollbackVnf.bpmn index 2fa1fa932c..4d1ccf9c8d 100644 --- a/bpmn/MSOInfrastructureBPMN/src/main/resources/subprocess/RollbackVnf.bpmn +++ b/bpmn/MSOInfrastructureBPMN/src/main/resources/subprocess/RollbackVnf.bpmn @@ -1,5 +1,5 @@ - + SequenceFlow_0bie3cu @@ -63,6 +63,7 @@ uvfm.preProcessRequest(execution) + SequenceFlow_1lne8je SequenceFlow_1ney8l6 @@ -74,6 +75,7 @@ uvfm.preProcessRequest(execution) + SequenceFlow_0gsro0z SequenceFlow_11556y3 @@ -128,6 +130,7 @@ uvfm.setRollbackResult(execution) + SequenceFlow_05ihl7f SequenceFlow_1pirwg0 diff --git a/bpmn/MSOInfrastructureBPMN/src/test/resources/__files/InfrastructureFlows/ConfigVnf_VID_request.json b/bpmn/MSOInfrastructureBPMN/src/test/resources/__files/InfrastructureFlows/ConfigVnf_VID_request.json index 04040028c3..3fc25944f2 100644 --- a/bpmn/MSOInfrastructureBPMN/src/test/resources/__files/InfrastructureFlows/ConfigVnf_VID_request.json +++ b/bpmn/MSOInfrastructureBPMN/src/test/resources/__files/InfrastructureFlows/ConfigVnf_VID_request.json @@ -33,6 +33,7 @@ } ], "requestParameters": { +"controllerType" : "appc", "payload": "{\"request-parameters\":{\"host-ip-address\":\"10.10.10.10\"},\"configuration- parameters\":{\"name1\":\"value1\",\"name2\":\"value2\"}}" } } diff --git a/bpmn/MSOInfrastructureBPMN/src/test/resources/__files/InfrastructureFlows/ReplaceVnf_VID_request.json b/bpmn/MSOInfrastructureBPMN/src/test/resources/__files/InfrastructureFlows/ReplaceVnf_VID_request.json index 7c9717244b..a018f50355 100644 --- a/bpmn/MSOInfrastructureBPMN/src/test/resources/__files/InfrastructureFlows/ReplaceVnf_VID_request.json +++ b/bpmn/MSOInfrastructureBPMN/src/test/resources/__files/InfrastructureFlows/ReplaceVnf_VID_request.json @@ -34,6 +34,7 @@ ], "requestParameters": { "usePreload": false, +"controllerType" : "appc", "userParams" : [ { "name" : "someUserParam", diff --git a/bpmn/MSOInfrastructureBPMN/src/test/resources/__files/InfrastructureFlows/UpdateVnf_VID_request.json b/bpmn/MSOInfrastructureBPMN/src/test/resources/__files/InfrastructureFlows/UpdateVnf_VID_request.json index 40e7b598c0..e6d3e97a5c 100644 --- a/bpmn/MSOInfrastructureBPMN/src/test/resources/__files/InfrastructureFlows/UpdateVnf_VID_request.json +++ b/bpmn/MSOInfrastructureBPMN/src/test/resources/__files/InfrastructureFlows/UpdateVnf_VID_request.json @@ -34,6 +34,7 @@ ], "requestParameters": { "usePreload": false, +"controllerType" : "appc", "userParams" : [ { "name" : "someUserParam", diff --git a/bpmn/MSOInfrastructureBPMN/src/test/resources/__files/InfrastructureFlows/VnfInPlaceUpdate_VID_request.json b/bpmn/MSOInfrastructureBPMN/src/test/resources/__files/InfrastructureFlows/VnfInPlaceUpdate_VID_request.json index 009db93d68..588ef1cbec 100644 --- a/bpmn/MSOInfrastructureBPMN/src/test/resources/__files/InfrastructureFlows/VnfInPlaceUpdate_VID_request.json +++ b/bpmn/MSOInfrastructureBPMN/src/test/resources/__files/InfrastructureFlows/VnfInPlaceUpdate_VID_request.json @@ -9,6 +9,7 @@ "requestorId": "ab1234" }, "requestParameters": { +"controllerType": "", "payload": "{\"existing-software-version\": \"3.1\",\"new-software-version\": \"3.2\", \"operations-timeout\": \"3600\"}" } diff --git a/bpmn/MSOInfrastructureBPMN/src/test/resources/mso.bpmn.urn.properties b/bpmn/MSOInfrastructureBPMN/src/test/resources/mso.bpmn.urn.properties index 2e5a199cdb..245d753f3e 100644 --- a/bpmn/MSOInfrastructureBPMN/src/test/resources/mso.bpmn.urn.properties +++ b/bpmn/MSOInfrastructureBPMN/src/test/resources/mso.bpmn.urn.properties @@ -106,6 +106,7 @@ log.debug.CreateGenericALaCarteServiceInstance=true log.debug.DecomposeService=true log.debug.DoCreateServiceInstance=true log.debug.DoDeleteServiceInstance=true +log.debug.VnfInPlaceUpdate=true policy.client.auth=Basic bTAzNzQzOnBvbGljeVIwY2sk policy.auth=Basic dGVzdHBkcDphbHBoYTEyMw== @@ -117,9 +118,10 @@ appc.topic.read=APPC-CL-FUSION-LCM-RESPONSE appc.topic.read.timeout=100 appc.client.response.timeout=300 appc.topic.write=APPC-CL-FUSION-LCM -appc.pool.members=localhost:28090 +appc.poolMembers=localhost:28090 appc.client.key=iaEMAfjsVsZnraBP appc.client.secret=wcivUjsjXzmGFBfxMmyJu9dz +appc.service=ueb sdnc.si.sv.types=PORT-MIRROR,PPROBES mso.bpmn.optimisticlockingexception.retrycount=3 -- cgit 1.2.3-korg