summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--bpmn/so-bpmn-building-blocks/src/main/resources/subprocess/BuildingBlock/ActivateNetworkBB.bpmn47
-rw-r--r--bpmn/so-bpmn-building-blocks/src/main/resources/subprocess/BuildingBlock/ActivateServiceInstanceBB.bpmn2
-rw-r--r--bpmn/so-bpmn-building-blocks/src/main/resources/subprocess/BuildingBlock/ActivateVfModuleBB.bpmn57
-rw-r--r--bpmn/so-bpmn-building-blocks/src/main/resources/subprocess/BuildingBlock/ActivateVnfBB.bpmn53
-rw-r--r--bpmn/so-bpmn-building-blocks/src/main/resources/subprocess/BuildingBlock/AssignNetworkBB.bpmn47
-rw-r--r--bpmn/so-bpmn-building-blocks/src/main/resources/subprocess/BuildingBlock/AssignServiceInstanceBB.bpmn57
-rw-r--r--bpmn/so-bpmn-building-blocks/src/main/resources/subprocess/BuildingBlock/AssignVfModuleBB.bpmn69
-rw-r--r--bpmn/so-bpmn-building-blocks/src/main/resources/subprocess/BuildingBlock/ChangeModelServiceInstanceBB.bpmn53
-rw-r--r--bpmn/so-bpmn-building-blocks/src/main/resources/subprocess/BuildingBlock/ChangeModelVfModuleBB.bpmn57
-rw-r--r--bpmn/so-bpmn-building-blocks/src/main/resources/subprocess/BuildingBlock/ChangeModelVnfBB.bpmn53
-rw-r--r--bpmn/so-bpmn-building-blocks/src/main/resources/subprocess/BuildingBlock/DeactivateNetworkBB.bpmn59
-rw-r--r--bpmn/so-bpmn-building-blocks/src/main/resources/subprocess/BuildingBlock/DeactivateServiceInstanceBB.bpmn53
-rw-r--r--bpmn/so-bpmn-building-blocks/src/main/resources/subprocess/BuildingBlock/DeactivateVfModuleBB.bpmn63
-rw-r--r--bpmn/so-bpmn-building-blocks/src/main/resources/subprocess/BuildingBlock/DeactivateVnfBB.bpmn53
-rw-r--r--bpmn/so-bpmn-building-blocks/src/main/resources/subprocess/BuildingBlock/UnassignNetworkBB.bpmn55
-rw-r--r--bpmn/so-bpmn-building-blocks/src/main/resources/subprocess/BuildingBlock/UnassignServiceInstanceBB.bpmn59
-rw-r--r--bpmn/so-bpmn-building-blocks/src/main/resources/subprocess/BuildingBlock/UnassignVfModuleBB.bpmn51
-rw-r--r--bpmn/so-bpmn-building-blocks/src/main/resources/subprocess/BuildingBlock/UnassignVnfBB.bpmn57
-rw-r--r--bpmn/so-bpmn-building-blocks/src/test/java/org/onap/so/bpmn/infrastructure/bpmn/subprocess/ActivateNetworkBBTest.java4
-rw-r--r--bpmn/so-bpmn-building-blocks/src/test/java/org/onap/so/bpmn/infrastructure/bpmn/subprocess/ActivateVfModuleBBTest.java10
-rw-r--r--bpmn/so-bpmn-building-blocks/src/test/java/org/onap/so/bpmn/infrastructure/bpmn/subprocess/ActivateVnfBBTest.java3
-rw-r--r--bpmn/so-bpmn-building-blocks/src/test/java/org/onap/so/bpmn/infrastructure/bpmn/subprocess/AssignNetworkBBTest.java6
-rw-r--r--bpmn/so-bpmn-building-blocks/src/test/java/org/onap/so/bpmn/infrastructure/bpmn/subprocess/AssignServiceInstanceBBTest.java3
-rw-r--r--bpmn/so-bpmn-building-blocks/src/test/java/org/onap/so/bpmn/infrastructure/bpmn/subprocess/AssignVfModuleBBTest.java2
-rw-r--r--bpmn/so-bpmn-building-blocks/src/test/java/org/onap/so/bpmn/infrastructure/bpmn/subprocess/ChangeModelServiceInstanceBBTest.java3
-rw-r--r--bpmn/so-bpmn-building-blocks/src/test/java/org/onap/so/bpmn/infrastructure/bpmn/subprocess/ChangeModelVfModuleBBTest.java3
-rw-r--r--bpmn/so-bpmn-building-blocks/src/test/java/org/onap/so/bpmn/infrastructure/bpmn/subprocess/ChangeModelVnfBBTest.java3
-rw-r--r--bpmn/so-bpmn-building-blocks/src/test/java/org/onap/so/bpmn/infrastructure/bpmn/subprocess/DeactivateNetworkBBTest.java4
-rw-r--r--bpmn/so-bpmn-building-blocks/src/test/java/org/onap/so/bpmn/infrastructure/bpmn/subprocess/DeactivateServiceInstanceBBTest.java9
-rw-r--r--bpmn/so-bpmn-building-blocks/src/test/java/org/onap/so/bpmn/infrastructure/bpmn/subprocess/DeactivateVfModuleBBTest.java4
-rw-r--r--bpmn/so-bpmn-building-blocks/src/test/java/org/onap/so/bpmn/infrastructure/bpmn/subprocess/DeactivateVnfBBTest.java4
-rw-r--r--bpmn/so-bpmn-building-blocks/src/test/java/org/onap/so/bpmn/infrastructure/bpmn/subprocess/DeleteVfModuleBBTest.java1
-rw-r--r--bpmn/so-bpmn-building-blocks/src/test/java/org/onap/so/bpmn/infrastructure/bpmn/subprocess/UnassignNetworkBBTest.java4
-rw-r--r--bpmn/so-bpmn-building-blocks/src/test/java/org/onap/so/bpmn/infrastructure/bpmn/subprocess/UnassignServiceInstanceBBTest.java5
-rw-r--r--bpmn/so-bpmn-building-blocks/src/test/java/org/onap/so/bpmn/infrastructure/bpmn/subprocess/UnassignVfModuleBBTest.java3
-rw-r--r--bpmn/so-bpmn-building-blocks/src/test/java/org/onap/so/bpmn/infrastructure/bpmn/subprocess/UnassignVnfBBTest.java3
-rw-r--r--bpmn/so-bpmn-tasks/src/main/java/org/onap/so/bpmn/infrastructure/sdnc/tasks/SDNCActivateTasks.java46
-rw-r--r--bpmn/so-bpmn-tasks/src/main/java/org/onap/so/bpmn/infrastructure/sdnc/tasks/SDNCAssignTasks.java27
-rw-r--r--bpmn/so-bpmn-tasks/src/main/java/org/onap/so/bpmn/infrastructure/sdnc/tasks/SDNCChangeAssignTasks.java37
-rw-r--r--bpmn/so-bpmn-tasks/src/main/java/org/onap/so/bpmn/infrastructure/sdnc/tasks/SDNCDeactivateTasks.java61
-rw-r--r--bpmn/so-bpmn-tasks/src/main/java/org/onap/so/bpmn/infrastructure/sdnc/tasks/SDNCUnassignTasks.java58
-rw-r--r--bpmn/so-bpmn-tasks/src/main/java/org/onap/so/client/orchestration/SDNCNetworkResources.java113
-rw-r--r--bpmn/so-bpmn-tasks/src/main/java/org/onap/so/client/orchestration/SDNCServiceInstanceResources.java77
-rw-r--r--bpmn/so-bpmn-tasks/src/main/java/org/onap/so/client/orchestration/SDNCVfModuleResources.java77
-rw-r--r--bpmn/so-bpmn-tasks/src/main/java/org/onap/so/client/orchestration/SDNCVnfResources.java44
-rw-r--r--bpmn/so-bpmn-tasks/src/test/java/org/onap/so/bpmn/infrastructure/sdnc/tasks/SDNCActivateTaskTest.java25
-rw-r--r--bpmn/so-bpmn-tasks/src/test/java/org/onap/so/bpmn/infrastructure/sdnc/tasks/SDNCAssignTasksTest.java34
-rw-r--r--bpmn/so-bpmn-tasks/src/test/java/org/onap/so/bpmn/infrastructure/sdnc/tasks/SDNCChangeAssignTasksTest.java28
-rw-r--r--bpmn/so-bpmn-tasks/src/test/java/org/onap/so/bpmn/infrastructure/sdnc/tasks/SDNCDeactivateTaskTest.java60
-rw-r--r--bpmn/so-bpmn-tasks/src/test/java/org/onap/so/bpmn/infrastructure/sdnc/tasks/SDNCUnassignTasksTest.java43
-rw-r--r--bpmn/so-bpmn-tasks/src/test/java/org/onap/so/client/orchestration/SDNCNetworkResourcesTest.java188
-rw-r--r--bpmn/so-bpmn-tasks/src/test/java/org/onap/so/client/orchestration/SDNCServiceInstanceResourcesTest.java49
-rw-r--r--bpmn/so-bpmn-tasks/src/test/java/org/onap/so/client/orchestration/SDNCVfModuleResourcesTest.java74
-rw-r--r--bpmn/so-bpmn-tasks/src/test/java/org/onap/so/client/orchestration/SDNCVnfResourcesTest.java71
54 files changed, 1171 insertions, 960 deletions
diff --git a/bpmn/so-bpmn-building-blocks/src/main/resources/subprocess/BuildingBlock/ActivateNetworkBB.bpmn b/bpmn/so-bpmn-building-blocks/src/main/resources/subprocess/BuildingBlock/ActivateNetworkBB.bpmn
index dc6e4a8d94..78a389a67d 100644
--- a/bpmn/so-bpmn-building-blocks/src/main/resources/subprocess/BuildingBlock/ActivateNetworkBB.bpmn
+++ b/bpmn/so-bpmn-building-blocks/src/main/resources/subprocess/BuildingBlock/ActivateNetworkBB.bpmn
@@ -1,5 +1,5 @@
<?xml version="1.0" encoding="UTF-8"?>
-<bpmn2:definitions xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:bpmn2="http://www.omg.org/spec/BPMN/20100524/MODEL" xmlns:bpmndi="http://www.omg.org/spec/BPMN/20100524/DI" xmlns:camunda="http://camunda.org/schema/1.0/bpmn" xmlns:dc="http://www.omg.org/spec/DD/20100524/DC" xmlns:di="http://www.omg.org/spec/DD/20100524/DI" id="_MagIIMOUEeW8asg-vCEgWQ" targetNamespace="http://camunda.org/schema/1.0/bpmn" exporter="Camunda Modeler" exporterVersion="1.10.0" xsi:schemaLocation="http://www.omg.org/spec/BPMN/20100524/MODEL BPMN20.xsd">
+<bpmn2:definitions xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:bpmn2="http://www.omg.org/spec/BPMN/20100524/MODEL" xmlns:bpmndi="http://www.omg.org/spec/BPMN/20100524/DI" xmlns:camunda="http://camunda.org/schema/1.0/bpmn" xmlns:dc="http://www.omg.org/spec/DD/20100524/DC" xmlns:di="http://www.omg.org/spec/DD/20100524/DI" id="_MagIIMOUEeW8asg-vCEgWQ" targetNamespace="http://camunda.org/schema/1.0/bpmn" exporter="Camunda Modeler" exporterVersion="1.8.2" xsi:schemaLocation="http://www.omg.org/spec/BPMN/20100524/MODEL BPMN20.xsd">
<bpmn2:process id="ActivateNetworkBB" name="ActivateNetworkBB" isExecutable="true">
<bpmn2:startEvent id="activateNetwork_startEvent">
<bpmn2:outgoing>SequenceFlow_05elmhj</bpmn2:outgoing>
@@ -9,15 +9,24 @@
</bpmn2:endEvent>
<bpmn2:serviceTask id="Activate_Network_SDNC_ServiceTask" name="&#10;SDNC&#10;Activate&#10;(network)&#10;" camunda:expression="${SDNCActivateTasks.activateNetwork(InjectExecution.execute(execution, execution.getVariable(&#34;gBuildingBlockExecution&#34;)))}">
<bpmn2:incoming>SequenceFlow_05elmhj</bpmn2:incoming>
- <bpmn2:outgoing>SequenceFlow_0xbvwsu</bpmn2:outgoing>
+ <bpmn2:outgoing>SequenceFlow_0zzlwi7</bpmn2:outgoing>
</bpmn2:serviceTask>
<bpmn2:serviceTask id="Activate_Network_AAI_ServiceTask" name="&#10;AAI&#10;Update&#10;(network)&#10;" camunda:expression="${AAIUpdateTasks.updateOrchestrationStatusActiveNetwork(InjectExecution.execute(execution, execution.getVariable(&#34;gBuildingBlockExecution&#34;)))}">
- <bpmn2:incoming>SequenceFlow_0xbvwsu</bpmn2:incoming>
+ <bpmn2:incoming>SequenceFlow_0wb238v</bpmn2:incoming>
<bpmn2:outgoing>SequenceFlow_18atf08</bpmn2:outgoing>
</bpmn2:serviceTask>
<bpmn2:sequenceFlow id="SequenceFlow_05elmhj" sourceRef="activateNetwork_startEvent" targetRef="Activate_Network_SDNC_ServiceTask" />
- <bpmn2:sequenceFlow id="SequenceFlow_0xbvwsu" sourceRef="Activate_Network_SDNC_ServiceTask" targetRef="Activate_Network_AAI_ServiceTask" />
<bpmn2:sequenceFlow id="SequenceFlow_18atf08" sourceRef="Activate_Network_AAI_ServiceTask" targetRef="activateNetwork_EndEvent" />
+ <bpmn2:callActivity id="CallActivity_sdncHandler" name="SDNC Activate (network)" calledElement="SDNCHandler">
+ <bpmn2:extensionElements>
+ <camunda:in source="SDNCRequest" target="SDNCRequest" />
+ <camunda:out source="SDNCResponse" target="SDNCResponse" />
+ </bpmn2:extensionElements>
+ <bpmn2:incoming>SequenceFlow_0zzlwi7</bpmn2:incoming>
+ <bpmn2:outgoing>SequenceFlow_0wb238v</bpmn2:outgoing>
+ </bpmn2:callActivity>
+ <bpmn2:sequenceFlow id="SequenceFlow_0zzlwi7" sourceRef="Activate_Network_SDNC_ServiceTask" targetRef="CallActivity_sdncHandler" />
+ <bpmn2:sequenceFlow id="SequenceFlow_0wb238v" sourceRef="CallActivity_sdncHandler" targetRef="Activate_Network_AAI_ServiceTask" />
</bpmn2:process>
<bpmn2:error id="Error_2" name="MSOWorkflowException" errorCode="MSOWorkflowException" />
<bpmn2:error id="Error_1" name="java.lang.Exception" errorCode="java.lang.Exception" />
@@ -30,16 +39,16 @@
</bpmndi:BPMNLabel>
</bpmndi:BPMNShape>
<bpmndi:BPMNShape id="EndEvent_10l9a3s_di" bpmnElement="activateNetwork_EndEvent">
- <dc:Bounds x="975" y="-55" width="36" height="36" />
+ <dc:Bounds x="1115" y="-55" width="36" height="36" />
<bpmndi:BPMNLabel>
- <dc:Bounds x="971" y="-19" width="46" height="12" />
+ <dc:Bounds x="1089" y="-19" width="90" height="12" />
</bpmndi:BPMNLabel>
</bpmndi:BPMNShape>
<bpmndi:BPMNShape id="ServiceTask_1k7d8ih_di" bpmnElement="Activate_Network_SDNC_ServiceTask">
<dc:Bounds x="653" y="-77" width="100" height="80" />
</bpmndi:BPMNShape>
<bpmndi:BPMNShape id="ServiceTask_1911vum_di" bpmnElement="Activate_Network_AAI_ServiceTask">
- <dc:Bounds x="802" y="-77" width="100" height="80" />
+ <dc:Bounds x="969" y="-77" width="100" height="80" />
</bpmndi:BPMNShape>
<bpmndi:BPMNEdge id="SequenceFlow_05elmhj_di" bpmnElement="SequenceFlow_05elmhj">
<di:waypoint xsi:type="dc:Point" x="581" y="-37" />
@@ -48,22 +57,28 @@
<dc:Bounds x="617" y="-62" width="0" height="0" />
</bpmndi:BPMNLabel>
</bpmndi:BPMNEdge>
- <bpmndi:BPMNEdge id="SequenceFlow_0xbvwsu_di" bpmnElement="SequenceFlow_0xbvwsu">
+ <bpmndi:BPMNEdge id="SequenceFlow_18atf08_di" bpmnElement="SequenceFlow_18atf08">
+ <di:waypoint xsi:type="dc:Point" x="1069" y="-37" />
+ <di:waypoint xsi:type="dc:Point" x="1115" y="-37" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="1047" y="-52" width="90" height="0" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNEdge>
+ <bpmndi:BPMNShape id="CallActivity_0g1zk8g_di" bpmnElement="CallActivity_sdncHandler">
+ <dc:Bounds x="802" y="-77" width="100" height="80" />
+ </bpmndi:BPMNShape>
+ <bpmndi:BPMNEdge id="SequenceFlow_0zzlwi7_di" bpmnElement="SequenceFlow_0zzlwi7">
<di:waypoint xsi:type="dc:Point" x="753" y="-37" />
- <di:waypoint xsi:type="dc:Point" x="778" y="-37" />
- <di:waypoint xsi:type="dc:Point" x="778" y="-37" />
<di:waypoint xsi:type="dc:Point" x="802" y="-37" />
<bpmndi:BPMNLabel>
- <dc:Bounds x="793" y="-37" width="0" height="0" />
+ <dc:Bounds x="777.5" y="-58" width="0" height="12" />
</bpmndi:BPMNLabel>
</bpmndi:BPMNEdge>
- <bpmndi:BPMNEdge id="SequenceFlow_18atf08_di" bpmnElement="SequenceFlow_18atf08">
+ <bpmndi:BPMNEdge id="SequenceFlow_0wb238v_di" bpmnElement="SequenceFlow_0wb238v">
<di:waypoint xsi:type="dc:Point" x="902" y="-37" />
- <di:waypoint xsi:type="dc:Point" x="939" y="-37" />
- <di:waypoint xsi:type="dc:Point" x="939" y="-37" />
- <di:waypoint xsi:type="dc:Point" x="975" y="-37" />
+ <di:waypoint xsi:type="dc:Point" x="969" y="-37" />
<bpmndi:BPMNLabel>
- <dc:Bounds x="954" y="-37" width="0" height="0" />
+ <dc:Bounds x="935.5" y="-58" width="0" height="12" />
</bpmndi:BPMNLabel>
</bpmndi:BPMNEdge>
</bpmndi:BPMNPlane>
diff --git a/bpmn/so-bpmn-building-blocks/src/main/resources/subprocess/BuildingBlock/ActivateServiceInstanceBB.bpmn b/bpmn/so-bpmn-building-blocks/src/main/resources/subprocess/BuildingBlock/ActivateServiceInstanceBB.bpmn
index 47cd3cf30b..49dc9be58e 100644
--- a/bpmn/so-bpmn-building-blocks/src/main/resources/subprocess/BuildingBlock/ActivateServiceInstanceBB.bpmn
+++ b/bpmn/so-bpmn-building-blocks/src/main/resources/subprocess/BuildingBlock/ActivateServiceInstanceBB.bpmn
@@ -62,4 +62,4 @@
</bpmndi:BPMNEdge>
</bpmndi:BPMNPlane>
</bpmndi:BPMNDiagram>
-</bpmn:definitions>
+</bpmn:definitions> \ No newline at end of file
diff --git a/bpmn/so-bpmn-building-blocks/src/main/resources/subprocess/BuildingBlock/ActivateVfModuleBB.bpmn b/bpmn/so-bpmn-building-blocks/src/main/resources/subprocess/BuildingBlock/ActivateVfModuleBB.bpmn
index c7b7952f02..259a3341c2 100644
--- a/bpmn/so-bpmn-building-blocks/src/main/resources/subprocess/BuildingBlock/ActivateVfModuleBB.bpmn
+++ b/bpmn/so-bpmn-building-blocks/src/main/resources/subprocess/BuildingBlock/ActivateVfModuleBB.bpmn
@@ -1,5 +1,5 @@
<?xml version="1.0" encoding="UTF-8"?>
-<bpmn:definitions xmlns:bpmn="http://www.omg.org/spec/BPMN/20100524/MODEL" xmlns:bpmndi="http://www.omg.org/spec/BPMN/20100524/DI" xmlns:di="http://www.omg.org/spec/DD/20100524/DI" xmlns:dc="http://www.omg.org/spec/DD/20100524/DC" xmlns:camunda="http://camunda.org/schema/1.0/bpmn" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" id="Definitions_1" targetNamespace="http://bpmn.io/schema/bpmn" exporter="Camunda Modeler" exporterVersion="1.10.0">
+<bpmn:definitions xmlns:bpmn="http://www.omg.org/spec/BPMN/20100524/MODEL" xmlns:bpmndi="http://www.omg.org/spec/BPMN/20100524/DI" xmlns:di="http://www.omg.org/spec/DD/20100524/DI" xmlns:dc="http://www.omg.org/spec/DD/20100524/DC" xmlns:camunda="http://camunda.org/schema/1.0/bpmn" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" id="Definitions_1" targetNamespace="http://bpmn.io/schema/bpmn" exporter="Camunda Modeler" exporterVersion="1.8.2">
<bpmn:process id="ActivateVfModuleBB" name="ActivateVfModuleBB" isExecutable="true">
<bpmn:startEvent id="ActivateVfModuleBB_Start">
<bpmn:outgoing>SequenceFlow_0ieafii</bpmn:outgoing>
@@ -10,14 +10,23 @@
</bpmn:endEvent>
<bpmn:serviceTask id="ActivateVfModule" name="&#10;SDNC&#10;Activate&#10;(vf module)&#10;" camunda:expression="${SDNCActivateTasks.activateVfModule(InjectExecution.execute(execution, execution.getVariable(&#34;gBuildingBlockExecution&#34;)))}">
<bpmn:incoming>SequenceFlow_0ieafii</bpmn:incoming>
- <bpmn:outgoing>SequenceFlow_14kvrbe</bpmn:outgoing>
+ <bpmn:outgoing>SequenceFlow_1a495wm</bpmn:outgoing>
</bpmn:serviceTask>
- <bpmn:sequenceFlow id="SequenceFlow_14kvrbe" sourceRef="ActivateVfModule" targetRef="UpdateVfModuleActiveStatus" />
<bpmn:serviceTask id="UpdateVfModuleActiveStatus" name="&#10;AAI&#10;Update&#10;(vf module)&#10;" camunda:expression="${AAIUpdateTasks.updateOrchestrationStatusActivateVfModule(InjectExecution.execute(execution, execution.getVariable(&#34;gBuildingBlockExecution&#34;)))}">
- <bpmn:incoming>SequenceFlow_14kvrbe</bpmn:incoming>
+ <bpmn:incoming>SequenceFlow_1j4x1ej</bpmn:incoming>
<bpmn:outgoing>SequenceFlow_0xsp0pv</bpmn:outgoing>
</bpmn:serviceTask>
<bpmn:sequenceFlow id="SequenceFlow_0xsp0pv" sourceRef="UpdateVfModuleActiveStatus" targetRef="ActivateVfModuleBB_End" />
+ <bpmn:callActivity id="CallActivity_sdncHandler" name="SDNC Activate (vfModule)" calledElement="SDNCHandler">
+ <bpmn:extensionElements>
+ <camunda:in source="SDNCRequest" target="SDNCRequest" />
+ <camunda:out source="SDNCResponse" target="SDNCResponse" />
+ </bpmn:extensionElements>
+ <bpmn:incoming>SequenceFlow_1a495wm</bpmn:incoming>
+ <bpmn:outgoing>SequenceFlow_1j4x1ej</bpmn:outgoing>
+ </bpmn:callActivity>
+ <bpmn:sequenceFlow id="SequenceFlow_1a495wm" sourceRef="ActivateVfModule" targetRef="CallActivity_sdncHandler" />
+ <bpmn:sequenceFlow id="SequenceFlow_1j4x1ej" sourceRef="CallActivity_sdncHandler" targetRef="UpdateVfModuleActiveStatus" />
</bpmn:process>
<bpmn:error id="Error_0q258vt" name="gDelegateError" errorCode="7000" />
<bpmndi:BPMNDiagram id="BPMNDiagram_1">
@@ -30,35 +39,45 @@
</bpmndi:BPMNShape>
<bpmndi:BPMNEdge id="SequenceFlow_0ieafii_di" bpmnElement="SequenceFlow_0ieafii">
<di:waypoint xsi:type="dc:Point" x="209" y="120" />
- <di:waypoint xsi:type="dc:Point" x="288" y="120" />
+ <di:waypoint xsi:type="dc:Point" x="262" y="120" />
<bpmndi:BPMNLabel>
- <dc:Bounds x="203.5" y="99" width="90" height="12" />
+ <dc:Bounds x="190.5" y="99" width="90" height="12" />
</bpmndi:BPMNLabel>
</bpmndi:BPMNEdge>
<bpmndi:BPMNShape id="EndEvent_1v967li_di" bpmnElement="ActivateVfModuleBB_End">
- <dc:Bounds x="624" y="102" width="36" height="36" />
+ <dc:Bounds x="736" y="102" width="36" height="36" />
<bpmndi:BPMNLabel>
- <dc:Bounds x="633" y="142" width="19" height="12" />
+ <dc:Bounds x="710" y="142" width="90" height="12" />
</bpmndi:BPMNLabel>
</bpmndi:BPMNShape>
<bpmndi:BPMNShape id="ServiceTask_0hawa84_di" bpmnElement="ActivateVfModule">
- <dc:Bounds x="288" y="80" width="100" height="80" />
+ <dc:Bounds x="262" y="80" width="100" height="80" />
</bpmndi:BPMNShape>
- <bpmndi:BPMNEdge id="SequenceFlow_14kvrbe_di" bpmnElement="SequenceFlow_14kvrbe">
- <di:waypoint xsi:type="dc:Point" x="388" y="120" />
- <di:waypoint xsi:type="dc:Point" x="433" y="120" />
+ <bpmndi:BPMNShape id="ServiceTask_175e9ul_di" bpmnElement="UpdateVfModuleActiveStatus">
+ <dc:Bounds x="600" y="80" width="100" height="80" />
+ </bpmndi:BPMNShape>
+ <bpmndi:BPMNEdge id="SequenceFlow_0xsp0pv_di" bpmnElement="SequenceFlow_0xsp0pv">
+ <di:waypoint xsi:type="dc:Point" x="700" y="120" />
+ <di:waypoint xsi:type="dc:Point" x="736" y="120" />
<bpmndi:BPMNLabel>
- <dc:Bounds x="365.5" y="99" width="90" height="12" />
+ <dc:Bounds x="673" y="99" width="90" height="12" />
</bpmndi:BPMNLabel>
</bpmndi:BPMNEdge>
- <bpmndi:BPMNShape id="ServiceTask_175e9ul_di" bpmnElement="UpdateVfModuleActiveStatus">
- <dc:Bounds x="433" y="80" width="100" height="80" />
+ <bpmndi:BPMNShape id="CallActivity_03jkesd_di" bpmnElement="CallActivity_sdncHandler">
+ <dc:Bounds x="420" y="80" width="100" height="80" />
</bpmndi:BPMNShape>
- <bpmndi:BPMNEdge id="SequenceFlow_0xsp0pv_di" bpmnElement="SequenceFlow_0xsp0pv">
- <di:waypoint xsi:type="dc:Point" x="533" y="120" />
- <di:waypoint xsi:type="dc:Point" x="624" y="120" />
+ <bpmndi:BPMNEdge id="SequenceFlow_1a495wm_di" bpmnElement="SequenceFlow_1a495wm">
+ <di:waypoint xsi:type="dc:Point" x="362" y="120" />
+ <di:waypoint xsi:type="dc:Point" x="420" y="120" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="391" y="99" width="0" height="12" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNEdge>
+ <bpmndi:BPMNEdge id="SequenceFlow_1j4x1ej_di" bpmnElement="SequenceFlow_1j4x1ej">
+ <di:waypoint xsi:type="dc:Point" x="520" y="120" />
+ <di:waypoint xsi:type="dc:Point" x="600" y="120" />
<bpmndi:BPMNLabel>
- <dc:Bounds x="533.5" y="99" width="90" height="12" />
+ <dc:Bounds x="560" y="99" width="0" height="12" />
</bpmndi:BPMNLabel>
</bpmndi:BPMNEdge>
</bpmndi:BPMNPlane>
diff --git a/bpmn/so-bpmn-building-blocks/src/main/resources/subprocess/BuildingBlock/ActivateVnfBB.bpmn b/bpmn/so-bpmn-building-blocks/src/main/resources/subprocess/BuildingBlock/ActivateVnfBB.bpmn
index 1147283160..e1f80dc77a 100644
--- a/bpmn/so-bpmn-building-blocks/src/main/resources/subprocess/BuildingBlock/ActivateVnfBB.bpmn
+++ b/bpmn/so-bpmn-building-blocks/src/main/resources/subprocess/BuildingBlock/ActivateVnfBB.bpmn
@@ -1,23 +1,32 @@
<?xml version="1.0" encoding="UTF-8"?>
-<bpmn:definitions xmlns:bpmn="http://www.omg.org/spec/BPMN/20100524/MODEL" xmlns:bpmndi="http://www.omg.org/spec/BPMN/20100524/DI" xmlns:di="http://www.omg.org/spec/DD/20100524/DI" xmlns:dc="http://www.omg.org/spec/DD/20100524/DC" xmlns:camunda="http://camunda.org/schema/1.0/bpmn" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" id="Definitions_1" targetNamespace="http://bpmn.io/schema/bpmn" exporter="Camunda Modeler" exporterVersion="1.10.0">
+<bpmn:definitions xmlns:bpmn="http://www.omg.org/spec/BPMN/20100524/MODEL" xmlns:bpmndi="http://www.omg.org/spec/BPMN/20100524/DI" xmlns:di="http://www.omg.org/spec/DD/20100524/DI" xmlns:dc="http://www.omg.org/spec/DD/20100524/DC" xmlns:camunda="http://camunda.org/schema/1.0/bpmn" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" id="Definitions_1" targetNamespace="http://bpmn.io/schema/bpmn" exporter="Camunda Modeler" exporterVersion="1.8.2">
<bpmn:process id="ActivateVnfBB" name="ActivateVnfBB" isExecutable="true">
<bpmn:startEvent id="Start_ActivateVnfBB">
<bpmn:outgoing>SequenceFlow_0k9qnoi</bpmn:outgoing>
</bpmn:startEvent>
<bpmn:sequenceFlow id="SequenceFlow_0k9qnoi" sourceRef="Start_ActivateVnfBB" targetRef="Task_SDNCAdapterVnfTopologyActivate" />
- <bpmn:sequenceFlow id="SequenceFlow_0r6pzwt" sourceRef="Task_SDNCAdapterVnfTopologyActivate" targetRef="Task_ActivateOrchestrationStatusVnf" />
<bpmn:endEvent id="End_ActivateVnfBB">
<bpmn:incoming>SequenceFlow_0vnitwg</bpmn:incoming>
</bpmn:endEvent>
<bpmn:sequenceFlow id="SequenceFlow_0vnitwg" sourceRef="Task_ActivateOrchestrationStatusVnf" targetRef="End_ActivateVnfBB" />
<bpmn:serviceTask id="Task_SDNCAdapterVnfTopologyActivate" name="&#10;SDNC&#10;Activate&#10;(vnf)&#10;" camunda:expression="${SDNCActivateTasks.activateVnf(InjectExecution.execute(execution, execution.getVariable(&#34;gBuildingBlockExecution&#34;)))}">
<bpmn:incoming>SequenceFlow_0k9qnoi</bpmn:incoming>
- <bpmn:outgoing>SequenceFlow_0r6pzwt</bpmn:outgoing>
+ <bpmn:outgoing>SequenceFlow_0wk5e4o</bpmn:outgoing>
</bpmn:serviceTask>
<bpmn:serviceTask id="Task_ActivateOrchestrationStatusVnf" name="&#10;AAI&#10;Update&#10;(vnf)&#10;" camunda:expression="${AAIUpdateTasks.updateOrchestrationStatusActiveVnf(InjectExecution.execute(execution, execution.getVariable(&#34;gBuildingBlockExecution&#34;)))}">
- <bpmn:incoming>SequenceFlow_0r6pzwt</bpmn:incoming>
+ <bpmn:incoming>SequenceFlow_0ho00ja</bpmn:incoming>
<bpmn:outgoing>SequenceFlow_0vnitwg</bpmn:outgoing>
</bpmn:serviceTask>
+ <bpmn:callActivity id="CallActivity_sdncHandler" name="SDNC Activate (vnf)" calledElement="SDNCHandler">
+ <bpmn:extensionElements>
+ <camunda:in source="SDNCRequest" target="SDNCRequest" />
+ <camunda:out source="SDNCResponse" target="SDNCResponse" />
+ </bpmn:extensionElements>
+ <bpmn:incoming>SequenceFlow_0wk5e4o</bpmn:incoming>
+ <bpmn:outgoing>SequenceFlow_0ho00ja</bpmn:outgoing>
+ </bpmn:callActivity>
+ <bpmn:sequenceFlow id="SequenceFlow_0wk5e4o" sourceRef="Task_SDNCAdapterVnfTopologyActivate" targetRef="CallActivity_sdncHandler" />
+ <bpmn:sequenceFlow id="SequenceFlow_0ho00ja" sourceRef="CallActivity_sdncHandler" targetRef="Task_ActivateOrchestrationStatusVnf" />
</bpmn:process>
<bpmndi:BPMNDiagram id="BPMNDiagram_1">
<bpmndi:BPMNPlane id="BPMNPlane_1" bpmnElement="ActivateVnfBB">
@@ -34,32 +43,42 @@
<dc:Bounds x="199" y="99" width="90" height="12" />
</bpmndi:BPMNLabel>
</bpmndi:BPMNEdge>
- <bpmndi:BPMNEdge id="SequenceFlow_0r6pzwt_di" bpmnElement="SequenceFlow_0r6pzwt">
- <di:waypoint xsi:type="dc:Point" x="379" y="120" />
- <di:waypoint xsi:type="dc:Point" x="411" y="120" />
- <bpmndi:BPMNLabel>
- <dc:Bounds x="350" y="99" width="90" height="12" />
- </bpmndi:BPMNLabel>
- </bpmndi:BPMNEdge>
<bpmndi:BPMNShape id="EndEvent_1ad7eym_di" bpmnElement="End_ActivateVnfBB">
- <dc:Bounds x="580" y="102" width="36" height="36" />
+ <dc:Bounds x="726" y="102" width="36" height="36" />
<bpmndi:BPMNLabel>
- <dc:Bounds x="589" y="142" width="18" height="12" />
+ <dc:Bounds x="699" y="142" width="90" height="12" />
</bpmndi:BPMNLabel>
</bpmndi:BPMNShape>
<bpmndi:BPMNEdge id="SequenceFlow_0vnitwg_di" bpmnElement="SequenceFlow_0vnitwg">
- <di:waypoint xsi:type="dc:Point" x="511" y="120" />
- <di:waypoint xsi:type="dc:Point" x="580" y="120" />
+ <di:waypoint xsi:type="dc:Point" x="663" y="120" />
+ <di:waypoint xsi:type="dc:Point" x="726" y="120" />
<bpmndi:BPMNLabel>
- <dc:Bounds x="500.5" y="99" width="90" height="12" />
+ <dc:Bounds x="649.5" y="99" width="90" height="12" />
</bpmndi:BPMNLabel>
</bpmndi:BPMNEdge>
<bpmndi:BPMNShape id="ServiceTask_1k98q3r_di" bpmnElement="Task_SDNCAdapterVnfTopologyActivate">
<dc:Bounds x="279" y="80" width="100" height="80" />
</bpmndi:BPMNShape>
<bpmndi:BPMNShape id="ServiceTask_1vg25fs_di" bpmnElement="Task_ActivateOrchestrationStatusVnf">
- <dc:Bounds x="411" y="80" width="100" height="80" />
+ <dc:Bounds x="563" y="80" width="100" height="80" />
+ </bpmndi:BPMNShape>
+ <bpmndi:BPMNShape id="CallActivity_1j8aadu_di" bpmnElement="CallActivity_sdncHandler">
+ <dc:Bounds x="418" y="80" width="100" height="80" />
</bpmndi:BPMNShape>
+ <bpmndi:BPMNEdge id="SequenceFlow_0wk5e4o_di" bpmnElement="SequenceFlow_0wk5e4o">
+ <di:waypoint xsi:type="dc:Point" x="379" y="120" />
+ <di:waypoint xsi:type="dc:Point" x="418" y="120" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="398.5" y="99" width="0" height="12" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNEdge>
+ <bpmndi:BPMNEdge id="SequenceFlow_0ho00ja_di" bpmnElement="SequenceFlow_0ho00ja">
+ <di:waypoint xsi:type="dc:Point" x="518" y="120" />
+ <di:waypoint xsi:type="dc:Point" x="563" y="120" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="540.5" y="99" width="0" height="12" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNEdge>
</bpmndi:BPMNPlane>
</bpmndi:BPMNDiagram>
</bpmn:definitions>
diff --git a/bpmn/so-bpmn-building-blocks/src/main/resources/subprocess/BuildingBlock/AssignNetworkBB.bpmn b/bpmn/so-bpmn-building-blocks/src/main/resources/subprocess/BuildingBlock/AssignNetworkBB.bpmn
index 5f7b29b3ab..967e01885c 100644
--- a/bpmn/so-bpmn-building-blocks/src/main/resources/subprocess/BuildingBlock/AssignNetworkBB.bpmn
+++ b/bpmn/so-bpmn-building-blocks/src/main/resources/subprocess/BuildingBlock/AssignNetworkBB.bpmn
@@ -1,5 +1,5 @@
<?xml version="1.0" encoding="UTF-8"?>
-<bpmn2:definitions xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:bpmn2="http://www.omg.org/spec/BPMN/20100524/MODEL" xmlns:bpmndi="http://www.omg.org/spec/BPMN/20100524/DI" xmlns:camunda="http://camunda.org/schema/1.0/bpmn" xmlns:dc="http://www.omg.org/spec/DD/20100524/DC" xmlns:di="http://www.omg.org/spec/DD/20100524/DI" id="_MagIIMOUEeW8asg-vCEgWQ" targetNamespace="http://camunda.org/schema/1.0/bpmn" exporter="Camunda Modeler" exporterVersion="1.10.0" xsi:schemaLocation="http://www.omg.org/spec/BPMN/20100524/MODEL BPMN20.xsd">
+<bpmn2:definitions xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:bpmn2="http://www.omg.org/spec/BPMN/20100524/MODEL" xmlns:bpmndi="http://www.omg.org/spec/BPMN/20100524/DI" xmlns:camunda="http://camunda.org/schema/1.0/bpmn" xmlns:dc="http://www.omg.org/spec/DD/20100524/DC" xmlns:di="http://www.omg.org/spec/DD/20100524/DI" id="_MagIIMOUEeW8asg-vCEgWQ" targetNamespace="http://camunda.org/schema/1.0/bpmn" exporter="Camunda Modeler" exporterVersion="1.8.2" xsi:schemaLocation="http://www.omg.org/spec/BPMN/20100524/MODEL BPMN20.xsd">
<bpmn2:process id="AssignNetworkBB" name="AssignNetworkBB" isExecutable="true">
<bpmn2:startEvent id="AssignNetworkBB_start">
<bpmn2:outgoing>SequenceFlow_11op1ih</bpmn2:outgoing>
@@ -10,14 +10,14 @@
</bpmn2:serviceTask>
<bpmn2:serviceTask id="ServiceTask_assign_network_sdnc" name="&#10;SDNC&#10;Assign&#10;(network)&#10;" camunda:expression="${SDNCAssignTasks.assignNetwork(InjectExecution.execute(execution, execution.getVariable(&#34;gBuildingBlockExecution&#34;)))}">
<bpmn2:incoming>SequenceFlow_16hhbw3</bpmn2:incoming>
- <bpmn2:outgoing>SequenceFlow_0oawye1</bpmn2:outgoing>
+ <bpmn2:outgoing>SequenceFlow_0rt36co</bpmn2:outgoing>
</bpmn2:serviceTask>
<bpmn2:serviceTask id="ServiceTask_put_network_in_AAI" name="&#10;AAI&#10;Create&#10;(network)&#10;" camunda:expression="${AAICreateTasks.createNetwork(InjectExecution.execute(execution, execution.getVariable(&#34;gBuildingBlockExecution&#34;)))}">
<bpmn2:incoming>SequenceFlow_0gkr871</bpmn2:incoming>
<bpmn2:outgoing>SequenceFlow_1ctpnpe</bpmn2:outgoing>
</bpmn2:serviceTask>
<bpmn2:serviceTask id="ServiceTask_assign_network_aai" name="&#10;AAI&#10;Update&#10;(network)&#10;" camunda:expression="${AAIUpdateTasks.updateOrchestrationStatusAssignedNetwork(InjectExecution.execute(execution, execution.getVariable(&#34;gBuildingBlockExecution&#34;)))}">
- <bpmn2:incoming>SequenceFlow_0oawye1</bpmn2:incoming>
+ <bpmn2:incoming>SequenceFlow_1mvf7b9</bpmn2:incoming>
<bpmn2:outgoing>SequenceFlow_0988gld</bpmn2:outgoing>
</bpmn2:serviceTask>
<bpmn2:sequenceFlow id="SequenceFlow_017131q" name="Yes" sourceRef="networkFoundByName_ExclusiveGateway" targetRef="ExclusiveGateway_0vtj8n8">
@@ -61,8 +61,17 @@
</bpmn2:inclusiveGateway>
<bpmn2:sequenceFlow id="SequenceFlow_0jm95hf" sourceRef="ExclusiveGateway_0vtj8n8" targetRef="ServiceTask_get_cloud_region" />
<bpmn2:sequenceFlow id="SequenceFlow_16hhbw3" sourceRef="ServiceTask_get_cloud_region" targetRef="ServiceTask_assign_network_sdnc" />
- <bpmn2:sequenceFlow id="SequenceFlow_0oawye1" sourceRef="ServiceTask_assign_network_sdnc" targetRef="ServiceTask_assign_network_aai" />
<bpmn2:sequenceFlow id="SequenceFlow_0988gld" sourceRef="ServiceTask_assign_network_aai" targetRef="AssignNetworkBB_end" />
+ <bpmn2:callActivity id="CallActivity_sdncHandlerCall" name="SDNC Assign (network)" calledElement="SDNCHandler">
+ <bpmn2:extensionElements>
+ <camunda:in source="SDNCRequest" target="SDNCRequest" />
+ <camunda:out source="SDNCResponse" target="SDNCResponse" />
+ </bpmn2:extensionElements>
+ <bpmn2:incoming>SequenceFlow_0rt36co</bpmn2:incoming>
+ <bpmn2:outgoing>SequenceFlow_1mvf7b9</bpmn2:outgoing>
+ </bpmn2:callActivity>
+ <bpmn2:sequenceFlow id="SequenceFlow_0rt36co" sourceRef="ServiceTask_assign_network_sdnc" targetRef="CallActivity_sdncHandlerCall" />
+ <bpmn2:sequenceFlow id="SequenceFlow_1mvf7b9" sourceRef="CallActivity_sdncHandlerCall" targetRef="ServiceTask_assign_network_aai" />
<bpmn2:textAnnotation id="TextAnnotation_0dnksb2"> <bpmn2:text>sets Cloud Region on BB execution for SDNC assign</bpmn2:text>
</bpmn2:textAnnotation>
<bpmn2:association id="Association_1rsqd3z" sourceRef="ServiceTask_get_cloud_region" targetRef="TextAnnotation_0dnksb2" />
@@ -97,7 +106,7 @@
<dc:Bounds x="906" y="-49" width="100" height="80" />
</bpmndi:BPMNShape>
<bpmndi:BPMNShape id="ServiceTask_18yks1p_di" bpmnElement="ServiceTask_assign_network_aai">
- <dc:Bounds x="1909" y="-127" width="100" height="80" />
+ <dc:Bounds x="2106" y="-127" width="100" height="80" />
</bpmndi:BPMNShape>
<bpmndi:BPMNEdge id="SequenceFlow_017131q_di" bpmnElement="SequenceFlow_017131q">
<di:waypoint xsi:type="dc:Point" x="863" y="-112" />
@@ -117,9 +126,9 @@
</bpmndi:BPMNLabel>
</bpmndi:BPMNEdge>
<bpmndi:BPMNShape id="EndEvent_083u1a5_di" bpmnElement="AssignNetworkBB_end">
- <dc:Bounds x="2118" y="-105" width="36" height="36" />
+ <dc:Bounds x="2241" y="-105" width="36" height="36" />
<bpmndi:BPMNLabel>
- <dc:Bounds x="2113" y="-65" width="46" height="12" />
+ <dc:Bounds x="2214" y="-65" width="90" height="12" />
</bpmndi:BPMNLabel>
</bpmndi:BPMNShape>
<bpmndi:BPMNEdge id="SequenceFlow_11op1ih_di" bpmnElement="SequenceFlow_11op1ih">
@@ -210,18 +219,28 @@
<dc:Bounds x="1750.5" y="-108" width="0" height="12" />
</bpmndi:BPMNLabel>
</bpmndi:BPMNEdge>
- <bpmndi:BPMNEdge id="SequenceFlow_0oawye1_di" bpmnElement="SequenceFlow_0oawye1">
+ <bpmndi:BPMNEdge id="SequenceFlow_0988gld_di" bpmnElement="SequenceFlow_0988gld">
+ <di:waypoint xsi:type="dc:Point" x="2206" y="-87" />
+ <di:waypoint xsi:type="dc:Point" x="2241" y="-87" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="2178.5" y="-108" width="90" height="12" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNEdge>
+ <bpmndi:BPMNShape id="CallActivity_0h7upeg_di" bpmnElement="CallActivity_sdncHandlerCall">
+ <dc:Bounds x="1927" y="-127" width="100" height="80" />
+ </bpmndi:BPMNShape>
+ <bpmndi:BPMNEdge id="SequenceFlow_0rt36co_di" bpmnElement="SequenceFlow_0rt36co">
<di:waypoint xsi:type="dc:Point" x="1869" y="-87" />
- <di:waypoint xsi:type="dc:Point" x="1909" y="-87" />
+ <di:waypoint xsi:type="dc:Point" x="1927" y="-87" />
<bpmndi:BPMNLabel>
- <dc:Bounds x="1889" y="-108" width="0" height="12" />
+ <dc:Bounds x="1898" y="-108" width="0" height="12" />
</bpmndi:BPMNLabel>
</bpmndi:BPMNEdge>
- <bpmndi:BPMNEdge id="SequenceFlow_0988gld_di" bpmnElement="SequenceFlow_0988gld">
- <di:waypoint xsi:type="dc:Point" x="2009" y="-87" />
- <di:waypoint xsi:type="dc:Point" x="2118" y="-87" />
+ <bpmndi:BPMNEdge id="SequenceFlow_1mvf7b9_di" bpmnElement="SequenceFlow_1mvf7b9">
+ <di:waypoint xsi:type="dc:Point" x="2027" y="-87" />
+ <di:waypoint xsi:type="dc:Point" x="2106" y="-87" />
<bpmndi:BPMNLabel>
- <dc:Bounds x="2063.5" y="-108" width="0" height="12" />
+ <dc:Bounds x="2066.5" y="-108" width="0" height="12" />
</bpmndi:BPMNLabel>
</bpmndi:BPMNEdge>
</bpmndi:BPMNPlane>
diff --git a/bpmn/so-bpmn-building-blocks/src/main/resources/subprocess/BuildingBlock/AssignServiceInstanceBB.bpmn b/bpmn/so-bpmn-building-blocks/src/main/resources/subprocess/BuildingBlock/AssignServiceInstanceBB.bpmn
index d1f2286258..a98db3ac7b 100644
--- a/bpmn/so-bpmn-building-blocks/src/main/resources/subprocess/BuildingBlock/AssignServiceInstanceBB.bpmn
+++ b/bpmn/so-bpmn-building-blocks/src/main/resources/subprocess/BuildingBlock/AssignServiceInstanceBB.bpmn
@@ -1,5 +1,5 @@
<?xml version="1.0" encoding="UTF-8"?>
-<bpmn:definitions xmlns:bpmn="http://www.omg.org/spec/BPMN/20100524/MODEL" xmlns:bpmndi="http://www.omg.org/spec/BPMN/20100524/DI" xmlns:di="http://www.omg.org/spec/DD/20100524/DI" xmlns:dc="http://www.omg.org/spec/DD/20100524/DC" xmlns:camunda="http://camunda.org/schema/1.0/bpmn" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" id="Definitions_1" targetNamespace="http://bpmn.io/schema/bpmn" exporter="Camunda Modeler" exporterVersion="1.10.0">
+<bpmn:definitions xmlns:bpmn="http://www.omg.org/spec/BPMN/20100524/MODEL" xmlns:bpmndi="http://www.omg.org/spec/BPMN/20100524/DI" xmlns:di="http://www.omg.org/spec/DD/20100524/DI" xmlns:dc="http://www.omg.org/spec/DD/20100524/DC" xmlns:camunda="http://camunda.org/schema/1.0/bpmn" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" id="Definitions_1" targetNamespace="http://bpmn.io/schema/bpmn" exporter="Camunda Modeler" exporterVersion="1.8.2">
<bpmn:process id="AssignServiceInstanceBB" name="AssignServiceInstanceBB" isExecutable="true">
<bpmn:startEvent id="Start_AssignServiceInstanceBB">
<bpmn:outgoing>SequenceFlow_1xr6chl</bpmn:outgoing>
@@ -16,20 +16,19 @@
<bpmn:incoming>SequenceFlow_1t55i01</bpmn:incoming>
<bpmn:outgoing>SequenceFlow_0aef1l8</bpmn:outgoing>
</bpmn:serviceTask>
- <bpmn:serviceTask id="Task_AssignServiceInstance" name="&#10;SDNC&#10;Assign&#10;(svc instance)&#10;" camunda:expression="${SDNCAssignTasks.assignServiceInstance(InjectExecution.execute(execution, execution.getVariable(&#34;gBuildingBlockExecution&#34;)))}">
+ <bpmn:serviceTask id="Task_AssignServiceInstance" name="&#10;SDNC&#10;Create Assign Request&#10;(svc instance)&#10;" camunda:expression="${SDNCAssignTasks.assignServiceInstance(InjectExecution.execute(execution, execution.getVariable(&#34;gBuildingBlockExecution&#34;)))}">
<bpmn:incoming>SequenceFlow_0aef1l8</bpmn:incoming>
- <bpmn:outgoing>SequenceFlow_07ea5ui</bpmn:outgoing>
+ <bpmn:outgoing>SequenceFlow_1vmf5yv</bpmn:outgoing>
</bpmn:serviceTask>
<bpmn:sequenceFlow id="SequenceFlow_1xr6chl" sourceRef="Start_AssignServiceInstanceBB" targetRef="Task_CreateServiceSubscription" />
<bpmn:sequenceFlow id="SequenceFlow_0czewtx" sourceRef="Task_CreateServiceInstance" targetRef="Task_CreateProject" />
<bpmn:sequenceFlow id="SequenceFlow_1t55i01" sourceRef="Task_CreateProject" targetRef="Task_CreateOwningEntity" />
- <bpmn:sequenceFlow id="SequenceFlow_07ea5ui" sourceRef="Task_AssignServiceInstance" targetRef="Task_UpdateServiceOstatusToAssigned" />
<bpmn:endEvent id="End_AssignServiceInstanceBB">
<bpmn:incoming>SequenceFlow_14xl505</bpmn:incoming>
</bpmn:endEvent>
<bpmn:sequenceFlow id="SequenceFlow_14xl505" sourceRef="Task_UpdateServiceOstatusToAssigned" targetRef="End_AssignServiceInstanceBB" />
<bpmn:serviceTask id="Task_UpdateServiceOstatusToAssigned" name="&#10;AAI&#10;Update&#10;(svc instance)&#10;" camunda:expression="${AAIUpdateTasks.updateOrchestrationStatusAssignedService(InjectExecution.execute(execution, execution.getVariable(&#34;gBuildingBlockExecution&#34;)))}">
- <bpmn:incoming>SequenceFlow_07ea5ui</bpmn:incoming>
+ <bpmn:incoming>SequenceFlow_0c6u1cp</bpmn:incoming>
<bpmn:outgoing>SequenceFlow_14xl505</bpmn:outgoing>
</bpmn:serviceTask>
<bpmn:sequenceFlow id="SequenceFlow_1h6t7yr" sourceRef="Task_CreateServiceSubscription" targetRef="Task_CreateServiceInstance" />
@@ -38,6 +37,16 @@
<bpmn:outgoing>SequenceFlow_1h6t7yr</bpmn:outgoing>
</bpmn:serviceTask>
<bpmn:sequenceFlow id="SequenceFlow_0aef1l8" sourceRef="Task_CreateOwningEntity" targetRef="Task_AssignServiceInstance" />
+ <bpmn:callActivity id="CallActivity_sdncHandler" name="SDNC Assign (svc instance)" calledElement="SDNCHandler">
+ <bpmn:extensionElements>
+ <camunda:in source="SDNCRequest" target="SDNCRequest" />
+ <camunda:out source="SDNCResponse" target="SDNCResponse" />
+ </bpmn:extensionElements>
+ <bpmn:incoming>SequenceFlow_1vmf5yv</bpmn:incoming>
+ <bpmn:outgoing>SequenceFlow_0c6u1cp</bpmn:outgoing>
+ </bpmn:callActivity>
+ <bpmn:sequenceFlow id="SequenceFlow_1vmf5yv" sourceRef="Task_AssignServiceInstance" targetRef="CallActivity_sdncHandler" />
+ <bpmn:sequenceFlow id="SequenceFlow_0c6u1cp" sourceRef="CallActivity_sdncHandler" targetRef="Task_UpdateServiceOstatusToAssigned" />
</bpmn:process>
<bpmn:error id="Error_02g61p6" name="gDelegateError" errorCode="7000" />
<bpmndi:BPMNDiagram id="BPMNDiagram_1">
@@ -81,28 +90,21 @@
<dc:Bounds x="464" y="87" width="90" height="12" />
</bpmndi:BPMNLabel>
</bpmndi:BPMNEdge>
- <bpmndi:BPMNEdge id="SequenceFlow_07ea5ui_di" bpmnElement="SequenceFlow_07ea5ui">
- <di:waypoint xsi:type="dc:Point" x="819" y="108" />
- <di:waypoint xsi:type="dc:Point" x="869" y="108" />
- <bpmndi:BPMNLabel>
- <dc:Bounds x="799" y="87" width="90" height="12" />
- </bpmndi:BPMNLabel>
- </bpmndi:BPMNEdge>
<bpmndi:BPMNShape id="EndEvent_0qdq7wj_di" bpmnElement="End_AssignServiceInstanceBB">
- <dc:Bounds x="1030" y="90" width="36" height="36" />
+ <dc:Bounds x="1150" y="90" width="36" height="36" />
<bpmndi:BPMNLabel>
- <dc:Bounds x="1039" y="130" width="18" height="12" />
+ <dc:Bounds x="1123" y="130" width="90" height="12" />
</bpmndi:BPMNLabel>
</bpmndi:BPMNShape>
<bpmndi:BPMNEdge id="SequenceFlow_14xl505_di" bpmnElement="SequenceFlow_14xl505">
- <di:waypoint xsi:type="dc:Point" x="969" y="108" />
- <di:waypoint xsi:type="dc:Point" x="1030" y="108" />
+ <di:waypoint xsi:type="dc:Point" x="1104" y="108" />
+ <di:waypoint xsi:type="dc:Point" x="1150" y="108" />
<bpmndi:BPMNLabel>
- <dc:Bounds x="954.5" y="87" width="90" height="12" />
+ <dc:Bounds x="1082" y="87" width="90" height="12" />
</bpmndi:BPMNLabel>
</bpmndi:BPMNEdge>
<bpmndi:BPMNShape id="ServiceTask_1dgenhy_di" bpmnElement="Task_UpdateServiceOstatusToAssigned">
- <dc:Bounds x="869" y="68" width="100" height="80" />
+ <dc:Bounds x="1004" y="68" width="100" height="80" />
</bpmndi:BPMNShape>
<bpmndi:BPMNEdge id="SequenceFlow_1h6t7yr_di" bpmnElement="SequenceFlow_1h6t7yr">
<di:waypoint xsi:type="dc:Point" x="253" y="108" />
@@ -121,6 +123,23 @@
<dc:Bounds x="653" y="87" width="90" height="12" />
</bpmndi:BPMNLabel>
</bpmndi:BPMNEdge>
+ <bpmndi:BPMNShape id="CallActivity_037c9st_di" bpmnElement="CallActivity_sdncHandler">
+ <dc:Bounds x="862" y="68" width="100" height="80" />
+ </bpmndi:BPMNShape>
+ <bpmndi:BPMNEdge id="SequenceFlow_1vmf5yv_di" bpmnElement="SequenceFlow_1vmf5yv">
+ <di:waypoint xsi:type="dc:Point" x="819" y="108" />
+ <di:waypoint xsi:type="dc:Point" x="862" y="108" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="840.5" y="87" width="0" height="12" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNEdge>
+ <bpmndi:BPMNEdge id="SequenceFlow_0c6u1cp_di" bpmnElement="SequenceFlow_0c6u1cp">
+ <di:waypoint xsi:type="dc:Point" x="962" y="108" />
+ <di:waypoint xsi:type="dc:Point" x="1004" y="108" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="983" y="87" width="0" height="12" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNEdge>
</bpmndi:BPMNPlane>
</bpmndi:BPMNDiagram>
-</bpmn:definitions> \ No newline at end of file
+</bpmn:definitions>
diff --git a/bpmn/so-bpmn-building-blocks/src/main/resources/subprocess/BuildingBlock/AssignVfModuleBB.bpmn b/bpmn/so-bpmn-building-blocks/src/main/resources/subprocess/BuildingBlock/AssignVfModuleBB.bpmn
index 3ab34c4129..7dee0f709d 100644
--- a/bpmn/so-bpmn-building-blocks/src/main/resources/subprocess/BuildingBlock/AssignVfModuleBB.bpmn
+++ b/bpmn/so-bpmn-building-blocks/src/main/resources/subprocess/BuildingBlock/AssignVfModuleBB.bpmn
@@ -1,5 +1,5 @@
<?xml version="1.0" encoding="UTF-8"?>
-<bpmn:definitions xmlns:bpmn="http://www.omg.org/spec/BPMN/20100524/MODEL" xmlns:bpmndi="http://www.omg.org/spec/BPMN/20100524/DI" xmlns:di="http://www.omg.org/spec/DD/20100524/DI" xmlns:dc="http://www.omg.org/spec/DD/20100524/DC" xmlns:camunda="http://camunda.org/schema/1.0/bpmn" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" id="Definitions_1" targetNamespace="http://bpmn.io/schema/bpmn" exporter="Camunda Modeler" exporterVersion="1.4.0">
+<bpmn:definitions xmlns:bpmn="http://www.omg.org/spec/BPMN/20100524/MODEL" xmlns:bpmndi="http://www.omg.org/spec/BPMN/20100524/DI" xmlns:di="http://www.omg.org/spec/DD/20100524/DI" xmlns:dc="http://www.omg.org/spec/DD/20100524/DC" xmlns:camunda="http://camunda.org/schema/1.0/bpmn" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" id="Definitions_1" targetNamespace="http://bpmn.io/schema/bpmn" exporter="Camunda Modeler" exporterVersion="1.8.2">
<bpmn:process id="AssignVfModuleBB" name="AssignVfModuleBB" isExecutable="true">
<bpmn:startEvent id="AssignVfModuleBB_Start">
<bpmn:outgoing>SequenceFlow_1xr6chl</bpmn:outgoing>
@@ -10,7 +10,7 @@
</bpmn:serviceTask>
<bpmn:serviceTask id="AssignVfModule" name="&#10;SDNC&#10;Assign&#10;(vf module)&#10;" camunda:expression="${SDNCAssignTasks.assignVfModule(InjectExecution.execute(execution, execution.getVariable(&#34;gBuildingBlockExecution&#34;)))}">
<bpmn:incoming>SequenceFlow_0574gaa</bpmn:incoming>
- <bpmn:outgoing>SequenceFlow_15hn8si</bpmn:outgoing>
+ <bpmn:outgoing>SequenceFlow_0269euz</bpmn:outgoing>
</bpmn:serviceTask>
<bpmn:sequenceFlow id="SequenceFlow_1xr6chl" sourceRef="AssignVfModuleBB_Start" targetRef="CreateVfModule" />
<bpmn:sequenceFlow id="SequenceFlow_0czewtx" sourceRef="CreateVfModule" targetRef="ConnectVfModuleToVolumeGroup" />
@@ -19,15 +19,24 @@
</bpmn:endEvent>
<bpmn:sequenceFlow id="SequenceFlow_14xl505" sourceRef="UpdateVfModuleStatus" targetRef="AssignVfModuleBB_End" />
<bpmn:serviceTask id="UpdateVfModuleStatus" name="&#10;AAI&#10;Update&#10;(vf module)&#10;" camunda:expression="${AAIUpdateTasks.updateOrchestrationStatusAssignedOrPendingActivationVfModule(InjectExecution.execute(execution, execution.getVariable(&#34;gBuildingBlockExecution&#34;)))}">
- <bpmn:incoming>SequenceFlow_15hn8si</bpmn:incoming>
+ <bpmn:incoming>SequenceFlow_1dttbxh</bpmn:incoming>
<bpmn:outgoing>SequenceFlow_14xl505</bpmn:outgoing>
</bpmn:serviceTask>
- <bpmn:sequenceFlow id="SequenceFlow_15hn8si" sourceRef="AssignVfModule" targetRef="UpdateVfModuleStatus" />
<bpmn:sequenceFlow id="SequenceFlow_0574gaa" sourceRef="ConnectVfModuleToVolumeGroup" targetRef="AssignVfModule" />
<bpmn:serviceTask id="ConnectVfModuleToVolumeGroup" name="&#10;AAI&#10;Connect&#10;(volume)&#10;" camunda:expression="${AAICreateTasks.connectVfModuleToVolumeGroup(InjectExecution.execute(execution, execution.getVariable(&#34;gBuildingBlockExecution&#34;)))}">
<bpmn:incoming>SequenceFlow_0czewtx</bpmn:incoming>
<bpmn:outgoing>SequenceFlow_0574gaa</bpmn:outgoing>
</bpmn:serviceTask>
+ <bpmn:callActivity id="CallActivity_sdncHandlerCall" name="SDNC Activate (vfModule)" calledElement="SDNCHandler">
+ <bpmn:extensionElements>
+ <camunda:in source="SDNCRequest" target="SDNCRequest" />
+ <camunda:out source="SDNCResponse" target="SDNCResponse" />
+ </bpmn:extensionElements>
+ <bpmn:incoming>SequenceFlow_0269euz</bpmn:incoming>
+ <bpmn:outgoing>SequenceFlow_1dttbxh</bpmn:outgoing>
+ </bpmn:callActivity>
+ <bpmn:sequenceFlow id="SequenceFlow_0269euz" sourceRef="AssignVfModule" targetRef="CallActivity_sdncHandlerCall" />
+ <bpmn:sequenceFlow id="SequenceFlow_1dttbxh" sourceRef="CallActivity_sdncHandlerCall" targetRef="UpdateVfModuleStatus" />
</bpmn:process>
<bpmndi:BPMNDiagram id="BPMNDiagram_1">
<bpmndi:BPMNPlane id="BPMNPlane_1" bpmnElement="AssignVfModuleBB">
@@ -38,23 +47,23 @@
</bpmndi:BPMNLabel>
</bpmndi:BPMNShape>
<bpmndi:BPMNShape id="ServiceTask_0028k7a_di" bpmnElement="CreateVfModule">
- <dc:Bounds x="297" y="46" width="100" height="80" />
+ <dc:Bounds x="255" y="46" width="100" height="80" />
</bpmndi:BPMNShape>
<bpmndi:BPMNShape id="ServiceTask_13t22km_di" bpmnElement="AssignVfModule">
- <dc:Bounds x="632" y="46" width="100" height="80" />
+ <dc:Bounds x="540" y="46" width="100" height="80" />
</bpmndi:BPMNShape>
<bpmndi:BPMNEdge id="SequenceFlow_1xr6chl_di" bpmnElement="SequenceFlow_1xr6chl">
<di:waypoint xsi:type="dc:Point" x="220" y="86" />
- <di:waypoint xsi:type="dc:Point" x="297" y="86" />
+ <di:waypoint xsi:type="dc:Point" x="255" y="86" />
<bpmndi:BPMNLabel>
- <dc:Bounds x="214" y="71" width="90" height="0" />
+ <dc:Bounds x="192.5" y="71" width="90" height="0" />
</bpmndi:BPMNLabel>
</bpmndi:BPMNEdge>
<bpmndi:BPMNEdge id="SequenceFlow_0czewtx_di" bpmnElement="SequenceFlow_0czewtx">
- <di:waypoint xsi:type="dc:Point" x="397" y="86" />
- <di:waypoint xsi:type="dc:Point" x="461" y="86" />
+ <di:waypoint xsi:type="dc:Point" x="355" y="86" />
+ <di:waypoint xsi:type="dc:Point" x="400" y="86" />
<bpmndi:BPMNLabel>
- <dc:Bounds x="384" y="71" width="90" height="0" />
+ <dc:Bounds x="332.5" y="71" width="90" height="0" />
</bpmndi:BPMNLabel>
</bpmndi:BPMNEdge>
<bpmndi:BPMNShape id="EndEvent_0qdq7wj_di" bpmnElement="AssignVfModuleBB_End">
@@ -64,32 +73,42 @@
</bpmndi:BPMNLabel>
</bpmndi:BPMNShape>
<bpmndi:BPMNEdge id="SequenceFlow_14xl505_di" bpmnElement="SequenceFlow_14xl505">
- <di:waypoint xsi:type="dc:Point" x="906" y="86" />
+ <di:waypoint xsi:type="dc:Point" x="964" y="86" />
<di:waypoint xsi:type="dc:Point" x="1008" y="86" />
<bpmndi:BPMNLabel>
- <dc:Bounds x="912" y="71" width="90" height="0" />
+ <dc:Bounds x="941" y="71" width="90" height="0" />
</bpmndi:BPMNLabel>
</bpmndi:BPMNEdge>
<bpmndi:BPMNShape id="ServiceTask_1dgenhy_di" bpmnElement="UpdateVfModuleStatus">
- <dc:Bounds x="806" y="46" width="100" height="80" />
+ <dc:Bounds x="864" y="46" width="100" height="80" />
</bpmndi:BPMNShape>
- <bpmndi:BPMNEdge id="SequenceFlow_15hn8si_di" bpmnElement="SequenceFlow_15hn8si">
- <di:waypoint xsi:type="dc:Point" x="732" y="86" />
- <di:waypoint xsi:type="dc:Point" x="806" y="86" />
- <bpmndi:BPMNLabel>
- <dc:Bounds x="724" y="71" width="90" height="0" />
- </bpmndi:BPMNLabel>
- </bpmndi:BPMNEdge>
<bpmndi:BPMNEdge id="SequenceFlow_0574gaa_di" bpmnElement="SequenceFlow_0574gaa">
- <di:waypoint xsi:type="dc:Point" x="561" y="86" />
- <di:waypoint xsi:type="dc:Point" x="632" y="86" />
+ <di:waypoint xsi:type="dc:Point" x="500" y="86" />
+ <di:waypoint xsi:type="dc:Point" x="540" y="86" />
<bpmndi:BPMNLabel>
- <dc:Bounds x="552" y="71" width="90" height="0" />
+ <dc:Bounds x="475" y="71" width="90" height="0" />
</bpmndi:BPMNLabel>
</bpmndi:BPMNEdge>
<bpmndi:BPMNShape id="ServiceTask_0ekqpfn_di" bpmnElement="ConnectVfModuleToVolumeGroup">
- <dc:Bounds x="461" y="46" width="100" height="80" />
+ <dc:Bounds x="400" y="46" width="100" height="80" />
</bpmndi:BPMNShape>
+ <bpmndi:BPMNShape id="CallActivity_0uicgnt_di" bpmnElement="CallActivity_sdncHandlerCall">
+ <dc:Bounds x="701" y="46" width="100" height="80" />
+ </bpmndi:BPMNShape>
+ <bpmndi:BPMNEdge id="SequenceFlow_0269euz_di" bpmnElement="SequenceFlow_0269euz">
+ <di:waypoint xsi:type="dc:Point" x="640" y="86" />
+ <di:waypoint xsi:type="dc:Point" x="701" y="86" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="670.5" y="65" width="0" height="12" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNEdge>
+ <bpmndi:BPMNEdge id="SequenceFlow_1dttbxh_di" bpmnElement="SequenceFlow_1dttbxh">
+ <di:waypoint xsi:type="dc:Point" x="801" y="86" />
+ <di:waypoint xsi:type="dc:Point" x="864" y="86" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="832.5" y="65" width="0" height="12" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNEdge>
</bpmndi:BPMNPlane>
</bpmndi:BPMNDiagram>
</bpmn:definitions>
diff --git a/bpmn/so-bpmn-building-blocks/src/main/resources/subprocess/BuildingBlock/ChangeModelServiceInstanceBB.bpmn b/bpmn/so-bpmn-building-blocks/src/main/resources/subprocess/BuildingBlock/ChangeModelServiceInstanceBB.bpmn
index fa0c7f4f44..c2e960364c 100644
--- a/bpmn/so-bpmn-building-blocks/src/main/resources/subprocess/BuildingBlock/ChangeModelServiceInstanceBB.bpmn
+++ b/bpmn/so-bpmn-building-blocks/src/main/resources/subprocess/BuildingBlock/ChangeModelServiceInstanceBB.bpmn
@@ -1,5 +1,5 @@
<?xml version="1.0" encoding="UTF-8"?>
-<bpmn2:definitions xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:bpmn2="http://www.omg.org/spec/BPMN/20100524/MODEL" xmlns:bpmndi="http://www.omg.org/spec/BPMN/20100524/DI" xmlns:camunda="http://camunda.org/schema/1.0/bpmn" xmlns:dc="http://www.omg.org/spec/DD/20100524/DC" xmlns:di="http://www.omg.org/spec/DD/20100524/DI" id="_MagIIMOUEeW8asg-vCEgWQ" targetNamespace="http://camunda.org/schema/1.0/bpmn" exporter="Camunda Modeler" exporterVersion="1.10.0" xsi:schemaLocation="http://www.omg.org/spec/BPMN/20100524/MODEL BPMN20.xsd">
+<bpmn2:definitions xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:bpmn2="http://www.omg.org/spec/BPMN/20100524/MODEL" xmlns:bpmndi="http://www.omg.org/spec/BPMN/20100524/DI" xmlns:camunda="http://camunda.org/schema/1.0/bpmn" xmlns:dc="http://www.omg.org/spec/DD/20100524/DC" xmlns:di="http://www.omg.org/spec/DD/20100524/DI" id="_MagIIMOUEeW8asg-vCEgWQ" targetNamespace="http://camunda.org/schema/1.0/bpmn" exporter="Camunda Modeler" exporterVersion="1.8.2" xsi:schemaLocation="http://www.omg.org/spec/BPMN/20100524/MODEL BPMN20.xsd">
<bpmn2:process id="ChangeModelServiceInstanceBB" name="ChangeModelServiceInstanceBB" isExecutable="true">
<bpmn2:startEvent id="ChangeModelServiceInstance_Start">
<bpmn2:outgoing>SequenceFlow_18i4a05</bpmn2:outgoing>
@@ -8,16 +8,25 @@
<bpmn2:incoming>SequenceFlow_0g502yj</bpmn2:incoming>
</bpmn2:endEvent>
<bpmn2:sequenceFlow id="SequenceFlow_18i4a05" sourceRef="ChangeModelServiceInstance_Start" targetRef="SDNCChangeModelServiceInstance" />
- <bpmn2:sequenceFlow id="SequenceFlow_19kfk17" sourceRef="SDNCChangeModelServiceInstance" targetRef="AAIUpdateModelServiceInstance" />
<bpmn2:sequenceFlow id="SequenceFlow_0g502yj" sourceRef="AAIUpdateModelServiceInstance" targetRef="ChangeModelServiceInstance_End" />
<bpmn2:serviceTask id="SDNCChangeModelServiceInstance" name="&#10;SDNC &#10;Change&#10;(svc instance)&#10;" camunda:expression="${SDNCChangeAssignTasks.changeModelServiceInstance(InjectExecution.execute(execution, execution.getVariable(&#34;gBuildingBlockExecution&#34;)))}">
<bpmn2:incoming>SequenceFlow_18i4a05</bpmn2:incoming>
- <bpmn2:outgoing>SequenceFlow_19kfk17</bpmn2:outgoing>
+ <bpmn2:outgoing>SequenceFlow_1q3rjt4</bpmn2:outgoing>
</bpmn2:serviceTask>
<bpmn2:serviceTask id="AAIUpdateModelServiceInstance" name="&#10;AAI &#10;Update&#10;(svc Instance)&#10;" camunda:expression="${AAIUpdateTasks.updateServiceInstance(InjectExecution.execute(execution, execution.getVariable(&#34;gBuildingBlockExecution&#34;)))}">
- <bpmn2:incoming>SequenceFlow_19kfk17</bpmn2:incoming>
+ <bpmn2:incoming>SequenceFlow_0ycnbyf</bpmn2:incoming>
<bpmn2:outgoing>SequenceFlow_0g502yj</bpmn2:outgoing>
</bpmn2:serviceTask>
+ <bpmn2:callActivity id="CallActivity_sdncHandlerReq" name="SDNC ChangeModel (svc instance)" calledElement="SDNCHandler">
+ <bpmn2:extensionElements>
+ <camunda:in source="SDNCRequest" target="SDNCRequest" />
+ <camunda:out source="SDNCResponse" target="SDNCResponse" />
+ </bpmn2:extensionElements>
+ <bpmn2:incoming>SequenceFlow_1q3rjt4</bpmn2:incoming>
+ <bpmn2:outgoing>SequenceFlow_0ycnbyf</bpmn2:outgoing>
+ </bpmn2:callActivity>
+ <bpmn2:sequenceFlow id="SequenceFlow_1q3rjt4" sourceRef="SDNCChangeModelServiceInstance" targetRef="CallActivity_sdncHandlerReq" />
+ <bpmn2:sequenceFlow id="SequenceFlow_0ycnbyf" sourceRef="CallActivity_sdncHandlerReq" targetRef="AAIUpdateModelServiceInstance" />
</bpmn2:process>
<bpmn2:error id="Error_2" name="MSOWorkflowException" errorCode="MSOWorkflowException" />
<bpmn2:error id="Error_1" name="java.lang.Exception" errorCode="java.lang.Exception" />
@@ -38,31 +47,41 @@
</bpmndi:BPMNShape>
<bpmndi:BPMNEdge id="SequenceFlow_18i4a05_di" bpmnElement="SequenceFlow_18i4a05">
<di:waypoint xsi:type="dc:Point" x="111" y="106" />
- <di:waypoint xsi:type="dc:Point" x="234" y="106" />
+ <di:waypoint xsi:type="dc:Point" x="158" y="106" />
<bpmndi:BPMNLabel>
- <dc:Bounds x="127.5" y="85" width="90" height="12" />
- </bpmndi:BPMNLabel>
- </bpmndi:BPMNEdge>
- <bpmndi:BPMNEdge id="SequenceFlow_19kfk17_di" bpmnElement="SequenceFlow_19kfk17">
- <di:waypoint xsi:type="dc:Point" x="334" y="106" />
- <di:waypoint xsi:type="dc:Point" x="390" y="106" />
- <bpmndi:BPMNLabel>
- <dc:Bounds x="317" y="85" width="90" height="12" />
+ <dc:Bounds x="89.5" y="85" width="90" height="12" />
</bpmndi:BPMNLabel>
</bpmndi:BPMNEdge>
<bpmndi:BPMNEdge id="SequenceFlow_0g502yj_di" bpmnElement="SequenceFlow_0g502yj">
- <di:waypoint xsi:type="dc:Point" x="490" y="106" />
+ <di:waypoint xsi:type="dc:Point" x="589" y="106" />
<di:waypoint xsi:type="dc:Point" x="632" y="106" />
<bpmndi:BPMNLabel>
- <dc:Bounds x="516" y="85" width="90" height="12" />
+ <dc:Bounds x="565.5" y="85" width="90" height="12" />
</bpmndi:BPMNLabel>
</bpmndi:BPMNEdge>
<bpmndi:BPMNShape id="ServiceTask_03km5f0_di" bpmnElement="SDNCChangeModelServiceInstance">
- <dc:Bounds x="234" y="66" width="100" height="80" />
+ <dc:Bounds x="158" y="66" width="100" height="80" />
</bpmndi:BPMNShape>
<bpmndi:BPMNShape id="ServiceTask_10b2mxq_di" bpmnElement="AAIUpdateModelServiceInstance">
- <dc:Bounds x="390" y="66" width="100" height="80" />
+ <dc:Bounds x="489" y="66" width="100" height="80" />
</bpmndi:BPMNShape>
+ <bpmndi:BPMNShape id="CallActivity_1heowq0_di" bpmnElement="CallActivity_sdncHandlerReq">
+ <dc:Bounds x="315" y="66" width="100" height="80" />
+ </bpmndi:BPMNShape>
+ <bpmndi:BPMNEdge id="SequenceFlow_1q3rjt4_di" bpmnElement="SequenceFlow_1q3rjt4">
+ <di:waypoint xsi:type="dc:Point" x="258" y="106" />
+ <di:waypoint xsi:type="dc:Point" x="315" y="106" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="286.5" y="85" width="0" height="12" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNEdge>
+ <bpmndi:BPMNEdge id="SequenceFlow_0ycnbyf_di" bpmnElement="SequenceFlow_0ycnbyf">
+ <di:waypoint xsi:type="dc:Point" x="415" y="106" />
+ <di:waypoint xsi:type="dc:Point" x="489" y="106" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="452" y="85" width="0" height="12" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNEdge>
</bpmndi:BPMNPlane>
</bpmndi:BPMNDiagram>
</bpmn2:definitions>
diff --git a/bpmn/so-bpmn-building-blocks/src/main/resources/subprocess/BuildingBlock/ChangeModelVfModuleBB.bpmn b/bpmn/so-bpmn-building-blocks/src/main/resources/subprocess/BuildingBlock/ChangeModelVfModuleBB.bpmn
index fd247d26eb..28957c6197 100644
--- a/bpmn/so-bpmn-building-blocks/src/main/resources/subprocess/BuildingBlock/ChangeModelVfModuleBB.bpmn
+++ b/bpmn/so-bpmn-building-blocks/src/main/resources/subprocess/BuildingBlock/ChangeModelVfModuleBB.bpmn
@@ -1,5 +1,5 @@
<?xml version="1.0" encoding="UTF-8"?>
-<bpmn:definitions xmlns:bpmn="http://www.omg.org/spec/BPMN/20100524/MODEL" xmlns:bpmndi="http://www.omg.org/spec/BPMN/20100524/DI" xmlns:di="http://www.omg.org/spec/DD/20100524/DI" xmlns:dc="http://www.omg.org/spec/DD/20100524/DC" xmlns:camunda="http://camunda.org/schema/1.0/bpmn" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" id="Definitions_1" targetNamespace="http://bpmn.io/schema/bpmn" exporter="Camunda Modeler" exporterVersion="1.10.0">
+<bpmn:definitions xmlns:bpmn="http://www.omg.org/spec/BPMN/20100524/MODEL" xmlns:bpmndi="http://www.omg.org/spec/BPMN/20100524/DI" xmlns:di="http://www.omg.org/spec/DD/20100524/DI" xmlns:dc="http://www.omg.org/spec/DD/20100524/DC" xmlns:camunda="http://camunda.org/schema/1.0/bpmn" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" id="Definitions_1" targetNamespace="http://bpmn.io/schema/bpmn" exporter="Camunda Modeler" exporterVersion="1.8.2">
<bpmn:process id="ChangeModelVfModuleBB" name="ChangeModelVfModuleBB" isExecutable="true">
<bpmn:startEvent id="ChangeModelVfModuleBB_Start">
<bpmn:outgoing>SequenceFlow_0ieafii</bpmn:outgoing>
@@ -10,14 +10,23 @@
</bpmn:endEvent>
<bpmn:serviceTask id="ChangeModelVfModule" name="&#10;SDNC&#10;Change &#10;(vf model)&#10;" camunda:expression="${SDNCChangeAssignTasks.changeAssignModelVfModule(InjectExecution.execute(execution, execution.getVariable(&#34;gBuildingBlockExecution&#34;)))}">
<bpmn:incoming>SequenceFlow_0ieafii</bpmn:incoming>
- <bpmn:outgoing>SequenceFlow_14kvrbe</bpmn:outgoing>
+ <bpmn:outgoing>SequenceFlow_0m403q5</bpmn:outgoing>
</bpmn:serviceTask>
- <bpmn:sequenceFlow id="SequenceFlow_14kvrbe" sourceRef="ChangeModelVfModule" targetRef="UpdateVfModuleModel" />
<bpmn:serviceTask id="UpdateVfModuleModel" name="&#10;AAI&#10;Update&#10;(vf model)&#10;" camunda:expression="${AAIUpdateTasks.updateModelVfModule(InjectExecution.execute(execution, execution.getVariable(&#34;gBuildingBlockExecution&#34;)))}">
- <bpmn:incoming>SequenceFlow_14kvrbe</bpmn:incoming>
+ <bpmn:incoming>SequenceFlow_0rpp4hi</bpmn:incoming>
<bpmn:outgoing>SequenceFlow_0xsp0pv</bpmn:outgoing>
</bpmn:serviceTask>
<bpmn:sequenceFlow id="SequenceFlow_0xsp0pv" sourceRef="UpdateVfModuleModel" targetRef="ChangeModelVfModuleBB_End" />
+ <bpmn:callActivity id="CallActivity_sdncHandler" name="SDNC ChangeModel (vf module)" calledElement="SDNCHandler">
+ <bpmn:extensionElements>
+ <camunda:in source="SDNCRequest" target="SDNCRequest" />
+ <camunda:out source="SDNCResponse" target="SDNCResponse" />
+ </bpmn:extensionElements>
+ <bpmn:incoming>SequenceFlow_0m403q5</bpmn:incoming>
+ <bpmn:outgoing>SequenceFlow_0rpp4hi</bpmn:outgoing>
+ </bpmn:callActivity>
+ <bpmn:sequenceFlow id="SequenceFlow_0m403q5" sourceRef="ChangeModelVfModule" targetRef="CallActivity_sdncHandler" />
+ <bpmn:sequenceFlow id="SequenceFlow_0rpp4hi" sourceRef="CallActivity_sdncHandler" targetRef="UpdateVfModuleModel" />
</bpmn:process>
<bpmn:error id="Error_0q258vt" name="gDelegateError" errorCode="7000" />
<bpmndi:BPMNDiagram id="BPMNDiagram_1">
@@ -30,35 +39,45 @@
</bpmndi:BPMNShape>
<bpmndi:BPMNEdge id="SequenceFlow_0ieafii_di" bpmnElement="SequenceFlow_0ieafii">
<di:waypoint xsi:type="dc:Point" x="209" y="120" />
- <di:waypoint xsi:type="dc:Point" x="297" y="120" />
+ <di:waypoint xsi:type="dc:Point" x="259" y="120" />
<bpmndi:BPMNLabel>
- <dc:Bounds x="208" y="99" width="90" height="12" />
+ <dc:Bounds x="189" y="99" width="90" height="12" />
</bpmndi:BPMNLabel>
</bpmndi:BPMNEdge>
<bpmndi:BPMNShape id="EndEvent_1v967li_di" bpmnElement="ChangeModelVfModuleBB_End">
- <dc:Bounds x="636" y="102" width="36" height="36" />
+ <dc:Bounds x="693" y="102" width="36" height="36" />
<bpmndi:BPMNLabel>
- <dc:Bounds x="645" y="142" width="19" height="12" />
+ <dc:Bounds x="667" y="142" width="90" height="12" />
</bpmndi:BPMNLabel>
</bpmndi:BPMNShape>
<bpmndi:BPMNShape id="ServiceTask_0hawa84_di" bpmnElement="ChangeModelVfModule">
- <dc:Bounds x="297" y="80" width="100" height="80" />
+ <dc:Bounds x="259" y="80" width="100" height="80" />
</bpmndi:BPMNShape>
- <bpmndi:BPMNEdge id="SequenceFlow_14kvrbe_di" bpmnElement="SequenceFlow_14kvrbe">
- <di:waypoint xsi:type="dc:Point" x="397" y="120" />
- <di:waypoint xsi:type="dc:Point" x="435" y="120" />
+ <bpmndi:BPMNShape id="ServiceTask_175e9ul_di" bpmnElement="UpdateVfModuleModel">
+ <dc:Bounds x="552" y="80" width="100" height="80" />
+ </bpmndi:BPMNShape>
+ <bpmndi:BPMNEdge id="SequenceFlow_0xsp0pv_di" bpmnElement="SequenceFlow_0xsp0pv">
+ <di:waypoint xsi:type="dc:Point" x="652" y="120" />
+ <di:waypoint xsi:type="dc:Point" x="693" y="120" />
<bpmndi:BPMNLabel>
- <dc:Bounds x="371" y="99" width="90" height="12" />
+ <dc:Bounds x="627.5" y="99" width="90" height="12" />
</bpmndi:BPMNLabel>
</bpmndi:BPMNEdge>
- <bpmndi:BPMNShape id="ServiceTask_175e9ul_di" bpmnElement="UpdateVfModuleModel">
- <dc:Bounds x="435" y="80" width="100" height="80" />
+ <bpmndi:BPMNShape id="CallActivity_1y6gpyq_di" bpmnElement="CallActivity_sdncHandler">
+ <dc:Bounds x="403" y="80" width="100" height="80" />
</bpmndi:BPMNShape>
- <bpmndi:BPMNEdge id="SequenceFlow_0xsp0pv_di" bpmnElement="SequenceFlow_0xsp0pv">
- <di:waypoint xsi:type="dc:Point" x="535" y="120" />
- <di:waypoint xsi:type="dc:Point" x="636" y="120" />
+ <bpmndi:BPMNEdge id="SequenceFlow_0m403q5_di" bpmnElement="SequenceFlow_0m403q5">
+ <di:waypoint xsi:type="dc:Point" x="359" y="120" />
+ <di:waypoint xsi:type="dc:Point" x="403" y="120" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="381" y="99" width="0" height="12" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNEdge>
+ <bpmndi:BPMNEdge id="SequenceFlow_0rpp4hi_di" bpmnElement="SequenceFlow_0rpp4hi">
+ <di:waypoint xsi:type="dc:Point" x="503" y="120" />
+ <di:waypoint xsi:type="dc:Point" x="552" y="120" />
<bpmndi:BPMNLabel>
- <dc:Bounds x="540.5" y="99" width="90" height="12" />
+ <dc:Bounds x="527.5" y="99" width="0" height="12" />
</bpmndi:BPMNLabel>
</bpmndi:BPMNEdge>
</bpmndi:BPMNPlane>
diff --git a/bpmn/so-bpmn-building-blocks/src/main/resources/subprocess/BuildingBlock/ChangeModelVnfBB.bpmn b/bpmn/so-bpmn-building-blocks/src/main/resources/subprocess/BuildingBlock/ChangeModelVnfBB.bpmn
index b320c12a5e..59c35c3c5b 100644
--- a/bpmn/so-bpmn-building-blocks/src/main/resources/subprocess/BuildingBlock/ChangeModelVnfBB.bpmn
+++ b/bpmn/so-bpmn-building-blocks/src/main/resources/subprocess/BuildingBlock/ChangeModelVnfBB.bpmn
@@ -1,5 +1,5 @@
<?xml version="1.0" encoding="UTF-8"?>
-<bpmn2:definitions xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:bpmn2="http://www.omg.org/spec/BPMN/20100524/MODEL" xmlns:bpmndi="http://www.omg.org/spec/BPMN/20100524/DI" xmlns:camunda="http://camunda.org/schema/1.0/bpmn" xmlns:dc="http://www.omg.org/spec/DD/20100524/DC" xmlns:di="http://www.omg.org/spec/DD/20100524/DI" id="_MagIIMOUEeW8asg-vCEgWQ" targetNamespace="http://camunda.org/schema/1.0/bpmn" exporter="Camunda Modeler" exporterVersion="1.10.0" xsi:schemaLocation="http://www.omg.org/spec/BPMN/20100524/MODEL BPMN20.xsd">
+<bpmn2:definitions xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:bpmn2="http://www.omg.org/spec/BPMN/20100524/MODEL" xmlns:bpmndi="http://www.omg.org/spec/BPMN/20100524/DI" xmlns:camunda="http://camunda.org/schema/1.0/bpmn" xmlns:dc="http://www.omg.org/spec/DD/20100524/DC" xmlns:di="http://www.omg.org/spec/DD/20100524/DI" id="_MagIIMOUEeW8asg-vCEgWQ" targetNamespace="http://camunda.org/schema/1.0/bpmn" exporter="Camunda Modeler" exporterVersion="1.8.2" xsi:schemaLocation="http://www.omg.org/spec/BPMN/20100524/MODEL BPMN20.xsd">
<bpmn2:process id="ChangeModelVnfBB" name="ChangeModelVnfBB" isExecutable="true">
<bpmn2:startEvent id="ChangeModelVnf_Start">
<bpmn2:outgoing>SequenceFlow_18i4a05</bpmn2:outgoing>
@@ -8,14 +8,13 @@
<bpmn2:incoming>SequenceFlow_0g502yj</bpmn2:incoming>
</bpmn2:endEvent>
<bpmn2:sequenceFlow id="SequenceFlow_18i4a05" sourceRef="ChangeModelVnf_Start" targetRef="SDNCChangeModel" />
- <bpmn2:sequenceFlow id="SequenceFlow_19kfk17" sourceRef="SDNCChangeModel" targetRef="AAIUpdateModel" />
<bpmn2:sequenceFlow id="SequenceFlow_0g502yj" sourceRef="AAIUpdateModel" targetRef="ChangeModelVnf_End" />
<bpmn2:serviceTask id="SDNCChangeModel" name="&#10;SDNC&#10;Change &#10;(vnf model)&#10;" camunda:expression="${SDNCChangeAssignTasks.changeModelVnf(InjectExecution.execute(execution, execution.getVariable(&#34;gBuildingBlockExecution&#34;)))}">
<bpmn2:incoming>SequenceFlow_18i4a05</bpmn2:incoming>
- <bpmn2:outgoing>SequenceFlow_19kfk17</bpmn2:outgoing>
+ <bpmn2:outgoing>SequenceFlow_17yjhsl</bpmn2:outgoing>
</bpmn2:serviceTask>
<bpmn2:serviceTask id="AAIUpdateModel" name="&#10;AAI &#10;Update &#10;(vnf model)&#10;" camunda:expression="${AAIUpdateTasks.updateObjectVnf(InjectExecution.execute(execution, execution.getVariable(&#34;gBuildingBlockExecution&#34;)))}">
- <bpmn2:incoming>SequenceFlow_19kfk17</bpmn2:incoming>
+ <bpmn2:incoming>SequenceFlow_1h1zrcl</bpmn2:incoming>
<bpmn2:outgoing>SequenceFlow_0g502yj</bpmn2:outgoing>
</bpmn2:serviceTask>
<bpmn2:subProcess id="SubProcess_1nibii6" name="Error Handling&#10;&#10;" triggeredByEvent="true">
@@ -29,6 +28,16 @@
</bpmn2:endEvent>
<bpmn2:sequenceFlow id="SequenceFlow_0s2743f" sourceRef="StartEvent_1fnfrm5" targetRef="EndEvent_124ugc0" />
</bpmn2:subProcess>
+ <bpmn2:callActivity id="CallActivity_sdncHandlerCall" name="SDNC Change Model (vnf)" calledElement="SDNCHandler">
+ <bpmn2:extensionElements>
+ <camunda:in source="SDNCRequest" target="SDNCRequest" />
+ <camunda:out source="SDNCResponse" target="SDNCResponse" />
+ </bpmn2:extensionElements>
+ <bpmn2:incoming>SequenceFlow_17yjhsl</bpmn2:incoming>
+ <bpmn2:outgoing>SequenceFlow_1h1zrcl</bpmn2:outgoing>
+ </bpmn2:callActivity>
+ <bpmn2:sequenceFlow id="SequenceFlow_17yjhsl" sourceRef="SDNCChangeModel" targetRef="CallActivity_sdncHandlerCall" />
+ <bpmn2:sequenceFlow id="SequenceFlow_1h1zrcl" sourceRef="CallActivity_sdncHandlerCall" targetRef="AAIUpdateModel" />
</bpmn2:process>
<bpmn2:error id="Error_2" name="MSOWorkflowException" errorCode="MSOWorkflowException" />
<bpmn2:error id="Error_1" name="java.lang.Exception" errorCode="java.lang.Exception" />
@@ -49,30 +58,23 @@
</bpmndi:BPMNShape>
<bpmndi:BPMNEdge id="SequenceFlow_18i4a05_di" bpmnElement="SequenceFlow_18i4a05">
<di:waypoint xsi:type="dc:Point" x="111" y="106" />
- <di:waypoint xsi:type="dc:Point" x="213" y="106" />
+ <di:waypoint xsi:type="dc:Point" x="158" y="106" />
<bpmndi:BPMNLabel>
- <dc:Bounds x="162" y="85" width="0" height="12" />
- </bpmndi:BPMNLabel>
- </bpmndi:BPMNEdge>
- <bpmndi:BPMNEdge id="SequenceFlow_19kfk17_di" bpmnElement="SequenceFlow_19kfk17">
- <di:waypoint xsi:type="dc:Point" x="313" y="106" />
- <di:waypoint xsi:type="dc:Point" x="423" y="106" />
- <bpmndi:BPMNLabel>
- <dc:Bounds x="368" y="85" width="0" height="12" />
+ <dc:Bounds x="89.5" y="85" width="90" height="12" />
</bpmndi:BPMNLabel>
</bpmndi:BPMNEdge>
<bpmndi:BPMNEdge id="SequenceFlow_0g502yj_di" bpmnElement="SequenceFlow_0g502yj">
- <di:waypoint xsi:type="dc:Point" x="523" y="106" />
+ <di:waypoint xsi:type="dc:Point" x="590" y="106" />
<di:waypoint xsi:type="dc:Point" x="632" y="106" />
<bpmndi:BPMNLabel>
- <dc:Bounds x="577.5" y="85" width="0" height="12" />
+ <dc:Bounds x="566" y="85" width="90" height="12" />
</bpmndi:BPMNLabel>
</bpmndi:BPMNEdge>
<bpmndi:BPMNShape id="ServiceTask_03km5f0_di" bpmnElement="SDNCChangeModel">
- <dc:Bounds x="213" y="66" width="100" height="80" />
+ <dc:Bounds x="158" y="66" width="100" height="80" />
</bpmndi:BPMNShape>
<bpmndi:BPMNShape id="ServiceTask_10b2mxq_di" bpmnElement="AAIUpdateModel">
- <dc:Bounds x="423" y="66" width="100" height="80" />
+ <dc:Bounds x="490" y="66" width="100" height="80" />
</bpmndi:BPMNShape>
<bpmndi:BPMNShape id="SubProcess_1nibii6_di" bpmnElement="SubProcess_1nibii6" isExpanded="true">
<dc:Bounds x="164" y="244" width="231" height="135" />
@@ -96,6 +98,23 @@
<dc:Bounds x="287.5" y="297" width="0" height="12" />
</bpmndi:BPMNLabel>
</bpmndi:BPMNEdge>
+ <bpmndi:BPMNShape id="CallActivity_17x4av7_di" bpmnElement="CallActivity_sdncHandlerCall">
+ <dc:Bounds x="322" y="66" width="100" height="80" />
+ </bpmndi:BPMNShape>
+ <bpmndi:BPMNEdge id="SequenceFlow_17yjhsl_di" bpmnElement="SequenceFlow_17yjhsl">
+ <di:waypoint xsi:type="dc:Point" x="258" y="106" />
+ <di:waypoint xsi:type="dc:Point" x="322" y="106" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="290" y="85" width="0" height="12" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNEdge>
+ <bpmndi:BPMNEdge id="SequenceFlow_1h1zrcl_di" bpmnElement="SequenceFlow_1h1zrcl">
+ <di:waypoint xsi:type="dc:Point" x="422" y="106" />
+ <di:waypoint xsi:type="dc:Point" x="490" y="106" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="456" y="85" width="0" height="12" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNEdge>
</bpmndi:BPMNPlane>
</bpmndi:BPMNDiagram>
</bpmn2:definitions>
diff --git a/bpmn/so-bpmn-building-blocks/src/main/resources/subprocess/BuildingBlock/DeactivateNetworkBB.bpmn b/bpmn/so-bpmn-building-blocks/src/main/resources/subprocess/BuildingBlock/DeactivateNetworkBB.bpmn
index 5c85d17403..29a03c4e6b 100644
--- a/bpmn/so-bpmn-building-blocks/src/main/resources/subprocess/BuildingBlock/DeactivateNetworkBB.bpmn
+++ b/bpmn/so-bpmn-building-blocks/src/main/resources/subprocess/BuildingBlock/DeactivateNetworkBB.bpmn
@@ -1,5 +1,5 @@
<?xml version="1.0" encoding="UTF-8"?>
-<bpmn2:definitions xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:bpmn2="http://www.omg.org/spec/BPMN/20100524/MODEL" xmlns:bpmndi="http://www.omg.org/spec/BPMN/20100524/DI" xmlns:camunda="http://camunda.org/schema/1.0/bpmn" xmlns:dc="http://www.omg.org/spec/DD/20100524/DC" xmlns:di="http://www.omg.org/spec/DD/20100524/DI" id="_MagIIMOUEeW8asg-vCEgWQ" targetNamespace="http://camunda.org/schema/1.0/bpmn" exporter="Camunda Modeler" exporterVersion="1.10.0" xsi:schemaLocation="http://www.omg.org/spec/BPMN/20100524/MODEL BPMN20.xsd">
+<bpmn2:definitions xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:bpmn2="http://www.omg.org/spec/BPMN/20100524/MODEL" xmlns:bpmndi="http://www.omg.org/spec/BPMN/20100524/DI" xmlns:camunda="http://camunda.org/schema/1.0/bpmn" xmlns:dc="http://www.omg.org/spec/DD/20100524/DC" xmlns:di="http://www.omg.org/spec/DD/20100524/DI" id="_MagIIMOUEeW8asg-vCEgWQ" targetNamespace="http://camunda.org/schema/1.0/bpmn" exporter="Camunda Modeler" exporterVersion="1.8.2" xsi:schemaLocation="http://www.omg.org/spec/BPMN/20100524/MODEL BPMN20.xsd">
<bpmn2:process id="DeactivateNetworkBB" name="DeactivateNetworkBB" isExecutable="true">
<bpmn2:startEvent id="DeactivateNetworkBB_Start" name="Start">
<bpmn2:outgoing>SequenceFlow_05elmhj</bpmn2:outgoing>
@@ -9,15 +9,24 @@
</bpmn2:endEvent>
<bpmn2:serviceTask id="DeactivateNetworkSDNC" name="&#10;SDNC&#10;Deactivate Network &#10;" camunda:expression="${SDNCDeactivateTasks.deactivateNetwork(InjectExecution.execute(execution, execution.getVariable(&#34;gBuildingBlockExecution&#34;)))}">
<bpmn2:incoming>SequenceFlow_05elmhj</bpmn2:incoming>
- <bpmn2:outgoing>SequenceFlow_0xbvwsu</bpmn2:outgoing>
+ <bpmn2:outgoing>SequenceFlow_0hfjdl4</bpmn2:outgoing>
</bpmn2:serviceTask>
<bpmn2:serviceTask id="DeactivateNetworkAAI" name="&#10;AAI&#10;Update&#10;(network)&#10;" camunda:expression="${AAIUpdateTasks.updateOrchestrationStatusCreatedNetwork(InjectExecution.execute(execution, execution.getVariable(&#34;gBuildingBlockExecution&#34;)))}">
- <bpmn2:incoming>SequenceFlow_0xbvwsu</bpmn2:incoming>
+ <bpmn2:incoming>SequenceFlow_0cu0wy4</bpmn2:incoming>
<bpmn2:outgoing>SequenceFlow_18atf08</bpmn2:outgoing>
</bpmn2:serviceTask>
<bpmn2:sequenceFlow id="SequenceFlow_05elmhj" sourceRef="DeactivateNetworkBB_Start" targetRef="DeactivateNetworkSDNC" />
- <bpmn2:sequenceFlow id="SequenceFlow_0xbvwsu" sourceRef="DeactivateNetworkSDNC" targetRef="DeactivateNetworkAAI" />
<bpmn2:sequenceFlow id="SequenceFlow_18atf08" sourceRef="DeactivateNetworkAAI" targetRef="DeactivateNetworkBB_End" />
+ <bpmn2:callActivity id="CallActivity_sdncHandler" name="SDNC Deactivate (network)" calledElement="SDNCHandler">
+ <bpmn2:extensionElements>
+ <camunda:in source="SDNCRequest" target="SDNCRequest" />
+ <camunda:out source="SDNCResponse" target="SDNCResponse" />
+ </bpmn2:extensionElements>
+ <bpmn2:incoming>SequenceFlow_0hfjdl4</bpmn2:incoming>
+ <bpmn2:outgoing>SequenceFlow_0cu0wy4</bpmn2:outgoing>
+ </bpmn2:callActivity>
+ <bpmn2:sequenceFlow id="SequenceFlow_0hfjdl4" sourceRef="DeactivateNetworkSDNC" targetRef="CallActivity_sdncHandler" />
+ <bpmn2:sequenceFlow id="SequenceFlow_0cu0wy4" sourceRef="CallActivity_sdncHandler" targetRef="DeactivateNetworkAAI" />
</bpmn2:process>
<bpmn2:error id="Error_0pz4sdi" name="gDelegateError" errorCode="7000" />
<bpmn2:error id="Error_2" name="MSOWorkflowException" errorCode="MSOWorkflowException" />
@@ -31,40 +40,46 @@
</bpmndi:BPMNLabel>
</bpmndi:BPMNShape>
<bpmndi:BPMNShape id="EndEvent_10l9a3s_di" bpmnElement="DeactivateNetworkBB_End">
- <dc:Bounds x="672" y="100" width="36" height="36" />
+ <dc:Bounds x="773" y="100" width="36" height="36" />
<bpmndi:BPMNLabel>
- <dc:Bounds x="682" y="136" width="19" height="12" />
+ <dc:Bounds x="783" y="136" width="19" height="12" />
</bpmndi:BPMNLabel>
</bpmndi:BPMNShape>
<bpmndi:BPMNShape id="ServiceTask_1k7d8ih_di" bpmnElement="DeactivateNetworkSDNC">
- <dc:Bounds x="350" y="78" width="100" height="80" />
+ <dc:Bounds x="326" y="78" width="100" height="80" />
</bpmndi:BPMNShape>
<bpmndi:BPMNShape id="ServiceTask_1911vum_di" bpmnElement="DeactivateNetworkAAI">
- <dc:Bounds x="499" y="78" width="100" height="80" />
+ <dc:Bounds x="620" y="78" width="100" height="80" />
</bpmndi:BPMNShape>
<bpmndi:BPMNEdge id="SequenceFlow_05elmhj_di" bpmnElement="SequenceFlow_05elmhj">
<di:waypoint xsi:type="dc:Point" x="278" y="118" />
- <di:waypoint xsi:type="dc:Point" x="350" y="118" />
+ <di:waypoint xsi:type="dc:Point" x="326" y="118" />
<bpmndi:BPMNLabel>
- <dc:Bounds x="269" y="93" width="90" height="0" />
+ <dc:Bounds x="257" y="103" width="90" height="0" />
</bpmndi:BPMNLabel>
</bpmndi:BPMNEdge>
- <bpmndi:BPMNEdge id="SequenceFlow_0xbvwsu_di" bpmnElement="SequenceFlow_0xbvwsu">
- <di:waypoint xsi:type="dc:Point" x="450" y="118" />
- <di:waypoint xsi:type="dc:Point" x="475" y="118" />
- <di:waypoint xsi:type="dc:Point" x="475" y="118" />
- <di:waypoint xsi:type="dc:Point" x="499" y="118" />
+ <bpmndi:BPMNEdge id="SequenceFlow_18atf08_di" bpmnElement="SequenceFlow_18atf08">
+ <di:waypoint xsi:type="dc:Point" x="720" y="118" />
+ <di:waypoint xsi:type="dc:Point" x="773" y="118" />
<bpmndi:BPMNLabel>
- <dc:Bounds x="445" y="118" width="90" height="0" />
+ <dc:Bounds x="701.5" y="103" width="90" height="0" />
</bpmndi:BPMNLabel>
</bpmndi:BPMNEdge>
- <bpmndi:BPMNEdge id="SequenceFlow_18atf08_di" bpmnElement="SequenceFlow_18atf08">
- <di:waypoint xsi:type="dc:Point" x="599" y="118" />
- <di:waypoint xsi:type="dc:Point" x="636" y="118" />
- <di:waypoint xsi:type="dc:Point" x="636" y="118" />
- <di:waypoint xsi:type="dc:Point" x="672" y="118" />
+ <bpmndi:BPMNShape id="CallActivity_0q2nryd_di" bpmnElement="CallActivity_sdncHandler">
+ <dc:Bounds x="465" y="78" width="100" height="80" />
+ </bpmndi:BPMNShape>
+ <bpmndi:BPMNEdge id="SequenceFlow_0hfjdl4_di" bpmnElement="SequenceFlow_0hfjdl4">
+ <di:waypoint xsi:type="dc:Point" x="426" y="118" />
+ <di:waypoint xsi:type="dc:Point" x="465" y="118" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="445.5" y="97" width="0" height="12" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNEdge>
+ <bpmndi:BPMNEdge id="SequenceFlow_0cu0wy4_di" bpmnElement="SequenceFlow_0cu0wy4">
+ <di:waypoint xsi:type="dc:Point" x="565" y="118" />
+ <di:waypoint xsi:type="dc:Point" x="620" y="118" />
<bpmndi:BPMNLabel>
- <dc:Bounds x="606" y="118" width="90" height="0" />
+ <dc:Bounds x="592.5" y="97" width="0" height="12" />
</bpmndi:BPMNLabel>
</bpmndi:BPMNEdge>
</bpmndi:BPMNPlane>
diff --git a/bpmn/so-bpmn-building-blocks/src/main/resources/subprocess/BuildingBlock/DeactivateServiceInstanceBB.bpmn b/bpmn/so-bpmn-building-blocks/src/main/resources/subprocess/BuildingBlock/DeactivateServiceInstanceBB.bpmn
index 5284788b89..41517871d0 100644
--- a/bpmn/so-bpmn-building-blocks/src/main/resources/subprocess/BuildingBlock/DeactivateServiceInstanceBB.bpmn
+++ b/bpmn/so-bpmn-building-blocks/src/main/resources/subprocess/BuildingBlock/DeactivateServiceInstanceBB.bpmn
@@ -1,5 +1,5 @@
<?xml version="1.0" encoding="UTF-8"?>
-<bpmn:definitions xmlns:bpmn="http://www.omg.org/spec/BPMN/20100524/MODEL" xmlns:bpmndi="http://www.omg.org/spec/BPMN/20100524/DI" xmlns:di="http://www.omg.org/spec/DD/20100524/DI" xmlns:dc="http://www.omg.org/spec/DD/20100524/DC" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:camunda="http://camunda.org/schema/1.0/bpmn" id="Definitions_1" targetNamespace="http://bpmn.io/schema/bpmn" exporter="Camunda Modeler" exporterVersion="1.10.0">
+<bpmn:definitions xmlns:bpmn="http://www.omg.org/spec/BPMN/20100524/MODEL" xmlns:bpmndi="http://www.omg.org/spec/BPMN/20100524/DI" xmlns:di="http://www.omg.org/spec/DD/20100524/DI" xmlns:dc="http://www.omg.org/spec/DD/20100524/DC" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:camunda="http://camunda.org/schema/1.0/bpmn" id="Definitions_1" targetNamespace="http://bpmn.io/schema/bpmn" exporter="Camunda Modeler" exporterVersion="1.8.2">
<bpmn:process id="DeactivateServiceInstanceBB" name="DeactivateServiceInstanceBB" isExecutable="true">
<bpmn:startEvent id="Start_DeactivateServiceInstanceBB" name="Start">
<bpmn:outgoing>SequenceFlow_101w1ck</bpmn:outgoing>
@@ -7,17 +7,26 @@
<bpmn:endEvent id="End_DeactivateServiceInstanceBB" name="end">
<bpmn:incoming>SequenceFlow_0pioehv</bpmn:incoming>
</bpmn:endEvent>
- <bpmn:sequenceFlow id="SequenceFlow_00q7fsg" sourceRef="Task_DeactivateServiceInstance_SDNC" targetRef="Task_DeactivateServiceInstance_AAI" />
<bpmn:sequenceFlow id="SequenceFlow_0pioehv" sourceRef="Task_DeactivateServiceInstance_AAI" targetRef="End_DeactivateServiceInstanceBB" />
<bpmn:serviceTask id="Task_DeactivateServiceInstance_AAI" name="&#10;AAI&#10;Update&#10;(svc instance)&#10;" camunda:expression="${AAIUpdateTasks.updateOrchestrationStatusAssignedService(InjectExecution.execute(execution, execution.getVariable(&#34;gBuildingBlockExecution&#34;)))}">
- <bpmn:incoming>SequenceFlow_00q7fsg</bpmn:incoming>
+ <bpmn:incoming>SequenceFlow_1ck1p4o</bpmn:incoming>
<bpmn:outgoing>SequenceFlow_0pioehv</bpmn:outgoing>
</bpmn:serviceTask>
<bpmn:serviceTask id="Task_DeactivateServiceInstance_SDNC" name="&#10;SDNC &#10;Deactivate&#10;(svc instance)&#10;" camunda:expression="${SDNCDeactivateTasks.deactivateServiceInstance(InjectExecution.execute(execution, execution.getVariable(&#34;gBuildingBlockExecution&#34;)))}">
<bpmn:incoming>SequenceFlow_101w1ck</bpmn:incoming>
- <bpmn:outgoing>SequenceFlow_00q7fsg</bpmn:outgoing>
+ <bpmn:outgoing>SequenceFlow_1j9qa4p</bpmn:outgoing>
</bpmn:serviceTask>
<bpmn:sequenceFlow id="SequenceFlow_101w1ck" sourceRef="Start_DeactivateServiceInstanceBB" targetRef="Task_DeactivateServiceInstance_SDNC" />
+ <bpmn:callActivity id="CallActivity_sdncHandler" name="SDNC Deactivate (svc instance)" calledElement="SDNCHandler">
+ <bpmn:extensionElements>
+ <camunda:in source="SDNCRequest" target="SDNCRequest" />
+ <camunda:out source="SDNCResponse" target="SDNCResponse" />
+ </bpmn:extensionElements>
+ <bpmn:incoming>SequenceFlow_1j9qa4p</bpmn:incoming>
+ <bpmn:outgoing>SequenceFlow_1ck1p4o</bpmn:outgoing>
+ </bpmn:callActivity>
+ <bpmn:sequenceFlow id="SequenceFlow_1ck1p4o" sourceRef="CallActivity_sdncHandler" targetRef="Task_DeactivateServiceInstance_AAI" />
+ <bpmn:sequenceFlow id="SequenceFlow_1j9qa4p" sourceRef="Task_DeactivateServiceInstance_SDNC" targetRef="CallActivity_sdncHandler" />
</bpmn:process>
<bpmn:error id="Error_05rnr6a" name="gDelegateError" errorCode="7000" />
<bpmndi:BPMNDiagram id="BPMNDiagram_1">
@@ -29,27 +38,20 @@
</bpmndi:BPMNLabel>
</bpmndi:BPMNShape>
<bpmndi:BPMNShape id="EndEvent_1qdtskz_di" bpmnElement="End_DeactivateServiceInstanceBB">
- <dc:Bounds x="416" y="102" width="36" height="36" />
+ <dc:Bounds x="541" y="102" width="36" height="36" />
<bpmndi:BPMNLabel>
- <dc:Bounds x="425" y="142" width="18" height="12" />
+ <dc:Bounds x="550" y="142" width="18" height="12" />
</bpmndi:BPMNLabel>
</bpmndi:BPMNShape>
- <bpmndi:BPMNEdge id="SequenceFlow_00q7fsg_di" bpmnElement="SequenceFlow_00q7fsg">
- <di:waypoint xsi:type="dc:Point" x="216" y="120" />
- <di:waypoint xsi:type="dc:Point" x="262" y="120" />
- <bpmndi:BPMNLabel>
- <dc:Bounds x="239" y="105" width="0" height="0" />
- </bpmndi:BPMNLabel>
- </bpmndi:BPMNEdge>
<bpmndi:BPMNEdge id="SequenceFlow_0pioehv_di" bpmnElement="SequenceFlow_0pioehv">
- <di:waypoint xsi:type="dc:Point" x="362" y="120" />
- <di:waypoint xsi:type="dc:Point" x="416" y="120" />
+ <di:waypoint xsi:type="dc:Point" x="520" y="120" />
+ <di:waypoint xsi:type="dc:Point" x="541" y="120" />
<bpmndi:BPMNLabel>
- <dc:Bounds x="389" y="99" width="0" height="0" />
+ <dc:Bounds x="485.5" y="105" width="90" height="0" />
</bpmndi:BPMNLabel>
</bpmndi:BPMNEdge>
<bpmndi:BPMNShape id="ServiceTask_1d9vh4e_di" bpmnElement="Task_DeactivateServiceInstance_AAI">
- <dc:Bounds x="262" y="80" width="100" height="80" />
+ <dc:Bounds x="420" y="80" width="100" height="80" />
</bpmndi:BPMNShape>
<bpmndi:BPMNShape id="ServiceTask_04l854m_di" bpmnElement="Task_DeactivateServiceInstance_SDNC">
<dc:Bounds x="116" y="80" width="100" height="80" />
@@ -61,6 +63,23 @@
<dc:Bounds x="87.5" y="99" width="0" height="12" />
</bpmndi:BPMNLabel>
</bpmndi:BPMNEdge>
+ <bpmndi:BPMNShape id="CallActivity_0fm7piq_di" bpmnElement="CallActivity_sdncHandler">
+ <dc:Bounds x="265" y="80" width="100" height="80" />
+ </bpmndi:BPMNShape>
+ <bpmndi:BPMNEdge id="SequenceFlow_1ck1p4o_di" bpmnElement="SequenceFlow_1ck1p4o">
+ <di:waypoint xsi:type="dc:Point" x="365" y="120" />
+ <di:waypoint xsi:type="dc:Point" x="420" y="120" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="392.5" y="99" width="0" height="12" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNEdge>
+ <bpmndi:BPMNEdge id="SequenceFlow_1j9qa4p_di" bpmnElement="SequenceFlow_1j9qa4p">
+ <di:waypoint xsi:type="dc:Point" x="216" y="120" />
+ <di:waypoint xsi:type="dc:Point" x="265" y="120" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="240.5" y="99" width="0" height="12" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNEdge>
</bpmndi:BPMNPlane>
</bpmndi:BPMNDiagram>
</bpmn:definitions>
diff --git a/bpmn/so-bpmn-building-blocks/src/main/resources/subprocess/BuildingBlock/DeactivateVfModuleBB.bpmn b/bpmn/so-bpmn-building-blocks/src/main/resources/subprocess/BuildingBlock/DeactivateVfModuleBB.bpmn
index f30a1f18ce..37fd2dbd98 100644
--- a/bpmn/so-bpmn-building-blocks/src/main/resources/subprocess/BuildingBlock/DeactivateVfModuleBB.bpmn
+++ b/bpmn/so-bpmn-building-blocks/src/main/resources/subprocess/BuildingBlock/DeactivateVfModuleBB.bpmn
@@ -1,23 +1,32 @@
<?xml version="1.0" encoding="UTF-8"?>
-<bpmn:definitions xmlns:bpmn="http://www.omg.org/spec/BPMN/20100524/MODEL" xmlns:bpmndi="http://www.omg.org/spec/BPMN/20100524/DI" xmlns:di="http://www.omg.org/spec/DD/20100524/DI" xmlns:dc="http://www.omg.org/spec/DD/20100524/DC" xmlns:camunda="http://camunda.org/schema/1.0/bpmn" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" id="Definitions_1" targetNamespace="http://bpmn.io/schema/bpmn" exporter="Camunda Modeler" exporterVersion="1.10.0">
+<bpmn:definitions xmlns:bpmn="http://www.omg.org/spec/BPMN/20100524/MODEL" xmlns:bpmndi="http://www.omg.org/spec/BPMN/20100524/DI" xmlns:di="http://www.omg.org/spec/DD/20100524/DI" xmlns:dc="http://www.omg.org/spec/DD/20100524/DC" xmlns:camunda="http://camunda.org/schema/1.0/bpmn" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" id="Definitions_1" targetNamespace="http://bpmn.io/schema/bpmn" exporter="Camunda Modeler" exporterVersion="1.8.2">
<bpmn:process id="DeactivateVfModuleBB" name="DeactivateVfModuleBB" isExecutable="true">
<bpmn:startEvent id="DeactivateVfModuleBB_Start" name="Start">
<bpmn:outgoing>SequenceFlow_0m379r2</bpmn:outgoing>
</bpmn:startEvent>
<bpmn:serviceTask id="DeactivateVfModule" name="&#10;SDNC &#10;Deactivate&#10;(vf module)&#10;" camunda:expression="${SDNCDeactivateTasks.deactivateVfModule(InjectExecution.execute(execution, execution.getVariable(&#34;gBuildingBlockExecution&#34;)))}">
<bpmn:incoming>SequenceFlow_0m379r2</bpmn:incoming>
- <bpmn:outgoing>SequenceFlow_01bdpek</bpmn:outgoing>
+ <bpmn:outgoing>SequenceFlow_15ep3y7</bpmn:outgoing>
</bpmn:serviceTask>
<bpmn:sequenceFlow id="SequenceFlow_0m379r2" sourceRef="DeactivateVfModuleBB_Start" targetRef="DeactivateVfModule" />
<bpmn:serviceTask id="UpdateVfModuleDeactivateStatus" name="&#10;AAI &#10;Update&#10;(vf module)&#10;" camunda:expression="${AAIUpdateTasks.updateOrchestrationStatusDeactivateVfModule(InjectExecution.execute(execution, execution.getVariable(&#34;gBuildingBlockExecution&#34;)))}">
- <bpmn:incoming>SequenceFlow_01bdpek</bpmn:incoming>
+ <bpmn:incoming>SequenceFlow_1gx4xce</bpmn:incoming>
<bpmn:outgoing>SequenceFlow_1y1c7fh</bpmn:outgoing>
</bpmn:serviceTask>
- <bpmn:sequenceFlow id="SequenceFlow_01bdpek" sourceRef="DeactivateVfModule" targetRef="UpdateVfModuleDeactivateStatus" />
<bpmn:endEvent id="DeactivateVfModuleBB_End" name="End">
<bpmn:incoming>SequenceFlow_1y1c7fh</bpmn:incoming>
</bpmn:endEvent>
<bpmn:sequenceFlow id="SequenceFlow_1y1c7fh" sourceRef="UpdateVfModuleDeactivateStatus" targetRef="DeactivateVfModuleBB_End" />
+ <bpmn:callActivity id="CallActivity_sdncHandler" name="SDNC Deactivate (vf module)" calledElement="SDNCHandler">
+ <bpmn:extensionElements>
+ <camunda:in source="SDNCRequest" target="SDNCRequest" />
+ <camunda:out source="SDNCResponse" target="SDNCResponse" />
+ </bpmn:extensionElements>
+ <bpmn:incoming>SequenceFlow_15ep3y7</bpmn:incoming>
+ <bpmn:outgoing>SequenceFlow_1gx4xce</bpmn:outgoing>
+ </bpmn:callActivity>
+ <bpmn:sequenceFlow id="SequenceFlow_15ep3y7" sourceRef="DeactivateVfModule" targetRef="CallActivity_sdncHandler" />
+ <bpmn:sequenceFlow id="SequenceFlow_1gx4xce" sourceRef="CallActivity_sdncHandler" targetRef="UpdateVfModuleDeactivateStatus" />
</bpmn:process>
<bpmn:error id="Error_0qg4xhp" name="gDelegateError" errorCode="7000" />
<bpmndi:BPMNDiagram id="BPMNDiagram_1">
@@ -29,40 +38,46 @@
</bpmndi:BPMNLabel>
</bpmndi:BPMNShape>
<bpmndi:BPMNShape id="ServiceTask_0rz90rp_di" bpmnElement="DeactivateVfModule">
- <dc:Bounds x="275" y="80" width="100" height="80" />
+ <dc:Bounds x="261" y="80" width="100" height="80" />
</bpmndi:BPMNShape>
<bpmndi:BPMNEdge id="SequenceFlow_0m379r2_di" bpmnElement="SequenceFlow_0m379r2">
<di:waypoint xsi:type="dc:Point" x="209" y="120" />
- <di:waypoint xsi:type="dc:Point" x="275" y="120" />
+ <di:waypoint xsi:type="dc:Point" x="261" y="120" />
<bpmndi:BPMNLabel>
- <dc:Bounds x="242" y="99" width="0" height="12" />
+ <dc:Bounds x="190" y="99" width="90" height="12" />
</bpmndi:BPMNLabel>
</bpmndi:BPMNEdge>
<bpmndi:BPMNShape id="ServiceTask_0lyevan_di" bpmnElement="UpdateVfModuleDeactivateStatus">
- <dc:Bounds x="432" y="80" width="100" height="80" />
+ <dc:Bounds x="550" y="80" width="100" height="80" />
</bpmndi:BPMNShape>
- <bpmndi:BPMNEdge id="SequenceFlow_01bdpek_di" bpmnElement="SequenceFlow_01bdpek">
- <di:waypoint xsi:type="dc:Point" x="375" y="120" />
- <di:waypoint xsi:type="dc:Point" x="401" y="120" />
- <di:waypoint xsi:type="dc:Point" x="401" y="120" />
- <di:waypoint xsi:type="dc:Point" x="432" y="120" />
- <bpmndi:BPMNLabel>
- <dc:Bounds x="416" y="114" width="0" height="12" />
- </bpmndi:BPMNLabel>
- </bpmndi:BPMNEdge>
<bpmndi:BPMNShape id="EndEvent_1h4ik86_di" bpmnElement="DeactivateVfModuleBB_End">
- <dc:Bounds x="589" y="102" width="36" height="36" />
+ <dc:Bounds x="686" y="102" width="36" height="36" />
<bpmndi:BPMNLabel>
- <dc:Bounds x="598" y="142" width="19" height="12" />
+ <dc:Bounds x="695" y="142" width="19" height="12" />
</bpmndi:BPMNLabel>
</bpmndi:BPMNShape>
<bpmndi:BPMNEdge id="SequenceFlow_1y1c7fh_di" bpmnElement="SequenceFlow_1y1c7fh">
- <di:waypoint xsi:type="dc:Point" x="532" y="120" />
- <di:waypoint xsi:type="dc:Point" x="557" y="120" />
- <di:waypoint xsi:type="dc:Point" x="557" y="120" />
- <di:waypoint xsi:type="dc:Point" x="589" y="120" />
+ <di:waypoint xsi:type="dc:Point" x="650" y="120" />
+ <di:waypoint xsi:type="dc:Point" x="686" y="120" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="623" y="99" width="90" height="12" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNEdge>
+ <bpmndi:BPMNShape id="CallActivity_0pp1hlz_di" bpmnElement="CallActivity_sdncHandler">
+ <dc:Bounds x="401" y="80" width="100" height="80" />
+ </bpmndi:BPMNShape>
+ <bpmndi:BPMNEdge id="SequenceFlow_15ep3y7_di" bpmnElement="SequenceFlow_15ep3y7">
+ <di:waypoint xsi:type="dc:Point" x="361" y="120" />
+ <di:waypoint xsi:type="dc:Point" x="401" y="120" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="381" y="99" width="0" height="12" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNEdge>
+ <bpmndi:BPMNEdge id="SequenceFlow_1gx4xce_di" bpmnElement="SequenceFlow_1gx4xce">
+ <di:waypoint xsi:type="dc:Point" x="501" y="120" />
+ <di:waypoint xsi:type="dc:Point" x="550" y="120" />
<bpmndi:BPMNLabel>
- <dc:Bounds x="572" y="114" width="0" height="12" />
+ <dc:Bounds x="525.5" y="99" width="0" height="12" />
</bpmndi:BPMNLabel>
</bpmndi:BPMNEdge>
</bpmndi:BPMNPlane>
diff --git a/bpmn/so-bpmn-building-blocks/src/main/resources/subprocess/BuildingBlock/DeactivateVnfBB.bpmn b/bpmn/so-bpmn-building-blocks/src/main/resources/subprocess/BuildingBlock/DeactivateVnfBB.bpmn
index 790cab1737..c627789119 100644
--- a/bpmn/so-bpmn-building-blocks/src/main/resources/subprocess/BuildingBlock/DeactivateVnfBB.bpmn
+++ b/bpmn/so-bpmn-building-blocks/src/main/resources/subprocess/BuildingBlock/DeactivateVnfBB.bpmn
@@ -1,23 +1,32 @@
<?xml version="1.0" encoding="UTF-8"?>
-<bpmn:definitions xmlns:bpmn="http://www.omg.org/spec/BPMN/20100524/MODEL" xmlns:bpmndi="http://www.omg.org/spec/BPMN/20100524/DI" xmlns:di="http://www.omg.org/spec/DD/20100524/DI" xmlns:dc="http://www.omg.org/spec/DD/20100524/DC" xmlns:camunda="http://camunda.org/schema/1.0/bpmn" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" id="Definitions_1" targetNamespace="http://bpmn.io/schema/bpmn" exporter="Camunda Modeler" exporterVersion="1.10.0">
+<bpmn:definitions xmlns:bpmn="http://www.omg.org/spec/BPMN/20100524/MODEL" xmlns:bpmndi="http://www.omg.org/spec/BPMN/20100524/DI" xmlns:di="http://www.omg.org/spec/DD/20100524/DI" xmlns:dc="http://www.omg.org/spec/DD/20100524/DC" xmlns:camunda="http://camunda.org/schema/1.0/bpmn" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" id="Definitions_1" targetNamespace="http://bpmn.io/schema/bpmn" exporter="Camunda Modeler" exporterVersion="1.8.2">
<bpmn:process id="DeactivateVnfBB" name="DeactivateVnfBB" isExecutable="true">
<bpmn:startEvent id="Start_DeactivateVnfBB" name="start">
<bpmn:outgoing>SequenceFlow_0k9qnoi</bpmn:outgoing>
</bpmn:startEvent>
<bpmn:sequenceFlow id="SequenceFlow_0k9qnoi" sourceRef="Start_DeactivateVnfBB" targetRef="Task_SDNCAdapterVnfTopologyDeactivate" />
- <bpmn:sequenceFlow id="SequenceFlow_0r6pzwt" sourceRef="Task_SDNCAdapterVnfTopologyDeactivate" targetRef="Task_DeactivateOrchestrationStatusVnf" />
<bpmn:endEvent id="End_DeactivateVnfBB" name="end">
<bpmn:incoming>SequenceFlow_0vnitwg</bpmn:incoming>
</bpmn:endEvent>
<bpmn:sequenceFlow id="SequenceFlow_0vnitwg" sourceRef="Task_DeactivateOrchestrationStatusVnf" targetRef="End_DeactivateVnfBB" />
<bpmn:serviceTask id="Task_SDNCAdapterVnfTopologyDeactivate" name="&#10;SDNC Deactivate&#10;(vnf)&#10;" camunda:expression="${SDNCDeactivateTasks.deactivateVnf(InjectExecution.execute(execution, execution.getVariable(&#34;gBuildingBlockExecution&#34;)))}">
<bpmn:incoming>SequenceFlow_0k9qnoi</bpmn:incoming>
- <bpmn:outgoing>SequenceFlow_0r6pzwt</bpmn:outgoing>
+ <bpmn:outgoing>SequenceFlow_000o6c2</bpmn:outgoing>
</bpmn:serviceTask>
<bpmn:serviceTask id="Task_DeactivateOrchestrationStatusVnf" name="&#10;AAI &#10;Update&#10;(vnf)&#10;" camunda:expression="${AAIUpdateTasks.updateOrchestrationStatusAssignedVnf(InjectExecution.execute(execution, execution.getVariable(&#34;gBuildingBlockExecution&#34;)))}">
- <bpmn:incoming>SequenceFlow_0r6pzwt</bpmn:incoming>
+ <bpmn:incoming>SequenceFlow_1ageldf</bpmn:incoming>
<bpmn:outgoing>SequenceFlow_0vnitwg</bpmn:outgoing>
</bpmn:serviceTask>
+ <bpmn:callActivity id="CallActivity_sdncHandler" name="SDNC Deactivate (vnf)" calledElement="SDNCHandler">
+ <bpmn:extensionElements>
+ <camunda:in source="SDNCRequest" target="SDNCRequest" />
+ <camunda:out source="SDNCResponse" target="SDNCResponse" />
+ </bpmn:extensionElements>
+ <bpmn:incoming>SequenceFlow_000o6c2</bpmn:incoming>
+ <bpmn:outgoing>SequenceFlow_1ageldf</bpmn:outgoing>
+ </bpmn:callActivity>
+ <bpmn:sequenceFlow id="SequenceFlow_000o6c2" sourceRef="Task_SDNCAdapterVnfTopologyDeactivate" targetRef="CallActivity_sdncHandler" />
+ <bpmn:sequenceFlow id="SequenceFlow_1ageldf" sourceRef="CallActivity_sdncHandler" targetRef="Task_DeactivateOrchestrationStatusVnf" />
</bpmn:process>
<bpmndi:BPMNDiagram id="BPMNDiagram_1">
<bpmndi:BPMNPlane id="BPMNPlane_1" bpmnElement="DeactivateVnfBB">
@@ -34,32 +43,42 @@
<dc:Bounds x="236" y="99" width="0" height="12" />
</bpmndi:BPMNLabel>
</bpmndi:BPMNEdge>
- <bpmndi:BPMNEdge id="SequenceFlow_0r6pzwt_di" bpmnElement="SequenceFlow_0r6pzwt">
- <di:waypoint xsi:type="dc:Point" x="363" y="120" />
- <di:waypoint xsi:type="dc:Point" x="422" y="120" />
- <bpmndi:BPMNLabel>
- <dc:Bounds x="392.5" y="99" width="0" height="12" />
- </bpmndi:BPMNLabel>
- </bpmndi:BPMNEdge>
<bpmndi:BPMNShape id="EndEvent_1ad7eym_di" bpmnElement="End_DeactivateVnfBB">
- <dc:Bounds x="572" y="102" width="36" height="36" />
+ <dc:Bounds x="753" y="102" width="36" height="36" />
<bpmndi:BPMNLabel>
- <dc:Bounds x="580" y="142" width="20" height="12" />
+ <dc:Bounds x="762" y="142" width="18" height="12" />
</bpmndi:BPMNLabel>
</bpmndi:BPMNShape>
<bpmndi:BPMNEdge id="SequenceFlow_0vnitwg_di" bpmnElement="SequenceFlow_0vnitwg">
- <di:waypoint xsi:type="dc:Point" x="522" y="120" />
- <di:waypoint xsi:type="dc:Point" x="572" y="120" />
+ <di:waypoint xsi:type="dc:Point" x="708" y="120" />
+ <di:waypoint xsi:type="dc:Point" x="753" y="120" />
<bpmndi:BPMNLabel>
- <dc:Bounds x="547" y="99" width="0" height="12" />
+ <dc:Bounds x="685.5" y="99" width="90" height="12" />
</bpmndi:BPMNLabel>
</bpmndi:BPMNEdge>
<bpmndi:BPMNShape id="ServiceTask_1k98q3r_di" bpmnElement="Task_SDNCAdapterVnfTopologyDeactivate">
<dc:Bounds x="263" y="80" width="100" height="80" />
</bpmndi:BPMNShape>
<bpmndi:BPMNShape id="ServiceTask_1vg25fs_di" bpmnElement="Task_DeactivateOrchestrationStatusVnf">
- <dc:Bounds x="422" y="80" width="100" height="80" />
+ <dc:Bounds x="608" y="80" width="100" height="80" />
+ </bpmndi:BPMNShape>
+ <bpmndi:BPMNShape id="CallActivity_1t6shsw_di" bpmnElement="CallActivity_sdncHandler">
+ <dc:Bounds x="431" y="80" width="100" height="80" />
</bpmndi:BPMNShape>
+ <bpmndi:BPMNEdge id="SequenceFlow_000o6c2_di" bpmnElement="SequenceFlow_000o6c2">
+ <di:waypoint xsi:type="dc:Point" x="363" y="120" />
+ <di:waypoint xsi:type="dc:Point" x="431" y="120" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="397" y="99" width="0" height="12" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNEdge>
+ <bpmndi:BPMNEdge id="SequenceFlow_1ageldf_di" bpmnElement="SequenceFlow_1ageldf">
+ <di:waypoint xsi:type="dc:Point" x="531" y="120" />
+ <di:waypoint xsi:type="dc:Point" x="608" y="120" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="569.5" y="99" width="0" height="12" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNEdge>
</bpmndi:BPMNPlane>
</bpmndi:BPMNDiagram>
</bpmn:definitions>
diff --git a/bpmn/so-bpmn-building-blocks/src/main/resources/subprocess/BuildingBlock/UnassignNetworkBB.bpmn b/bpmn/so-bpmn-building-blocks/src/main/resources/subprocess/BuildingBlock/UnassignNetworkBB.bpmn
index fdae49fdda..8e4c8501b5 100644
--- a/bpmn/so-bpmn-building-blocks/src/main/resources/subprocess/BuildingBlock/UnassignNetworkBB.bpmn
+++ b/bpmn/so-bpmn-building-blocks/src/main/resources/subprocess/BuildingBlock/UnassignNetworkBB.bpmn
@@ -1,21 +1,20 @@
<?xml version="1.0" encoding="UTF-8"?>
-<bpmn:definitions xmlns:bpmn="http://www.omg.org/spec/BPMN/20100524/MODEL" xmlns:bpmndi="http://www.omg.org/spec/BPMN/20100524/DI" xmlns:di="http://www.omg.org/spec/DD/20100524/DI" xmlns:dc="http://www.omg.org/spec/DD/20100524/DC" xmlns:camunda="http://camunda.org/schema/1.0/bpmn" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" id="Definitions_1" targetNamespace="http://bpmn.io/schema/bpmn" exporter="Camunda Modeler" exporterVersion="1.10.0">
+<bpmn:definitions xmlns:bpmn="http://www.omg.org/spec/BPMN/20100524/MODEL" xmlns:bpmndi="http://www.omg.org/spec/BPMN/20100524/DI" xmlns:di="http://www.omg.org/spec/DD/20100524/DI" xmlns:dc="http://www.omg.org/spec/DD/20100524/DC" xmlns:camunda="http://camunda.org/schema/1.0/bpmn" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" id="Definitions_1" targetNamespace="http://bpmn.io/schema/bpmn" exporter="Camunda Modeler" exporterVersion="1.8.2">
<bpmn:process id="UnassignNetworkBB" name="UnassignNetworkBB" isExecutable="true">
<bpmn:startEvent id="Start_UnassignNetworkBB" name="start">
<bpmn:outgoing>SequenceFlow_0zaz9o2</bpmn:outgoing>
</bpmn:startEvent>
<bpmn:serviceTask id="Task_SNDCUnAssign" name="&#10;SDNC&#10;Unassign&#10;(network)&#10;" camunda:expression="${SDNCUnassignTasks.unassignNetwork(InjectExecution.execute(execution, execution.getVariable(&#34;gBuildingBlockExecution&#34;)))}">
<bpmn:incoming>SequenceFlow_0le4vrj</bpmn:incoming>
- <bpmn:outgoing>SequenceFlow_1ks8kmt</bpmn:outgoing>
+ <bpmn:outgoing>SequenceFlow_1woj6rc</bpmn:outgoing>
</bpmn:serviceTask>
<bpmn:endEvent id="End_UnassignNetworkBB" name="end">
<bpmn:incoming>SequenceFlow_0csh9dc</bpmn:incoming>
</bpmn:endEvent>
<bpmn:sequenceFlow id="SequenceFlow_0zaz9o2" sourceRef="Start_UnassignNetworkBB" targetRef="Task_VfModuleRelatioship" />
- <bpmn:sequenceFlow id="SequenceFlow_1ks8kmt" sourceRef="Task_SNDCUnAssign" targetRef="Task_DeleteNetwork" />
<bpmn:sequenceFlow id="SequenceFlow_0csh9dc" sourceRef="Task_DeleteNetwork" targetRef="End_UnassignNetworkBB" />
<bpmn:serviceTask id="Task_DeleteNetwork" name="&#10;AAI&#10;Delete&#10;(network)&#10;" camunda:expression="${AAIDeleteTasks.deleteNetwork(InjectExecution.execute(execution, execution.getVariable(&#34;gBuildingBlockExecution&#34;)))}">
- <bpmn:incoming>SequenceFlow_1ks8kmt</bpmn:incoming>
+ <bpmn:incoming>SequenceFlow_15oc7ot</bpmn:incoming>
<bpmn:outgoing>SequenceFlow_0csh9dc</bpmn:outgoing>
</bpmn:serviceTask>
<bpmn:serviceTask id="Task_VfModuleRelatioship" name="Veriyf &#39;vf-module&#39; relationship exists" camunda:expression="${UnassignNetworkBB.checkRelationshipRelatedTo(InjectExecution.execute(execution, execution.getVariable(&#34;gBuildingBlockExecution&#34;)), &#34;vf-module&#34;)}">
@@ -28,6 +27,16 @@
<bpmn:incoming>SequenceFlow_0mxe1a7</bpmn:incoming>
<bpmn:outgoing>SequenceFlow_0le4vrj</bpmn:outgoing>
</bpmn:serviceTask>
+ <bpmn:callActivity id="CallActivity_sdncHandlerCall" name="SDNC Unassign (network)" calledElement="SDNCHandler">
+ <bpmn:extensionElements>
+ <camunda:in source="SDNCRequest" target="SDNCRequest" />
+ <camunda:out source="SDNCResponse" target="SDNCResponse" />
+ </bpmn:extensionElements>
+ <bpmn:incoming>SequenceFlow_1woj6rc</bpmn:incoming>
+ <bpmn:outgoing>SequenceFlow_15oc7ot</bpmn:outgoing>
+ </bpmn:callActivity>
+ <bpmn:sequenceFlow id="SequenceFlow_1woj6rc" sourceRef="Task_SNDCUnAssign" targetRef="CallActivity_sdncHandlerCall" />
+ <bpmn:sequenceFlow id="SequenceFlow_15oc7ot" sourceRef="CallActivity_sdncHandlerCall" targetRef="Task_DeleteNetwork" />
</bpmn:process>
<bpmndi:BPMNDiagram id="BPMNDiagram_1">
<bpmndi:BPMNPlane id="BPMNPlane_1" bpmnElement="UnassignNetworkBB">
@@ -41,9 +50,9 @@
<dc:Bounds x="665" y="97" width="100" height="80" />
</bpmndi:BPMNShape>
<bpmndi:BPMNShape id="EndEvent_1h93h9d_di" bpmnElement="End_UnassignNetworkBB">
- <dc:Bounds x="946" y="119" width="36" height="36" />
+ <dc:Bounds x="1084" y="119" width="36" height="36" />
<bpmndi:BPMNLabel>
- <dc:Bounds x="955" y="159" width="18" height="12" />
+ <dc:Bounds x="1093" y="159" width="18" height="12" />
</bpmndi:BPMNLabel>
</bpmndi:BPMNShape>
<bpmndi:BPMNEdge id="SequenceFlow_0zaz9o2_di" bpmnElement="SequenceFlow_0zaz9o2">
@@ -53,22 +62,15 @@
<dc:Bounds x="295" y="122" width="90" height="0" />
</bpmndi:BPMNLabel>
</bpmndi:BPMNEdge>
- <bpmndi:BPMNEdge id="SequenceFlow_1ks8kmt_di" bpmnElement="SequenceFlow_1ks8kmt">
- <di:waypoint xsi:type="dc:Point" x="765" y="137" />
- <di:waypoint xsi:type="dc:Point" x="804" y="137" />
- <bpmndi:BPMNLabel>
- <dc:Bounds x="785" y="122" width="0" height="0" />
- </bpmndi:BPMNLabel>
- </bpmndi:BPMNEdge>
<bpmndi:BPMNEdge id="SequenceFlow_0csh9dc_di" bpmnElement="SequenceFlow_0csh9dc">
- <di:waypoint xsi:type="dc:Point" x="904" y="137" />
- <di:waypoint xsi:type="dc:Point" x="946" y="137" />
+ <di:waypoint xsi:type="dc:Point" x="1054" y="137" />
+ <di:waypoint xsi:type="dc:Point" x="1084" y="137" />
<bpmndi:BPMNLabel>
- <dc:Bounds x="925" y="122" width="0" height="0" />
+ <dc:Bounds x="1024" y="122" width="90" height="0" />
</bpmndi:BPMNLabel>
</bpmndi:BPMNEdge>
<bpmndi:BPMNShape id="ServiceTask_0s6d1be_di" bpmnElement="Task_DeleteNetwork">
- <dc:Bounds x="804" y="97" width="100" height="80" />
+ <dc:Bounds x="954" y="97" width="100" height="80" />
</bpmndi:BPMNShape>
<bpmndi:BPMNShape id="ServiceTask_194x6el_di" bpmnElement="Task_VfModuleRelatioship">
<dc:Bounds x="375" y="97" width="100" height="80" />
@@ -90,6 +92,25 @@
<bpmndi:BPMNShape id="ServiceTask_1ev9w69_di" bpmnElement="Task_GetCloudRegionVersion">
<dc:Bounds x="524" y="97" width="100" height="80" />
</bpmndi:BPMNShape>
+ <bpmndi:BPMNShape id="CallActivity_172bbje_di" bpmnElement="CallActivity_sdncHandlerCall">
+ <dc:Bounds x="813" y="97" width="100" height="80" />
+ </bpmndi:BPMNShape>
+ <bpmndi:BPMNEdge id="SequenceFlow_1woj6rc_di" bpmnElement="SequenceFlow_1woj6rc">
+ <di:waypoint xsi:type="dc:Point" x="765" y="137" />
+ <di:waypoint xsi:type="dc:Point" x="787" y="137" />
+ <di:waypoint xsi:type="dc:Point" x="787" y="137" />
+ <di:waypoint xsi:type="dc:Point" x="813" y="137" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="802" y="131" width="0" height="12" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNEdge>
+ <bpmndi:BPMNEdge id="SequenceFlow_15oc7ot_di" bpmnElement="SequenceFlow_15oc7ot">
+ <di:waypoint xsi:type="dc:Point" x="913" y="137" />
+ <di:waypoint xsi:type="dc:Point" x="954" y="137" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="933.5" y="116" width="0" height="12" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNEdge>
</bpmndi:BPMNPlane>
</bpmndi:BPMNDiagram>
</bpmn:definitions>
diff --git a/bpmn/so-bpmn-building-blocks/src/main/resources/subprocess/BuildingBlock/UnassignServiceInstanceBB.bpmn b/bpmn/so-bpmn-building-blocks/src/main/resources/subprocess/BuildingBlock/UnassignServiceInstanceBB.bpmn
index f077c78348..08f17469da 100644
--- a/bpmn/so-bpmn-building-blocks/src/main/resources/subprocess/BuildingBlock/UnassignServiceInstanceBB.bpmn
+++ b/bpmn/so-bpmn-building-blocks/src/main/resources/subprocess/BuildingBlock/UnassignServiceInstanceBB.bpmn
@@ -1,23 +1,32 @@
<?xml version="1.0" encoding="UTF-8"?>
-<bpmn:definitions xmlns:bpmn="http://www.omg.org/spec/BPMN/20100524/MODEL" xmlns:bpmndi="http://www.omg.org/spec/BPMN/20100524/DI" xmlns:di="http://www.omg.org/spec/DD/20100524/DI" xmlns:dc="http://www.omg.org/spec/DD/20100524/DC" xmlns:camunda="http://camunda.org/schema/1.0/bpmn" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" id="Definitions_1" targetNamespace="http://bpmn.io/schema/bpmn" exporter="Camunda Modeler" exporterVersion="1.10.0">
+<bpmn:definitions xmlns:bpmn="http://www.omg.org/spec/BPMN/20100524/MODEL" xmlns:bpmndi="http://www.omg.org/spec/BPMN/20100524/DI" xmlns:di="http://www.omg.org/spec/DD/20100524/DI" xmlns:dc="http://www.omg.org/spec/DD/20100524/DC" xmlns:camunda="http://camunda.org/schema/1.0/bpmn" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" id="Definitions_1" targetNamespace="http://bpmn.io/schema/bpmn" exporter="Camunda Modeler" exporterVersion="1.8.2">
<bpmn:process id="UnassignServiceInstanceBB" name="UnassignServiceInstanceBB" isExecutable="true">
<bpmn:startEvent id="Start_UnassignServiceInstanceBB">
<bpmn:outgoing>SequenceFlow_0fzrhkc</bpmn:outgoing>
</bpmn:startEvent>
<bpmn:serviceTask id="Task_AAIDeleteServiceInstance" name="&#10;AAI&#10;Delete &#10;(svc instance)&#10;" camunda:expression="${AAIDeleteTasks.deleteServiceInstance(InjectExecution.execute(execution, execution.getVariable(&#34;gBuildingBlockExecution&#34;)))}">
- <bpmn:incoming>SequenceFlow_0pu9j6i</bpmn:incoming>
+ <bpmn:incoming>SequenceFlow_0uzdp0c</bpmn:incoming>
<bpmn:outgoing>SequenceFlow_0sfeg65</bpmn:outgoing>
</bpmn:serviceTask>
<bpmn:sequenceFlow id="SequenceFlow_0sfeg65" sourceRef="Task_AAIDeleteServiceInstance" targetRef="End_UnassignServiceInstanceBB" />
<bpmn:serviceTask id="Task_SdncUnassignServiceInstance" name="&#10;SDNC&#10;Unassign&#10;(svc instance)&#10;" camunda:expression="${SDNCUnassignTasks.unassignServiceInstance(InjectExecution.execute(execution, execution.getVariable(&#34;gBuildingBlockExecution&#34;)))}">
<bpmn:incoming>SequenceFlow_0fzrhkc</bpmn:incoming>
- <bpmn:outgoing>SequenceFlow_0pu9j6i</bpmn:outgoing>
+ <bpmn:outgoing>SequenceFlow_00dyi16</bpmn:outgoing>
</bpmn:serviceTask>
- <bpmn:sequenceFlow id="SequenceFlow_0pu9j6i" sourceRef="Task_SdncUnassignServiceInstance" targetRef="Task_AAIDeleteServiceInstance" />
<bpmn:endEvent id="End_UnassignServiceInstanceBB">
<bpmn:incoming>SequenceFlow_0sfeg65</bpmn:incoming>
</bpmn:endEvent>
<bpmn:sequenceFlow id="SequenceFlow_0fzrhkc" sourceRef="Start_UnassignServiceInstanceBB" targetRef="Task_SdncUnassignServiceInstance" />
+ <bpmn:callActivity id="CallActivity_sdncHandlerCall" name="SDNC Unassign (svc instance)" calledElement="SDNCHandler">
+ <bpmn:extensionElements>
+ <camunda:in source="SDNCRequest" target="SDNCRequest" />
+ <camunda:out source="SDNCResponse" target="SDNCResponse" />
+ </bpmn:extensionElements>
+ <bpmn:incoming>SequenceFlow_00dyi16</bpmn:incoming>
+ <bpmn:outgoing>SequenceFlow_0uzdp0c</bpmn:outgoing>
+ </bpmn:callActivity>
+ <bpmn:sequenceFlow id="SequenceFlow_00dyi16" sourceRef="Task_SdncUnassignServiceInstance" targetRef="CallActivity_sdncHandlerCall" />
+ <bpmn:sequenceFlow id="SequenceFlow_0uzdp0c" sourceRef="CallActivity_sdncHandlerCall" targetRef="Task_AAIDeleteServiceInstance" />
</bpmn:process>
<bpmn:error id="Error_041z84w" name="gDelegateError" errorCode="7000" />
<bpmn:error id="Error_027m7l6" name="Failed orchestration status verification" errorCode="7000" />
@@ -30,36 +39,46 @@
</bpmndi:BPMNLabel>
</bpmndi:BPMNShape>
<bpmndi:BPMNShape id="ServiceTask_0ltb3dj_di" bpmnElement="Task_AAIDeleteServiceInstance">
- <dc:Bounds x="708" y="191" width="100" height="80" />
+ <dc:Bounds x="819" y="191" width="100" height="80" />
</bpmndi:BPMNShape>
<bpmndi:BPMNEdge id="SequenceFlow_0sfeg65_di" bpmnElement="SequenceFlow_0sfeg65">
- <di:waypoint xsi:type="dc:Point" x="808" y="231" />
- <di:waypoint xsi:type="dc:Point" x="871" y="231" />
+ <di:waypoint xsi:type="dc:Point" x="919" y="231" />
+ <di:waypoint xsi:type="dc:Point" x="961" y="231" />
<bpmndi:BPMNLabel>
- <dc:Bounds x="794.5" y="210" width="90" height="12" />
+ <dc:Bounds x="895" y="210" width="90" height="12" />
</bpmndi:BPMNLabel>
</bpmndi:BPMNEdge>
<bpmndi:BPMNShape id="ServiceTask_11klnmn_di" bpmnElement="Task_SdncUnassignServiceInstance">
- <dc:Bounds x="563" y="191" width="100" height="80" />
+ <dc:Bounds x="510" y="191" width="100" height="80" />
</bpmndi:BPMNShape>
- <bpmndi:BPMNEdge id="SequenceFlow_0pu9j6i_di" bpmnElement="SequenceFlow_0pu9j6i">
- <di:waypoint xsi:type="dc:Point" x="663" y="231" />
- <di:waypoint xsi:type="dc:Point" x="708" y="231" />
- <bpmndi:BPMNLabel>
- <dc:Bounds x="640.5" y="210" width="90" height="12" />
- </bpmndi:BPMNLabel>
- </bpmndi:BPMNEdge>
<bpmndi:BPMNShape id="EndEvent_1p34ka9_di" bpmnElement="End_UnassignServiceInstanceBB">
- <dc:Bounds x="871" y="213" width="36" height="36" />
+ <dc:Bounds x="961" y="213" width="36" height="36" />
<bpmndi:BPMNLabel>
- <dc:Bounds x="883" y="255" width="18" height="12" />
+ <dc:Bounds x="937" y="255" width="90" height="12" />
</bpmndi:BPMNLabel>
</bpmndi:BPMNShape>
<bpmndi:BPMNEdge id="SequenceFlow_0fzrhkc_di" bpmnElement="SequenceFlow_0fzrhkc">
<di:waypoint xsi:type="dc:Point" x="480" y="231" />
- <di:waypoint xsi:type="dc:Point" x="563" y="231" />
+ <di:waypoint xsi:type="dc:Point" x="510" y="231" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="450" y="210" width="90" height="12" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNEdge>
+ <bpmndi:BPMNShape id="CallActivity_0q2i7pr_di" bpmnElement="CallActivity_sdncHandlerCall">
+ <dc:Bounds x="668" y="191" width="100" height="80" />
+ </bpmndi:BPMNShape>
+ <bpmndi:BPMNEdge id="SequenceFlow_00dyi16_di" bpmnElement="SequenceFlow_00dyi16">
+ <di:waypoint xsi:type="dc:Point" x="610" y="231" />
+ <di:waypoint xsi:type="dc:Point" x="668" y="231" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="639" y="210" width="0" height="12" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNEdge>
+ <bpmndi:BPMNEdge id="SequenceFlow_0uzdp0c_di" bpmnElement="SequenceFlow_0uzdp0c">
+ <di:waypoint xsi:type="dc:Point" x="768" y="231" />
+ <di:waypoint xsi:type="dc:Point" x="819" y="231" />
<bpmndi:BPMNLabel>
- <dc:Bounds x="476.5" y="210" width="90" height="12" />
+ <dc:Bounds x="793.5" y="210" width="0" height="12" />
</bpmndi:BPMNLabel>
</bpmndi:BPMNEdge>
</bpmndi:BPMNPlane>
diff --git a/bpmn/so-bpmn-building-blocks/src/main/resources/subprocess/BuildingBlock/UnassignVfModuleBB.bpmn b/bpmn/so-bpmn-building-blocks/src/main/resources/subprocess/BuildingBlock/UnassignVfModuleBB.bpmn
index 0f3138121e..dd00078fb5 100644
--- a/bpmn/so-bpmn-building-blocks/src/main/resources/subprocess/BuildingBlock/UnassignVfModuleBB.bpmn
+++ b/bpmn/so-bpmn-building-blocks/src/main/resources/subprocess/BuildingBlock/UnassignVfModuleBB.bpmn
@@ -1,23 +1,32 @@
<?xml version="1.0" encoding="UTF-8"?>
-<bpmn:definitions xmlns:bpmn="http://www.omg.org/spec/BPMN/20100524/MODEL" xmlns:bpmndi="http://www.omg.org/spec/BPMN/20100524/DI" xmlns:di="http://www.omg.org/spec/DD/20100524/DI" xmlns:dc="http://www.omg.org/spec/DD/20100524/DC" xmlns:camunda="http://camunda.org/schema/1.0/bpmn" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" id="Definitions_1" targetNamespace="http://bpmn.io/schema/bpmn" exporter="Camunda Modeler" exporterVersion="1.10.0">
+<bpmn:definitions xmlns:bpmn="http://www.omg.org/spec/BPMN/20100524/MODEL" xmlns:bpmndi="http://www.omg.org/spec/BPMN/20100524/DI" xmlns:di="http://www.omg.org/spec/DD/20100524/DI" xmlns:dc="http://www.omg.org/spec/DD/20100524/DC" xmlns:camunda="http://camunda.org/schema/1.0/bpmn" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" id="Definitions_1" targetNamespace="http://bpmn.io/schema/bpmn" exporter="Camunda Modeler" exporterVersion="1.8.2">
<bpmn:process id="UnassignVfModuleBB" name="UnassignVfModuleBB" isExecutable="true">
<bpmn:startEvent id="UnassignVfModuleBB_Start">
<bpmn:outgoing>SequenceFlow_1kfxl04</bpmn:outgoing>
</bpmn:startEvent>
<bpmn:serviceTask id="DeleteVfModule" name="&#10;AAI &#10;Delete&#10;(vf module)&#10;" camunda:expression="${AAIDeleteTasks.deleteVfModule(InjectExecution.execute(execution, execution.getVariable(&#34;gBuildingBlockExecution&#34;)))}">
- <bpmn:incoming>SequenceFlow_1p2r4og</bpmn:incoming>
+ <bpmn:incoming>SequenceFlow_0py9tf7</bpmn:incoming>
<bpmn:outgoing>SequenceFlow_0qa6sxx</bpmn:outgoing>
</bpmn:serviceTask>
<bpmn:serviceTask id="UnassignVfModule" name="&#10;SDNC Unassign&#10;(vf module)&#10;" camunda:expression="${SDNCUnassignTasks.unassignVfModule(InjectExecution.execute(execution, execution.getVariable(&#34;gBuildingBlockExecution&#34;)))}">
<bpmn:incoming>SequenceFlow_1kfxl04</bpmn:incoming>
- <bpmn:outgoing>SequenceFlow_1p2r4og</bpmn:outgoing>
+ <bpmn:outgoing>SequenceFlow_152ntu2</bpmn:outgoing>
</bpmn:serviceTask>
<bpmn:endEvent id="UnassignVfModuleBB_End">
<bpmn:incoming>SequenceFlow_0qa6sxx</bpmn:incoming>
</bpmn:endEvent>
<bpmn:sequenceFlow id="SequenceFlow_1kfxl04" sourceRef="UnassignVfModuleBB_Start" targetRef="UnassignVfModule" />
- <bpmn:sequenceFlow id="SequenceFlow_1p2r4og" sourceRef="UnassignVfModule" targetRef="DeleteVfModule" />
<bpmn:sequenceFlow id="SequenceFlow_0qa6sxx" sourceRef="DeleteVfModule" targetRef="UnassignVfModuleBB_End" />
+ <bpmn:callActivity id="CallActivity_sdncHandler" name="SDNC Unassign (vf module)" calledElement="SDNCHandler">
+ <bpmn:extensionElements>
+ <camunda:in source="SDNCRequest" target="SDNCRequest" />
+ <camunda:out source="SDNCResponse" target="SDNCResponse" />
+ </bpmn:extensionElements>
+ <bpmn:incoming>SequenceFlow_152ntu2</bpmn:incoming>
+ <bpmn:outgoing>SequenceFlow_0py9tf7</bpmn:outgoing>
+ </bpmn:callActivity>
+ <bpmn:sequenceFlow id="SequenceFlow_152ntu2" sourceRef="UnassignVfModule" targetRef="CallActivity_sdncHandler" />
+ <bpmn:sequenceFlow id="SequenceFlow_0py9tf7" sourceRef="CallActivity_sdncHandler" targetRef="DeleteVfModule" />
</bpmn:process>
<bpmndi:BPMNDiagram id="BPMNDiagram_1">
<bpmndi:BPMNPlane id="BPMNPlane_1" bpmnElement="UnassignVfModuleBB">
@@ -28,10 +37,10 @@
</bpmndi:BPMNLabel>
</bpmndi:BPMNShape>
<bpmndi:BPMNShape id="ServiceTask_0028k7a_di" bpmnElement="DeleteVfModule">
- <dc:Bounds x="537" y="-25" width="100" height="80" />
+ <dc:Bounds x="614" y="-25" width="100" height="80" />
</bpmndi:BPMNShape>
<bpmndi:BPMNShape id="ServiceTask_13t22km_di" bpmnElement="UnassignVfModule">
- <dc:Bounds x="387" y="-25" width="100" height="80" />
+ <dc:Bounds x="298" y="-25" width="100" height="80" />
</bpmndi:BPMNShape>
<bpmndi:BPMNShape id="EndEvent_0qdq7wj_di" bpmnElement="UnassignVfModuleBB_End">
<dc:Bounds x="782" y="-3" width="36" height="36" />
@@ -41,23 +50,33 @@
</bpmndi:BPMNShape>
<bpmndi:BPMNEdge id="SequenceFlow_1kfxl04_di" bpmnElement="SequenceFlow_1kfxl04">
<di:waypoint xsi:type="dc:Point" x="249" y="15" />
- <di:waypoint xsi:type="dc:Point" x="387" y="15" />
+ <di:waypoint xsi:type="dc:Point" x="298" y="15" />
<bpmndi:BPMNLabel>
- <dc:Bounds x="273" y="0" width="90" height="0" />
+ <dc:Bounds x="228.5" y="0" width="90" height="0" />
</bpmndi:BPMNLabel>
</bpmndi:BPMNEdge>
- <bpmndi:BPMNEdge id="SequenceFlow_1p2r4og_di" bpmnElement="SequenceFlow_1p2r4og">
- <di:waypoint xsi:type="dc:Point" x="487" y="15" />
- <di:waypoint xsi:type="dc:Point" x="537" y="15" />
+ <bpmndi:BPMNEdge id="SequenceFlow_0qa6sxx_di" bpmnElement="SequenceFlow_0qa6sxx">
+ <di:waypoint xsi:type="dc:Point" x="714" y="15" />
+ <di:waypoint xsi:type="dc:Point" x="782" y="15" />
<bpmndi:BPMNLabel>
- <dc:Bounds x="467" y="0" width="90" height="0" />
+ <dc:Bounds x="703" y="0" width="90" height="0" />
</bpmndi:BPMNLabel>
</bpmndi:BPMNEdge>
- <bpmndi:BPMNEdge id="SequenceFlow_0qa6sxx_di" bpmnElement="SequenceFlow_0qa6sxx">
- <di:waypoint xsi:type="dc:Point" x="637" y="15" />
- <di:waypoint xsi:type="dc:Point" x="782" y="15" />
+ <bpmndi:BPMNShape id="CallActivity_1x5hvzz_di" bpmnElement="CallActivity_sdncHandler">
+ <dc:Bounds x="449" y="-25" width="100" height="80" />
+ </bpmndi:BPMNShape>
+ <bpmndi:BPMNEdge id="SequenceFlow_152ntu2_di" bpmnElement="SequenceFlow_152ntu2">
+ <di:waypoint xsi:type="dc:Point" x="398" y="15" />
+ <di:waypoint xsi:type="dc:Point" x="449" y="15" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="423.5" y="-6" width="0" height="12" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNEdge>
+ <bpmndi:BPMNEdge id="SequenceFlow_0py9tf7_di" bpmnElement="SequenceFlow_0py9tf7">
+ <di:waypoint xsi:type="dc:Point" x="549" y="15" />
+ <di:waypoint xsi:type="dc:Point" x="614" y="15" />
<bpmndi:BPMNLabel>
- <dc:Bounds x="664.5" y="0" width="90" height="0" />
+ <dc:Bounds x="581.5" y="-6" width="0" height="12" />
</bpmndi:BPMNLabel>
</bpmndi:BPMNEdge>
</bpmndi:BPMNPlane>
diff --git a/bpmn/so-bpmn-building-blocks/src/main/resources/subprocess/BuildingBlock/UnassignVnfBB.bpmn b/bpmn/so-bpmn-building-blocks/src/main/resources/subprocess/BuildingBlock/UnassignVnfBB.bpmn
index 4676acfa42..dec5681c9d 100644
--- a/bpmn/so-bpmn-building-blocks/src/main/resources/subprocess/BuildingBlock/UnassignVnfBB.bpmn
+++ b/bpmn/so-bpmn-building-blocks/src/main/resources/subprocess/BuildingBlock/UnassignVnfBB.bpmn
@@ -1,5 +1,5 @@
<?xml version="1.0" encoding="UTF-8"?>
-<bpmn:definitions xmlns:bpmn="http://www.omg.org/spec/BPMN/20100524/MODEL" xmlns:bpmndi="http://www.omg.org/spec/BPMN/20100524/DI" xmlns:di="http://www.omg.org/spec/DD/20100524/DI" xmlns:dc="http://www.omg.org/spec/DD/20100524/DC" xmlns:camunda="http://camunda.org/schema/1.0/bpmn" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" id="Definitions_1" targetNamespace="http://bpmn.io/schema/bpmn" exporter="Camunda Modeler" exporterVersion="1.10.0">
+<bpmn:definitions xmlns:bpmn="http://www.omg.org/spec/BPMN/20100524/MODEL" xmlns:bpmndi="http://www.omg.org/spec/BPMN/20100524/DI" xmlns:di="http://www.omg.org/spec/DD/20100524/DI" xmlns:dc="http://www.omg.org/spec/DD/20100524/DC" xmlns:camunda="http://camunda.org/schema/1.0/bpmn" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" id="Definitions_1" targetNamespace="http://bpmn.io/schema/bpmn" exporter="Camunda Modeler" exporterVersion="1.8.2">
<bpmn:process id="UnassignVnfBB" name="UnassignVnfBB" isExecutable="true">
<bpmn:startEvent id="UnassignVnfBB_Start">
<bpmn:outgoing>SequenceFlow_1kfxl04</bpmn:outgoing>
@@ -10,7 +10,7 @@
</bpmn:serviceTask>
<bpmn:serviceTask id="UnassignVnf" name="&#10;SDNC &#10;Unassign&#10;(vnf)&#10;" camunda:expression="${SDNCUnassignTasks.unassignVnf(InjectExecution.execute(execution, execution.getVariable(&#34;gBuildingBlockExecution&#34;)))}">
<bpmn:incoming>SequenceFlow_1kfxl04</bpmn:incoming>
- <bpmn:outgoing>SequenceFlow_02st1i1</bpmn:outgoing>
+ <bpmn:outgoing>SequenceFlow_0ielrmh</bpmn:outgoing>
</bpmn:serviceTask>
<bpmn:endEvent id="UnassignVnfBB_End">
<bpmn:incoming>SequenceFlow_0qa6sxx</bpmn:incoming>
@@ -18,11 +18,20 @@
<bpmn:sequenceFlow id="SequenceFlow_1kfxl04" sourceRef="UnassignVnfBB_Start" targetRef="UnassignVnf" />
<bpmn:sequenceFlow id="SequenceFlow_0qa6sxx" sourceRef="DeleteVnf" targetRef="UnassignVnfBB_End" />
<bpmn:serviceTask id="DeleteVnfInstanceGroups" name="&#10;AAI &#10;Delete&#10;(instance grp)&#10;" camunda:expression="${UnassignVnf.deleteInstanceGroups(InjectExecution.execute(execution, execution.getVariable(&#34;gBuildingBlockExecution&#34;)))}">
- <bpmn:incoming>SequenceFlow_02st1i1</bpmn:incoming>
+ <bpmn:incoming>SequenceFlow_1cpzq86</bpmn:incoming>
<bpmn:outgoing>SequenceFlow_0w3s09a</bpmn:outgoing>
</bpmn:serviceTask>
- <bpmn:sequenceFlow id="SequenceFlow_02st1i1" sourceRef="UnassignVnf" targetRef="DeleteVnfInstanceGroups" />
<bpmn:sequenceFlow id="SequenceFlow_0w3s09a" sourceRef="DeleteVnfInstanceGroups" targetRef="DeleteVnf" />
+ <bpmn:callActivity id="CallActivity_sdncHandlerCall" name="SDNC Unassign (vnf)" calledElement="SDNCHandler">
+ <bpmn:extensionElements>
+ <camunda:in source="SDNCRequest" target="SDNCRequest" />
+ <camunda:out source="SDNCResponse" target="SDNCResponse" />
+ </bpmn:extensionElements>
+ <bpmn:incoming>SequenceFlow_0ielrmh</bpmn:incoming>
+ <bpmn:outgoing>SequenceFlow_1cpzq86</bpmn:outgoing>
+ </bpmn:callActivity>
+ <bpmn:sequenceFlow id="SequenceFlow_0ielrmh" sourceRef="UnassignVnf" targetRef="CallActivity_sdncHandlerCall" />
+ <bpmn:sequenceFlow id="SequenceFlow_1cpzq86" sourceRef="CallActivity_sdncHandlerCall" targetRef="DeleteVnfInstanceGroups" />
</bpmn:process>
<bpmndi:BPMNDiagram id="BPMNDiagram_1">
<bpmndi:BPMNPlane id="BPMNPlane_1" bpmnElement="UnassignVnfBB">
@@ -33,10 +42,10 @@
</bpmndi:BPMNLabel>
</bpmndi:BPMNShape>
<bpmndi:BPMNShape id="ServiceTask_0028k7a_di" bpmnElement="DeleteVnf">
- <dc:Bounds x="723" y="-25" width="100" height="80" />
+ <dc:Bounds x="822" y="-25" width="100" height="80" />
</bpmndi:BPMNShape>
<bpmndi:BPMNShape id="ServiceTask_13t22km_di" bpmnElement="UnassignVnf">
- <dc:Bounds x="367" y="-25" width="100" height="80" />
+ <dc:Bounds x="309" y="-25" width="100" height="80" />
</bpmndi:BPMNShape>
<bpmndi:BPMNShape id="EndEvent_0qdq7wj_di" bpmnElement="UnassignVnfBB_End">
<dc:Bounds x="959" y="-3" width="36" height="36" />
@@ -46,33 +55,43 @@
</bpmndi:BPMNShape>
<bpmndi:BPMNEdge id="SequenceFlow_1kfxl04_di" bpmnElement="SequenceFlow_1kfxl04">
<di:waypoint xsi:type="dc:Point" x="249" y="15" />
- <di:waypoint xsi:type="dc:Point" x="367" y="15" />
+ <di:waypoint xsi:type="dc:Point" x="309" y="15" />
<bpmndi:BPMNLabel>
- <dc:Bounds x="308" y="0" width="0" height="0" />
+ <dc:Bounds x="234" y="0" width="90" height="0" />
</bpmndi:BPMNLabel>
</bpmndi:BPMNEdge>
<bpmndi:BPMNEdge id="SequenceFlow_0qa6sxx_di" bpmnElement="SequenceFlow_0qa6sxx">
- <di:waypoint xsi:type="dc:Point" x="823" y="15" />
+ <di:waypoint xsi:type="dc:Point" x="922" y="15" />
<di:waypoint xsi:type="dc:Point" x="959" y="15" />
<bpmndi:BPMNLabel>
- <dc:Bounds x="846" y="0" width="90" height="0" />
+ <dc:Bounds x="895.5" y="0" width="90" height="0" />
</bpmndi:BPMNLabel>
</bpmndi:BPMNEdge>
<bpmndi:BPMNShape id="ServiceTask_0b1276e_di" bpmnElement="DeleteVnfInstanceGroups">
- <dc:Bounds x="546" y="-25" width="100" height="80" />
+ <dc:Bounds x="650" y="-25" width="100" height="80" />
</bpmndi:BPMNShape>
- <bpmndi:BPMNEdge id="SequenceFlow_02st1i1_di" bpmnElement="SequenceFlow_02st1i1">
- <di:waypoint xsi:type="dc:Point" x="467" y="15" />
- <di:waypoint xsi:type="dc:Point" x="546" y="15" />
+ <bpmndi:BPMNEdge id="SequenceFlow_0w3s09a_di" bpmnElement="SequenceFlow_0w3s09a">
+ <di:waypoint xsi:type="dc:Point" x="750" y="15" />
+ <di:waypoint xsi:type="dc:Point" x="822" y="15" />
<bpmndi:BPMNLabel>
- <dc:Bounds x="506.5" y="-6" width="0" height="12" />
+ <dc:Bounds x="741" y="-6" width="90" height="12" />
</bpmndi:BPMNLabel>
</bpmndi:BPMNEdge>
- <bpmndi:BPMNEdge id="SequenceFlow_0w3s09a_di" bpmnElement="SequenceFlow_0w3s09a">
- <di:waypoint xsi:type="dc:Point" x="646" y="15" />
- <di:waypoint xsi:type="dc:Point" x="723" y="15" />
+ <bpmndi:BPMNShape id="CallActivity_195fzng_di" bpmnElement="CallActivity_sdncHandlerCall">
+ <dc:Bounds x="471" y="-25" width="100" height="80" />
+ </bpmndi:BPMNShape>
+ <bpmndi:BPMNEdge id="SequenceFlow_0ielrmh_di" bpmnElement="SequenceFlow_0ielrmh">
+ <di:waypoint xsi:type="dc:Point" x="409" y="15" />
+ <di:waypoint xsi:type="dc:Point" x="471" y="15" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="440" y="-6" width="0" height="12" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNEdge>
+ <bpmndi:BPMNEdge id="SequenceFlow_1cpzq86_di" bpmnElement="SequenceFlow_1cpzq86">
+ <di:waypoint xsi:type="dc:Point" x="571" y="15" />
+ <di:waypoint xsi:type="dc:Point" x="650" y="15" />
<bpmndi:BPMNLabel>
- <dc:Bounds x="684.5" y="-6" width="0" height="12" />
+ <dc:Bounds x="610.5" y="-6" width="0" height="12" />
</bpmndi:BPMNLabel>
</bpmndi:BPMNEdge>
</bpmndi:BPMNPlane>
diff --git a/bpmn/so-bpmn-building-blocks/src/test/java/org/onap/so/bpmn/infrastructure/bpmn/subprocess/ActivateNetworkBBTest.java b/bpmn/so-bpmn-building-blocks/src/test/java/org/onap/so/bpmn/infrastructure/bpmn/subprocess/ActivateNetworkBBTest.java
index be49e3c681..dcf679610e 100644
--- a/bpmn/so-bpmn-building-blocks/src/test/java/org/onap/so/bpmn/infrastructure/bpmn/subprocess/ActivateNetworkBBTest.java
+++ b/bpmn/so-bpmn-building-blocks/src/test/java/org/onap/so/bpmn/infrastructure/bpmn/subprocess/ActivateNetworkBBTest.java
@@ -33,14 +33,16 @@ import org.onap.so.bpmn.common.BuildingBlockExecution;
public class ActivateNetworkBBTest extends BaseBPMNTest{
@Test
public void sunnyDayActivateNetwork_Test() throws InterruptedException {
+ mockSubprocess("SDNCHandler", "My Mock Process Name", "GenericStub");
ProcessInstance pi = runtimeService.startProcessInstanceByKey("ActivateNetworkBB", variables);
assertThat(pi).isNotNull();
- assertThat(pi).isStarted().hasPassedInOrder("activateNetwork_startEvent","Activate_Network_SDNC_ServiceTask","Activate_Network_AAI_ServiceTask","activateNetwork_EndEvent");
+ assertThat(pi).isStarted().hasPassedInOrder("activateNetwork_startEvent","Activate_Network_SDNC_ServiceTask","CallActivity_sdncHandler","Activate_Network_AAI_ServiceTask","activateNetwork_EndEvent");
assertThat(pi).isEnded();
}
@Test
public void rainyDayActivateNetwork_Test() throws Exception {
+ mockSubprocess("SDNCHandler", "My Mock Process Name", "GenericStub");
doThrow(new BpmnError("7000", "TESTING ERRORS")).when(aaiUpdateTasks).updateOrchestrationStatusActiveNetwork(any(BuildingBlockExecution.class));
ProcessInstance pi = runtimeService.startProcessInstanceByKey("ActivateNetworkBB", variables);
assertThat(pi).isStarted()
diff --git a/bpmn/so-bpmn-building-blocks/src/test/java/org/onap/so/bpmn/infrastructure/bpmn/subprocess/ActivateVfModuleBBTest.java b/bpmn/so-bpmn-building-blocks/src/test/java/org/onap/so/bpmn/infrastructure/bpmn/subprocess/ActivateVfModuleBBTest.java
index 14ff2fce9a..2c2777154d 100644
--- a/bpmn/so-bpmn-building-blocks/src/test/java/org/onap/so/bpmn/infrastructure/bpmn/subprocess/ActivateVfModuleBBTest.java
+++ b/bpmn/so-bpmn-building-blocks/src/test/java/org/onap/so/bpmn/infrastructure/bpmn/subprocess/ActivateVfModuleBBTest.java
@@ -19,7 +19,7 @@
*/
package org.onap.so.bpmn.infrastructure.bpmn.subprocess;
-import static org.camunda.bpm.engine.test.assertions.ProcessEngineTests.assertThat;
+import static org.camunda.bpm.engine.test.assertions.bpmn.BpmnAwareAssertions.assertThat;
import static org.mockito.ArgumentMatchers.any;
import static org.mockito.Mockito.doThrow;
@@ -27,7 +27,6 @@ import java.io.IOException;
import org.camunda.bpm.engine.delegate.BpmnError;
import org.camunda.bpm.engine.runtime.ProcessInstance;
-import org.junit.Ignore;
import org.junit.Test;
import org.onap.so.bpmn.BaseBPMNTest;
import org.onap.so.bpmn.common.BuildingBlockExecution;
@@ -35,22 +34,21 @@ import org.onap.so.bpmn.common.BuildingBlockExecution;
public class ActivateVfModuleBBTest extends BaseBPMNTest{
@Test
public void sunnyDay() throws InterruptedException, IOException {
+ mockSubprocess("SDNCHandler", "My Mock Process Name", "GenericStub");
ProcessInstance pi = runtimeService.startProcessInstanceByKey("ActivateVfModuleBB", variables);
assertThat(pi).isNotNull();
- assertThat(pi).isStarted().hasPassedInOrder("ActivateVfModuleBB_Start", "ActivateVfModule",
+ assertThat(pi).isStarted().hasPassedInOrder("ActivateVfModuleBB_Start", "ActivateVfModule", "CallActivity_sdncHandler",
"UpdateVfModuleActiveStatus", "ActivateVfModuleBB_End");
assertThat(pi).isEnded();
}
@Test
-
public void rainyDay() throws Exception {
+ mockSubprocess("SDNCHandler", "My Mock Process Name", "GenericStub");
doThrow(BpmnError.class).when(aaiUpdateTasks).updateOrchestrationStatusActivateVfModule(any(BuildingBlockExecution.class));
ProcessInstance pi = runtimeService.startProcessInstanceByKey("ActivateVfModuleBB", variables);
assertThat(pi).isNotNull().isStarted()
.hasPassedInOrder("ActivateVfModuleBB_Start", "ActivateVfModule", "UpdateVfModuleActiveStatus")
.hasNotPassed("ActivateVfModuleBB_End");
-
-
}
}
diff --git a/bpmn/so-bpmn-building-blocks/src/test/java/org/onap/so/bpmn/infrastructure/bpmn/subprocess/ActivateVnfBBTest.java b/bpmn/so-bpmn-building-blocks/src/test/java/org/onap/so/bpmn/infrastructure/bpmn/subprocess/ActivateVnfBBTest.java
index 7a8838e9fd..d1d95fee71 100644
--- a/bpmn/so-bpmn-building-blocks/src/test/java/org/onap/so/bpmn/infrastructure/bpmn/subprocess/ActivateVnfBBTest.java
+++ b/bpmn/so-bpmn-building-blocks/src/test/java/org/onap/so/bpmn/infrastructure/bpmn/subprocess/ActivateVnfBBTest.java
@@ -30,10 +30,11 @@ import org.onap.so.bpmn.BaseBPMNTest;
public class ActivateVnfBBTest extends BaseBPMNTest{
@Test
public void sunnyDay() throws InterruptedException, IOException {
+ mockSubprocess("SDNCHandler", "My Mock Process Name", "GenericStub");
ProcessInstance pi = runtimeService.startProcessInstanceByKey("ActivateVnfBB", variables);
assertThat(pi).isNotNull();
assertThat(pi).isStarted().hasPassedInOrder("Start_ActivateVnfBB", "Task_SDNCAdapterVnfTopologyActivate",
- "Task_ActivateOrchestrationStatusVnf", "End_ActivateVnfBB");
+ "CallActivity_sdncHandler", "Task_ActivateOrchestrationStatusVnf", "End_ActivateVnfBB");
assertThat(pi).isEnded();
}
diff --git a/bpmn/so-bpmn-building-blocks/src/test/java/org/onap/so/bpmn/infrastructure/bpmn/subprocess/AssignNetworkBBTest.java b/bpmn/so-bpmn-building-blocks/src/test/java/org/onap/so/bpmn/infrastructure/bpmn/subprocess/AssignNetworkBBTest.java
index ee76eefd2c..c581a16349 100644
--- a/bpmn/so-bpmn-building-blocks/src/test/java/org/onap/so/bpmn/infrastructure/bpmn/subprocess/AssignNetworkBBTest.java
+++ b/bpmn/so-bpmn-building-blocks/src/test/java/org/onap/so/bpmn/infrastructure/bpmn/subprocess/AssignNetworkBBTest.java
@@ -34,16 +34,16 @@ public class AssignNetworkBBTest extends BaseBPMNTest{
@Test
@Deployment(resources = { "subprocess/AssignNetworkRollbackBB.bpmn"})
public void sunnyDayAssignNetwork_Test() throws InterruptedException {
-
+ mockSubprocess("SDNCHandler", "My Mock Process Name", "GenericStub");
ProcessInstance pi = runtimeService.startProcessInstanceByKey("AssignNetworkBB",variables);
assertThat(pi).isNotNull();
- assertThat(pi).isStarted().hasPassedInOrder("AssignNetworkBB_start","networkFoundByName_ExclusiveGateway","ServiceTask_put_network_in_AAI","ServiceTask_connect_to_Tenant","ServiceTask_connect_to_CloudRegion","ServiceTask_connect_to_NCIG","ServiceTask_connect_to_NCSI","ServiceTask_get_cloud_region","ServiceTask_assign_network_sdnc","ServiceTask_assign_network_aai","AssignNetworkBB_end");
+ assertThat(pi).isStarted().hasPassedInOrder("AssignNetworkBB_start","networkFoundByName_ExclusiveGateway","ServiceTask_put_network_in_AAI","ServiceTask_connect_to_Tenant","ServiceTask_connect_to_CloudRegion","ServiceTask_connect_to_NCIG","ServiceTask_connect_to_NCSI","ServiceTask_get_cloud_region","ServiceTask_assign_network_sdnc","CallActivity_sdncHandlerCall","ServiceTask_assign_network_aai","AssignNetworkBB_end");
assertThat(pi).isEnded();
}
@Test
public void rainyDayAssignNetwork_Test() throws Exception {
-
+ mockSubprocess("SDNCHandler", "My Mock Process Name", "GenericStub");
doThrow(new BpmnError("7000", "TESTING ERRORS")).when(aaiUpdateTasks).updateOrchestrationStatusAssignedNetwork(any(BuildingBlockExecution.class));
ProcessInstance pi = runtimeService.startProcessInstanceByKey("AssignNetworkBB", variables);
assertThat(pi).isNotNull();
diff --git a/bpmn/so-bpmn-building-blocks/src/test/java/org/onap/so/bpmn/infrastructure/bpmn/subprocess/AssignServiceInstanceBBTest.java b/bpmn/so-bpmn-building-blocks/src/test/java/org/onap/so/bpmn/infrastructure/bpmn/subprocess/AssignServiceInstanceBBTest.java
index 078f101347..2624cc0ccb 100644
--- a/bpmn/so-bpmn-building-blocks/src/test/java/org/onap/so/bpmn/infrastructure/bpmn/subprocess/AssignServiceInstanceBBTest.java
+++ b/bpmn/so-bpmn-building-blocks/src/test/java/org/onap/so/bpmn/infrastructure/bpmn/subprocess/AssignServiceInstanceBBTest.java
@@ -31,10 +31,11 @@ public class AssignServiceInstanceBBTest extends BaseBPMNTest{
@Test
public void sunnyDaySDNC() throws InterruptedException, IOException {
+ mockSubprocess("SDNCHandler", "My Mock Process Name", "GenericStub");
ProcessInstance pi = runtimeService.startProcessInstanceByKey("AssignServiceInstanceBB", variables);
assertThat(pi).isNotNull();
assertThat(pi).isStarted().hasPassedInOrder("Start_AssignServiceInstanceBB", "Task_CreateServiceInstance",
- "Task_CreateProject", "Task_CreateOwningEntity", "Task_AssignServiceInstance",
+ "Task_CreateProject", "Task_CreateOwningEntity", "Task_AssignServiceInstance", "CallActivity_sdncHandler",
"Task_UpdateServiceOstatusToAssigned", "End_AssignServiceInstanceBB");
assertThat(pi).isEnded();
}
diff --git a/bpmn/so-bpmn-building-blocks/src/test/java/org/onap/so/bpmn/infrastructure/bpmn/subprocess/AssignVfModuleBBTest.java b/bpmn/so-bpmn-building-blocks/src/test/java/org/onap/so/bpmn/infrastructure/bpmn/subprocess/AssignVfModuleBBTest.java
index 567d57cbc9..44d17a350c 100644
--- a/bpmn/so-bpmn-building-blocks/src/test/java/org/onap/so/bpmn/infrastructure/bpmn/subprocess/AssignVfModuleBBTest.java
+++ b/bpmn/so-bpmn-building-blocks/src/test/java/org/onap/so/bpmn/infrastructure/bpmn/subprocess/AssignVfModuleBBTest.java
@@ -32,12 +32,14 @@ import org.onap.so.bpmn.common.BuildingBlockExecution;
public class AssignVfModuleBBTest extends BaseBPMNTest{
@Test
public void sunnyDayAssignVfModule_Test() throws InterruptedException {
+ mockSubprocess("SDNCHandler", "My Mock Process Name", "GenericStub");
ProcessInstance pi = runtimeService.startProcessInstanceByKey("AssignVfModuleBB", variables);
assertThat(pi).isNotNull();
assertThat(pi).isStarted().hasPassedInOrder("AssignVfModuleBB_Start",
"CreateVfModule",
"ConnectVfModuleToVolumeGroup",
"AssignVfModule",
+ "CallActivity_sdncHandlerCall",
"UpdateVfModuleStatus",
"AssignVfModuleBB_End");
assertThat(pi).isEnded();
diff --git a/bpmn/so-bpmn-building-blocks/src/test/java/org/onap/so/bpmn/infrastructure/bpmn/subprocess/ChangeModelServiceInstanceBBTest.java b/bpmn/so-bpmn-building-blocks/src/test/java/org/onap/so/bpmn/infrastructure/bpmn/subprocess/ChangeModelServiceInstanceBBTest.java
index 2e0b813b36..1772a3af4b 100644
--- a/bpmn/so-bpmn-building-blocks/src/test/java/org/onap/so/bpmn/infrastructure/bpmn/subprocess/ChangeModelServiceInstanceBBTest.java
+++ b/bpmn/so-bpmn-building-blocks/src/test/java/org/onap/so/bpmn/infrastructure/bpmn/subprocess/ChangeModelServiceInstanceBBTest.java
@@ -32,9 +32,10 @@ import org.onap.so.bpmn.common.BuildingBlockExecution;
public class ChangeModelServiceInstanceBBTest extends BaseBPMNTest{
@Test
public void changeModelVnfBBTest() {
+ mockSubprocess("SDNCHandler", "My Mock Process Name", "GenericStub");
ProcessInstance processInstance = runtimeService.startProcessInstanceByKey("ChangeModelServiceInstanceBB", variables);
assertThat(processInstance).isNotNull();
- assertThat(processInstance).isStarted().hasPassedInOrder("ChangeModelServiceInstance_Start" ,"SDNCChangeModelServiceInstance", "AAIUpdateModelServiceInstance", "ChangeModelServiceInstance_End");
+ assertThat(processInstance).isStarted().hasPassedInOrder("ChangeModelServiceInstance_Start" ,"SDNCChangeModelServiceInstance", "CallActivity_sdncHandlerReq", "AAIUpdateModelServiceInstance", "ChangeModelServiceInstance_End");
assertThat(processInstance).isEnded();
}
diff --git a/bpmn/so-bpmn-building-blocks/src/test/java/org/onap/so/bpmn/infrastructure/bpmn/subprocess/ChangeModelVfModuleBBTest.java b/bpmn/so-bpmn-building-blocks/src/test/java/org/onap/so/bpmn/infrastructure/bpmn/subprocess/ChangeModelVfModuleBBTest.java
index fca6aae107..8549b6bc5a 100644
--- a/bpmn/so-bpmn-building-blocks/src/test/java/org/onap/so/bpmn/infrastructure/bpmn/subprocess/ChangeModelVfModuleBBTest.java
+++ b/bpmn/so-bpmn-building-blocks/src/test/java/org/onap/so/bpmn/infrastructure/bpmn/subprocess/ChangeModelVfModuleBBTest.java
@@ -32,9 +32,10 @@ import org.onap.so.bpmn.common.BuildingBlockExecution;
public class ChangeModelVfModuleBBTest extends BaseBPMNTest{
@Test
public void sunnyDayChangeModelVfModuleTest() throws InterruptedException {
+ mockSubprocess("SDNCHandler", "My Mock Process Name", "GenericStub");
ProcessInstance pi = runtimeService.startProcessInstanceByKey("ChangeModelVfModuleBB", variables);
assertThat(pi).isNotNull();
- assertThat(pi).isStarted().hasPassedInOrder("ChangeModelVfModuleBB_Start", "ChangeModelVfModule", "UpdateVfModuleModel", "ChangeModelVfModuleBB_End");
+ assertThat(pi).isStarted().hasPassedInOrder("ChangeModelVfModuleBB_Start", "ChangeModelVfModule", "CallActivity_sdncHandler", "UpdateVfModuleModel", "ChangeModelVfModuleBB_End");
assertThat(pi).isEnded();
}
diff --git a/bpmn/so-bpmn-building-blocks/src/test/java/org/onap/so/bpmn/infrastructure/bpmn/subprocess/ChangeModelVnfBBTest.java b/bpmn/so-bpmn-building-blocks/src/test/java/org/onap/so/bpmn/infrastructure/bpmn/subprocess/ChangeModelVnfBBTest.java
index 50dc25d081..43ac1630df 100644
--- a/bpmn/so-bpmn-building-blocks/src/test/java/org/onap/so/bpmn/infrastructure/bpmn/subprocess/ChangeModelVnfBBTest.java
+++ b/bpmn/so-bpmn-building-blocks/src/test/java/org/onap/so/bpmn/infrastructure/bpmn/subprocess/ChangeModelVnfBBTest.java
@@ -32,9 +32,10 @@ import org.onap.so.bpmn.common.BuildingBlockExecution;
public class ChangeModelVnfBBTest extends BaseBPMNTest{
@Test
public void changeModelVnfBBTest() {
+ mockSubprocess("SDNCHandler", "My Mock Process Name", "GenericStub");
ProcessInstance processInstance = runtimeService.startProcessInstanceByKey("ChangeModelVnfBB", variables);
assertThat(processInstance).isNotNull();
- assertThat(processInstance).isStarted().hasPassedInOrder("ChangeModelVnf_Start" ,"SDNCChangeModel", "AAIUpdateModel", "ChangeModelVnf_End");
+ assertThat(processInstance).isStarted().hasPassedInOrder("ChangeModelVnf_Start" ,"SDNCChangeModel", "CallActivity_sdncHandlerCall", "AAIUpdateModel", "ChangeModelVnf_End");
assertThat(processInstance).isEnded();
}
diff --git a/bpmn/so-bpmn-building-blocks/src/test/java/org/onap/so/bpmn/infrastructure/bpmn/subprocess/DeactivateNetworkBBTest.java b/bpmn/so-bpmn-building-blocks/src/test/java/org/onap/so/bpmn/infrastructure/bpmn/subprocess/DeactivateNetworkBBTest.java
index 02903cd00f..ad93eec514 100644
--- a/bpmn/so-bpmn-building-blocks/src/test/java/org/onap/so/bpmn/infrastructure/bpmn/subprocess/DeactivateNetworkBBTest.java
+++ b/bpmn/so-bpmn-building-blocks/src/test/java/org/onap/so/bpmn/infrastructure/bpmn/subprocess/DeactivateNetworkBBTest.java
@@ -32,14 +32,16 @@ import org.onap.so.bpmn.common.BuildingBlockExecution;
public class DeactivateNetworkBBTest extends BaseBPMNTest{
@Test
public void sunnyDayDeactivateNetworkBB_Test() throws InterruptedException {
+ mockSubprocess("SDNCHandler", "My Mock Process Name", "GenericStub");
ProcessInstance pi = runtimeService.startProcessInstanceByKey("DeactivateNetworkBB", variables);
assertThat(pi).isNotNull();
- assertThat(pi).isStarted().hasPassedInOrder("DeactivateNetworkBB_Start", "DeactivateNetworkSDNC", "DeactivateNetworkAAI", "DeactivateNetworkBB_End");
+ assertThat(pi).isStarted().hasPassedInOrder("DeactivateNetworkBB_Start", "DeactivateNetworkSDNC", "CallActivity_sdncHandler","DeactivateNetworkAAI", "DeactivateNetworkBB_End");
assertThat(pi).isEnded();
}
@Test
public void rainyDayDeactivateNetworkBB_Test() throws Exception {
+ mockSubprocess("SDNCHandler", "My Mock Process Name", "GenericStub");
doThrow(new BpmnError("7000", "TESTING ERRORS")).when(sdncDeactivateTasks).deactivateNetwork(any(BuildingBlockExecution.class));
ProcessInstance pi = runtimeService.startProcessInstanceByKey("DeactivateNetworkBB", variables);
assertThat(pi).isNotNull();
diff --git a/bpmn/so-bpmn-building-blocks/src/test/java/org/onap/so/bpmn/infrastructure/bpmn/subprocess/DeactivateServiceInstanceBBTest.java b/bpmn/so-bpmn-building-blocks/src/test/java/org/onap/so/bpmn/infrastructure/bpmn/subprocess/DeactivateServiceInstanceBBTest.java
index 2bf6377a71..428713d9a7 100644
--- a/bpmn/so-bpmn-building-blocks/src/test/java/org/onap/so/bpmn/infrastructure/bpmn/subprocess/DeactivateServiceInstanceBBTest.java
+++ b/bpmn/so-bpmn-building-blocks/src/test/java/org/onap/so/bpmn/infrastructure/bpmn/subprocess/DeactivateServiceInstanceBBTest.java
@@ -19,15 +19,11 @@
*/
package org.onap.so.bpmn.infrastructure.bpmn.subprocess;
-import static org.camunda.bpm.engine.test.assertions.ProcessEngineTests.assertThat;
-import static org.mockito.ArgumentMatchers.any;
-import static org.mockito.Mockito.doThrow;
+import static org.camunda.bpm.engine.test.assertions.bpmn.BpmnAwareAssertions.assertThat;
-import org.camunda.bpm.engine.delegate.BpmnError;
import org.camunda.bpm.engine.runtime.ProcessInstance;
import org.junit.Test;
import org.onap.so.bpmn.BaseBPMNTest;
-import org.onap.so.bpmn.common.BuildingBlockExecution;
/**
* Unit test cases for DeActivateServiceInstanceTest.bpmn
@@ -35,9 +31,10 @@ import org.onap.so.bpmn.common.BuildingBlockExecution;
public class DeactivateServiceInstanceBBTest extends BaseBPMNTest{
@Test
public void sunnyDayDeactivateServiceInstanceSDNC() throws InterruptedException {
+ mockSubprocess("SDNCHandler", "My Mock Process Name", "GenericStub");
ProcessInstance pi = runtimeService.startProcessInstanceByKey("DeactivateServiceInstanceBB", variables);
assertThat(pi).isNotNull();
- assertThat(pi).isStarted().hasPassedInOrder("Start_DeactivateServiceInstanceBB", "Task_DeactivateServiceInstance_SDNC", "Task_DeactivateServiceInstance_AAI", "End_DeactivateServiceInstanceBB");
+ assertThat(pi).isStarted().hasPassedInOrder("Start_DeactivateServiceInstanceBB", "Task_DeactivateServiceInstance_SDNC", "CallActivity_sdncHandler", "Task_DeactivateServiceInstance_AAI", "End_DeactivateServiceInstanceBB");
assertThat(pi).isEnded();
}
}
diff --git a/bpmn/so-bpmn-building-blocks/src/test/java/org/onap/so/bpmn/infrastructure/bpmn/subprocess/DeactivateVfModuleBBTest.java b/bpmn/so-bpmn-building-blocks/src/test/java/org/onap/so/bpmn/infrastructure/bpmn/subprocess/DeactivateVfModuleBBTest.java
index ef04d716fb..c7232e504e 100644
--- a/bpmn/so-bpmn-building-blocks/src/test/java/org/onap/so/bpmn/infrastructure/bpmn/subprocess/DeactivateVfModuleBBTest.java
+++ b/bpmn/so-bpmn-building-blocks/src/test/java/org/onap/so/bpmn/infrastructure/bpmn/subprocess/DeactivateVfModuleBBTest.java
@@ -34,15 +34,17 @@ import org.onap.so.bpmn.common.BuildingBlockExecution;
public class DeactivateVfModuleBBTest extends BaseBPMNTest{
@Test
public void sunnyDay() throws InterruptedException, IOException {
+ mockSubprocess("SDNCHandler", "My Mock Process Name", "GenericStub");
ProcessInstance pi = runtimeService.startProcessInstanceByKey("DeactivateVfModuleBB", variables);
assertThat(pi).isNotNull();
- assertThat(pi).isStarted().hasPassedInOrder("DeactivateVfModuleBB_Start", "DeactivateVfModule",
+ assertThat(pi).isStarted().hasPassedInOrder("DeactivateVfModuleBB_Start", "DeactivateVfModule", "CallActivity_sdncHandler",
"UpdateVfModuleDeactivateStatus", "DeactivateVfModuleBB_End");
assertThat(pi).isEnded();
}
@Test
public void rainyDay() throws Exception {
+ mockSubprocess("SDNCHandler", "My Mock Process Name", "GenericStub");
doThrow(BpmnError.class).when(aaiUpdateTasks).updateOrchestrationStatusDeactivateVfModule(any(BuildingBlockExecution.class));
ProcessInstance pi = runtimeService.startProcessInstanceByKey("DeactivateVfModuleBB", variables);
assertThat(pi).isNotNull();
diff --git a/bpmn/so-bpmn-building-blocks/src/test/java/org/onap/so/bpmn/infrastructure/bpmn/subprocess/DeactivateVnfBBTest.java b/bpmn/so-bpmn-building-blocks/src/test/java/org/onap/so/bpmn/infrastructure/bpmn/subprocess/DeactivateVnfBBTest.java
index 22cdfbb25a..bf5e228cbf 100644
--- a/bpmn/so-bpmn-building-blocks/src/test/java/org/onap/so/bpmn/infrastructure/bpmn/subprocess/DeactivateVnfBBTest.java
+++ b/bpmn/so-bpmn-building-blocks/src/test/java/org/onap/so/bpmn/infrastructure/bpmn/subprocess/DeactivateVnfBBTest.java
@@ -34,10 +34,11 @@ import org.onap.so.bpmn.common.BuildingBlockExecution;
public class DeactivateVnfBBTest extends BaseBPMNTest{
@Test
public void sunnyDay() throws InterruptedException, IOException {
+ mockSubprocess("SDNCHandler", "My Mock Process Name", "GenericStub");
ProcessInstance pi = runtimeService.startProcessInstanceByKey("DeactivateVnfBB", variables);
assertThat(pi).isNotNull();
assertThat(pi).isStarted().hasPassedInOrder("Start_DeactivateVnfBB","Task_SDNCAdapterVnfTopologyDeactivate",
- "Task_DeactivateOrchestrationStatusVnf", "End_DeactivateVnfBB");
+ "CallActivity_sdncHandler", "Task_DeactivateOrchestrationStatusVnf", "End_DeactivateVnfBB");
assertThat(pi).isEnded();
}
@@ -54,6 +55,7 @@ public class DeactivateVnfBBTest extends BaseBPMNTest{
@Test
public void rainyDayDeactivateVnfAAIError_Test() throws Exception {
+ mockSubprocess("SDNCHandler", "My Mock Process Name", "GenericStub");
doThrow(new BpmnError("7000", "TESTING ERRORS")).when(aaiUpdateTasks).updateOrchestrationStatusAssignedVnf(any(BuildingBlockExecution.class));
ProcessInstance pi = runtimeService.startProcessInstanceByKey("DeactivateVnfBB", variables);
assertThat(pi).isNotNull();
diff --git a/bpmn/so-bpmn-building-blocks/src/test/java/org/onap/so/bpmn/infrastructure/bpmn/subprocess/DeleteVfModuleBBTest.java b/bpmn/so-bpmn-building-blocks/src/test/java/org/onap/so/bpmn/infrastructure/bpmn/subprocess/DeleteVfModuleBBTest.java
index b88bb3a309..e7e8ac0631 100644
--- a/bpmn/so-bpmn-building-blocks/src/test/java/org/onap/so/bpmn/infrastructure/bpmn/subprocess/DeleteVfModuleBBTest.java
+++ b/bpmn/so-bpmn-building-blocks/src/test/java/org/onap/so/bpmn/infrastructure/bpmn/subprocess/DeleteVfModuleBBTest.java
@@ -33,6 +33,7 @@ import org.onap.so.bpmn.common.BuildingBlockExecution;
public class DeleteVfModuleBBTest extends BaseBPMNTest{
@Test
public void sunnyDay() throws InterruptedException, IOException {
+ mockSubprocess("SDNCHandler", "My Mock Process Name", "GenericStub");
mockSubprocess("VnfAdapter", "Mocked VnfAdapter", "GenericStub");
ProcessInstance pi = runtimeService.startProcessInstanceByKey("DeleteVfModuleBB", variables);
assertThat(pi).isNotNull();
diff --git a/bpmn/so-bpmn-building-blocks/src/test/java/org/onap/so/bpmn/infrastructure/bpmn/subprocess/UnassignNetworkBBTest.java b/bpmn/so-bpmn-building-blocks/src/test/java/org/onap/so/bpmn/infrastructure/bpmn/subprocess/UnassignNetworkBBTest.java
index b065ba092c..442d7b72c4 100644
--- a/bpmn/so-bpmn-building-blocks/src/test/java/org/onap/so/bpmn/infrastructure/bpmn/subprocess/UnassignNetworkBBTest.java
+++ b/bpmn/so-bpmn-building-blocks/src/test/java/org/onap/so/bpmn/infrastructure/bpmn/subprocess/UnassignNetworkBBTest.java
@@ -33,14 +33,16 @@ import org.onap.so.bpmn.common.BuildingBlockExecution;
public class UnassignNetworkBBTest extends BaseBPMNTest {
@Test
public void sunnyDayAssignNetwork_Test() throws InterruptedException {
+ mockSubprocess("SDNCHandler", "My Mock Process Name", "GenericStub");
ProcessInstance pi = runtimeService.startProcessInstanceByKey("UnassignNetworkBB",variables);
assertThat(pi).isNotNull();
- assertThat(pi).isStarted().hasPassedInOrder("Start_UnassignNetworkBB","Task_VfModuleRelatioship","Task_GetCloudRegionVersion","Task_SNDCUnAssign","Task_DeleteNetwork","End_UnassignNetworkBB");
+ assertThat(pi).isStarted().hasPassedInOrder("Start_UnassignNetworkBB","Task_VfModuleRelatioship","Task_GetCloudRegionVersion","Task_SNDCUnAssign","CallActivity_sdncHandlerCall","Task_DeleteNetwork","End_UnassignNetworkBB");
assertThat(pi).isEnded();
}
@Test
public void rainyDayAssignNetwork_Test() throws Exception {
+ mockSubprocess("SDNCHandler", "My Mock Process Name", "GenericStub");
doThrow(new BpmnError("7000", "TESTING ERRORS")).when(unassignNetworkBB).checkRelationshipRelatedTo(any(BuildingBlockExecution.class), eq("vf-module"));
ProcessInstance pi = runtimeService.startProcessInstanceByKey("UnassignNetworkBB", variables);
assertThat(pi).isNotNull();
diff --git a/bpmn/so-bpmn-building-blocks/src/test/java/org/onap/so/bpmn/infrastructure/bpmn/subprocess/UnassignServiceInstanceBBTest.java b/bpmn/so-bpmn-building-blocks/src/test/java/org/onap/so/bpmn/infrastructure/bpmn/subprocess/UnassignServiceInstanceBBTest.java
index f8eddab4c9..854c4f9c2e 100644
--- a/bpmn/so-bpmn-building-blocks/src/test/java/org/onap/so/bpmn/infrastructure/bpmn/subprocess/UnassignServiceInstanceBBTest.java
+++ b/bpmn/so-bpmn-building-blocks/src/test/java/org/onap/so/bpmn/infrastructure/bpmn/subprocess/UnassignServiceInstanceBBTest.java
@@ -31,13 +31,12 @@ import org.onap.so.bpmn.common.DelegateExecutionImpl;
public class UnassignServiceInstanceBBTest extends BaseBPMNTest{
@Test
public void sunnyDayUnassignServiceInstanceSDNC() throws InterruptedException {
+ mockSubprocess("SDNCHandler", "My Mock Process Name", "GenericStub");
BuildingBlockExecution bbe = new DelegateExecutionImpl(new ExecutionImpl());
-
variables.put("gBuildingBlockExecution", bbe);
-
ProcessInstance pi = runtimeService.startProcessInstanceByKey("UnassignServiceInstanceBB", variables);
assertThat(pi).isNotNull();
- assertThat(pi).isStarted().hasPassedInOrder("Start_UnassignServiceInstanceBB", "Task_SdncUnassignServiceInstance", "Task_AAIDeleteServiceInstance", "End_UnassignServiceInstanceBB");
+ assertThat(pi).isStarted().hasPassedInOrder("Start_UnassignServiceInstanceBB", "Task_SdncUnassignServiceInstance", "CallActivity_sdncHandlerCall", "Task_AAIDeleteServiceInstance", "End_UnassignServiceInstanceBB");
assertThat(pi).isEnded();
}
}
diff --git a/bpmn/so-bpmn-building-blocks/src/test/java/org/onap/so/bpmn/infrastructure/bpmn/subprocess/UnassignVfModuleBBTest.java b/bpmn/so-bpmn-building-blocks/src/test/java/org/onap/so/bpmn/infrastructure/bpmn/subprocess/UnassignVfModuleBBTest.java
index 90955e3ac5..89089770b1 100644
--- a/bpmn/so-bpmn-building-blocks/src/test/java/org/onap/so/bpmn/infrastructure/bpmn/subprocess/UnassignVfModuleBBTest.java
+++ b/bpmn/so-bpmn-building-blocks/src/test/java/org/onap/so/bpmn/infrastructure/bpmn/subprocess/UnassignVfModuleBBTest.java
@@ -32,10 +32,12 @@ import org.onap.so.bpmn.common.BuildingBlockExecution;
public class UnassignVfModuleBBTest extends BaseBPMNTest{
@Test
public void sunnyDayUnassignVfModule_Test() throws InterruptedException {
+ mockSubprocess("SDNCHandler", "My Mock Process Name", "GenericStub");
ProcessInstance pi = runtimeService.startProcessInstanceByKey("UnassignVfModuleBB", variables);
assertThat(pi).isNotNull();
assertThat(pi).isStarted().hasPassedInOrder("UnassignVfModuleBB_Start",
"UnassignVfModule",
+ "CallActivity_sdncHandler",
"DeleteVfModule",
"UnassignVfModuleBB_End");
assertThat(pi).isEnded();
@@ -43,6 +45,7 @@ public class UnassignVfModuleBBTest extends BaseBPMNTest{
@Test
public void rainyDayUnassignVfModuleAAIDeleteFailed_Test() throws Exception {
+ mockSubprocess("SDNCHandler", "My Mock Process Name", "GenericStub");
doThrow(new BpmnError("7000", "TESTING ERRORS")).when(aaiDeleteTasks).deleteVfModule(any(BuildingBlockExecution.class));
ProcessInstance pi = runtimeService.startProcessInstanceByKey("UnassignVfModuleBB", variables);
assertThat(pi).isNotNull();
diff --git a/bpmn/so-bpmn-building-blocks/src/test/java/org/onap/so/bpmn/infrastructure/bpmn/subprocess/UnassignVnfBBTest.java b/bpmn/so-bpmn-building-blocks/src/test/java/org/onap/so/bpmn/infrastructure/bpmn/subprocess/UnassignVnfBBTest.java
index 57d2ac5170..d508f4fcd7 100644
--- a/bpmn/so-bpmn-building-blocks/src/test/java/org/onap/so/bpmn/infrastructure/bpmn/subprocess/UnassignVnfBBTest.java
+++ b/bpmn/so-bpmn-building-blocks/src/test/java/org/onap/so/bpmn/infrastructure/bpmn/subprocess/UnassignVnfBBTest.java
@@ -33,10 +33,12 @@ import org.onap.so.bpmn.common.BuildingBlockExecution;
public class UnassignVnfBBTest extends BaseBPMNTest{
@Test
public void sunnyDayUnassignVnf_Test() throws InterruptedException {
+ mockSubprocess("SDNCHandler", "My Mock Process Name", "GenericStub");
ProcessInstance pi = runtimeService.startProcessInstanceByKey("UnassignVnfBB", variables);
assertThat(pi).isNotNull();
assertThat(pi).isStarted().hasPassedInOrder("UnassignVnfBB_Start",
"UnassignVnf",
+ "CallActivity_sdncHandlerCall",
"DeleteVnfInstanceGroups",
"DeleteVnf",
"UnassignVnfBB_End");
@@ -56,6 +58,7 @@ public class UnassignVnfBBTest extends BaseBPMNTest{
@Test
public void rainyDayUnassignVnfAAIDeleteFailed_Test() throws Exception {
+ mockSubprocess("SDNCHandler", "My Mock Process Name", "GenericStub");
doThrow(new BpmnError("7000", "TESTING ERRORS")).when(aaiDeleteTasks).deleteVnf(any(BuildingBlockExecution.class));
ProcessInstance pi = runtimeService.startProcessInstanceByKey("UnassignVnfBB", variables);
assertThat(pi).isNotNull().isStarted().hasPassedInOrder("UnassignVnfBB_Start", "UnassignVnf", "DeleteVnfInstanceGroups","DeleteVnf")
diff --git a/bpmn/so-bpmn-tasks/src/main/java/org/onap/so/bpmn/infrastructure/sdnc/tasks/SDNCActivateTasks.java b/bpmn/so-bpmn-tasks/src/main/java/org/onap/so/bpmn/infrastructure/sdnc/tasks/SDNCActivateTasks.java
index e587e80251..43ee71e676 100644
--- a/bpmn/so-bpmn-tasks/src/main/java/org/onap/so/bpmn/infrastructure/sdnc/tasks/SDNCActivateTasks.java
+++ b/bpmn/so-bpmn-tasks/src/main/java/org/onap/so/bpmn/infrastructure/sdnc/tasks/SDNCActivateTasks.java
@@ -20,6 +20,9 @@
package org.onap.so.bpmn.infrastructure.sdnc.tasks;
+import org.onap.sdnc.northbound.client.model.GenericResourceApiNetworkOperationInformation;
+import org.onap.sdnc.northbound.client.model.GenericResourceApiVfModuleOperationInformation;
+import org.onap.sdnc.northbound.client.model.GenericResourceApiVnfOperationInformation;
import org.onap.so.bpmn.common.BuildingBlockExecution;
import org.onap.so.bpmn.servicedecomposition.bbobjects.CloudRegion;
import org.onap.so.bpmn.servicedecomposition.bbobjects.Customer;
@@ -36,6 +39,8 @@ import org.onap.so.client.exception.ExceptionBuilder;
import org.onap.so.client.orchestration.SDNCNetworkResources;
import org.onap.so.client.orchestration.SDNCVfModuleResources;
import org.onap.so.client.orchestration.SDNCVnfResources;
+import org.onap.so.client.sdnc.beans.SDNCRequest;
+import org.onap.so.client.sdnc.endpoint.SDNCTopology;
import org.onap.so.logger.MsoLogger;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Component;
@@ -63,8 +68,11 @@ public class SDNCActivateTasks {
GenericVnf vnf = extractPojosForBB.extractByKey(execution, ResourceKey.GENERIC_VNF_ID, execution.getLookupMap().get(ResourceKey.GENERIC_VNF_ID));
CloudRegion cloudRegion = gBBInput.getCloudRegion();
Customer customer = gBBInput.getCustomer();
- String response = sdncVnfResources.activateVnf(vnf, serviceInstance, customer, cloudRegion, requestContext);
- execution.setVariable("SDNCResponse", response);
+ GenericResourceApiVnfOperationInformation req = sdncVnfResources.activateVnf(vnf, serviceInstance, customer, cloudRegion, requestContext);
+ SDNCRequest sdncRequest = new SDNCRequest();
+ sdncRequest.setSDNCPayload(req);
+ sdncRequest.setTopology(SDNCTopology.VNF);
+ execution.setVariable("SDNCRequest", sdncRequest);
} catch (Exception ex) {
exceptionUtil.buildAndThrowWorkflowException(execution, 7000, ex);
}
@@ -76,18 +84,18 @@ public class SDNCActivateTasks {
* @throws BBObjectNotFoundException
*/
public void activateNetwork(BuildingBlockExecution execution) throws BBObjectNotFoundException {
- execution.setVariable("sdncNetworkActivateRollback", false);
- GeneralBuildingBlock gBBInput = execution.getGeneralBuildingBlock();
-
- L3Network l3network = extractPojosForBB.extractByKey(execution, ResourceKey.NETWORK_ID, execution.getLookupMap().get(ResourceKey.NETWORK_ID));
- ServiceInstance serviceInstance = extractPojosForBB.extractByKey(execution, ResourceKey.SERVICE_INSTANCE_ID, execution.getLookupMap().get(ResourceKey.SERVICE_INSTANCE_ID));
-
- Customer customer = gBBInput.getCustomer();
- RequestContext requestContext = gBBInput.getRequestContext();
- CloudRegion cloudRegion = gBBInput.getCloudRegion();
- try {
- sdncNetworkResources.activateNetwork(l3network, serviceInstance, customer, requestContext, cloudRegion);
- execution.setVariable("sdncNetworkActivateRollback", true);
+ try{
+ GeneralBuildingBlock gBBInput = execution.getGeneralBuildingBlock();
+ L3Network l3network = extractPojosForBB.extractByKey(execution, ResourceKey.NETWORK_ID, execution.getLookupMap().get(ResourceKey.NETWORK_ID));
+ ServiceInstance serviceInstance = extractPojosForBB.extractByKey(execution, ResourceKey.SERVICE_INSTANCE_ID, execution.getLookupMap().get(ResourceKey.SERVICE_INSTANCE_ID));
+ Customer customer = gBBInput.getCustomer();
+ RequestContext requestContext = gBBInput.getRequestContext();
+ CloudRegion cloudRegion = gBBInput.getCloudRegion();
+ GenericResourceApiNetworkOperationInformation req = sdncNetworkResources.activateNetwork(l3network, serviceInstance, customer, requestContext, cloudRegion);
+ SDNCRequest sdncRequest = new SDNCRequest();
+ sdncRequest.setSDNCPayload(req);
+ sdncRequest.setTopology(SDNCTopology.NETWORK);
+ execution.setVariable("SDNCRequest", sdncRequest);
} catch (Exception ex) {
exceptionUtil.buildAndThrowWorkflowException(execution, 7000, ex);
}
@@ -108,12 +116,12 @@ public class SDNCActivateTasks {
execution.getLookupMap().get(ResourceKey.VF_MODULE_ID));
Customer customer = gBBInput.getCustomer();
CloudRegion cloudRegion = gBBInput.getCloudRegion();
- execution.setVariable("sdncActivateVfModuleRollback", false);
-
- String response = sdncVfModuleResources.activateVfModule(vfModule, vnf, serviceInstance, customer,
+ GenericResourceApiVfModuleOperationInformation req = sdncVfModuleResources.activateVfModule(vfModule, vnf, serviceInstance, customer,
cloudRegion, requestContext);
- execution.setVariable("SDNCActivateVfModuleResponse", response);
- execution.setVariable("sdncActivateVfModuleRollback", true);
+ SDNCRequest sdncRequest = new SDNCRequest();
+ sdncRequest.setSDNCPayload(req);
+ sdncRequest.setTopology(SDNCTopology.VFMODULE);
+ execution.setVariable("SDNCRequest", sdncRequest);
} catch (Exception ex) {
exceptionUtil.buildAndThrowWorkflowException(execution, 7000, ex);
}
diff --git a/bpmn/so-bpmn-tasks/src/main/java/org/onap/so/bpmn/infrastructure/sdnc/tasks/SDNCAssignTasks.java b/bpmn/so-bpmn-tasks/src/main/java/org/onap/so/bpmn/infrastructure/sdnc/tasks/SDNCAssignTasks.java
index 30f38fc2ed..2695a170b4 100644
--- a/bpmn/so-bpmn-tasks/src/main/java/org/onap/so/bpmn/infrastructure/sdnc/tasks/SDNCAssignTasks.java
+++ b/bpmn/so-bpmn-tasks/src/main/java/org/onap/so/bpmn/infrastructure/sdnc/tasks/SDNCAssignTasks.java
@@ -20,6 +20,9 @@
package org.onap.so.bpmn.infrastructure.sdnc.tasks;
+import org.onap.sdnc.northbound.client.model.GenericResourceApiNetworkOperationInformation;
+import org.onap.sdnc.northbound.client.model.GenericResourceApiServiceOperationInformation;
+import org.onap.sdnc.northbound.client.model.GenericResourceApiVfModuleOperationInformation;
import org.onap.sdnc.northbound.client.model.GenericResourceApiVnfOperationInformation;
import org.onap.so.bpmn.common.BuildingBlockExecution;
import org.onap.so.bpmn.servicedecomposition.bbobjects.CloudRegion;
@@ -67,8 +70,11 @@ public class SDNCAssignTasks {
RequestContext requestContext = gBBInput.getRequestContext();
ServiceInstance serviceInstance = extractPojosForBB.extractByKey(execution, ResourceKey.SERVICE_INSTANCE_ID, execution.getLookupMap().get(ResourceKey.SERVICE_INSTANCE_ID));
Customer customer = gBBInput.getCustomer();
- String response = sdncSIResources.assignServiceInstance(serviceInstance, customer, requestContext);
- execution.setVariable("SDNCResponse", response);
+ GenericResourceApiServiceOperationInformation req = sdncSIResources.assignServiceInstance(serviceInstance, customer, requestContext);
+ SDNCRequest sdncRequest = new SDNCRequest();
+ sdncRequest.setSDNCPayload(req);
+ sdncRequest.setTopology(SDNCTopology.SERVICE);
+ execution.setVariable("SDNCRequest", sdncRequest);
} catch (Exception ex) {
exceptionUtil.buildAndThrowWorkflowException(execution, 7000, ex);
}
@@ -107,9 +113,11 @@ public class SDNCAssignTasks {
}
Customer customer = gBBInput.getCustomer();
CloudRegion cloudRegion = gBBInput.getCloudRegion();
-
- String response = sdncVfModuleResources.assignVfModule(vfModule, volumeGroup, vnf, serviceInstance, customer, cloudRegion, requestContext);
- execution.setVariable("SDNCAssignResponse_"+ vfModule.getVfModuleId(), response);
+ GenericResourceApiVfModuleOperationInformation req = sdncVfModuleResources.assignVfModule(vfModule, volumeGroup, vnf, serviceInstance, customer, cloudRegion, requestContext);
+ SDNCRequest sdncRequest = new SDNCRequest();
+ sdncRequest.setSDNCPayload(req);
+ sdncRequest.setTopology(SDNCTopology.VFMODULE);
+ execution.setVariable("SDNCRequest", sdncRequest);
} catch (Exception ex) {
exceptionUtil.buildAndThrowWorkflowException(execution, 7000, ex);
}
@@ -123,15 +131,16 @@ public class SDNCAssignTasks {
public void assignNetwork(BuildingBlockExecution execution) {
try {
GeneralBuildingBlock gBBInput = execution.getGeneralBuildingBlock();
-
L3Network l3network = extractPojosForBB.extractByKey(execution, ResourceKey.NETWORK_ID, execution.getLookupMap().get(ResourceKey.NETWORK_ID));
ServiceInstance serviceInstance = extractPojosForBB.extractByKey(execution, ResourceKey.SERVICE_INSTANCE_ID, execution.getLookupMap().get(ResourceKey.SERVICE_INSTANCE_ID));
-
Customer customer = gBBInput.getCustomer();
RequestContext requestContext = gBBInput.getRequestContext();
CloudRegion cloudRegion = gBBInput.getCloudRegion();
-
- sdncNetworkResources.assignNetwork(l3network, serviceInstance, customer, requestContext, cloudRegion);
+ GenericResourceApiNetworkOperationInformation req = sdncNetworkResources.assignNetwork(l3network, serviceInstance, customer, requestContext, cloudRegion);
+ SDNCRequest sdncRequest = new SDNCRequest();
+ sdncRequest.setSDNCPayload(req);
+ sdncRequest.setTopology(SDNCTopology.NETWORK);
+ execution.setVariable("SDNCRequest", sdncRequest);
} catch (Exception ex) {
exceptionUtil.buildAndThrowWorkflowException(execution, 7000, ex);
}
diff --git a/bpmn/so-bpmn-tasks/src/main/java/org/onap/so/bpmn/infrastructure/sdnc/tasks/SDNCChangeAssignTasks.java b/bpmn/so-bpmn-tasks/src/main/java/org/onap/so/bpmn/infrastructure/sdnc/tasks/SDNCChangeAssignTasks.java
index cae4dc26de..592b831d62 100644
--- a/bpmn/so-bpmn-tasks/src/main/java/org/onap/so/bpmn/infrastructure/sdnc/tasks/SDNCChangeAssignTasks.java
+++ b/bpmn/so-bpmn-tasks/src/main/java/org/onap/so/bpmn/infrastructure/sdnc/tasks/SDNCChangeAssignTasks.java
@@ -20,6 +20,10 @@
package org.onap.so.bpmn.infrastructure.sdnc.tasks;
+import org.onap.sdnc.northbound.client.model.GenericResourceApiNetworkOperationInformation;
+import org.onap.sdnc.northbound.client.model.GenericResourceApiServiceOperationInformation;
+import org.onap.sdnc.northbound.client.model.GenericResourceApiVfModuleOperationInformation;
+import org.onap.sdnc.northbound.client.model.GenericResourceApiVnfOperationInformation;
import org.onap.so.bpmn.common.BuildingBlockExecution;
import org.onap.so.bpmn.servicedecomposition.bbobjects.CloudRegion;
import org.onap.so.bpmn.servicedecomposition.bbobjects.Customer;
@@ -36,6 +40,8 @@ import org.onap.so.client.orchestration.SDNCNetworkResources;
import org.onap.so.client.orchestration.SDNCServiceInstanceResources;
import org.onap.so.client.orchestration.SDNCVfModuleResources;
import org.onap.so.client.orchestration.SDNCVnfResources;
+import org.onap.so.client.sdnc.beans.SDNCRequest;
+import org.onap.so.client.sdnc.endpoint.SDNCTopology;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Component;
@@ -58,9 +64,11 @@ public class SDNCChangeAssignTasks {
try {
GeneralBuildingBlock gBBInput = execution.getGeneralBuildingBlock();
ServiceInstance serviceInstance = extractPojosForBB.extractByKey(execution, ResourceKey.SERVICE_INSTANCE_ID, execution.getLookupMap().get(ResourceKey.SERVICE_INSTANCE_ID));
-
- String response = sdncServiceInstanceResources.changeModelServiceInstance(serviceInstance, gBBInput.getCustomer(), gBBInput.getRequestContext());
- execution.setVariable("SDNCChangeAssignTasks.changeModelServiceInstance.response", response);
+ GenericResourceApiServiceOperationInformation req = sdncServiceInstanceResources.changeModelServiceInstance(serviceInstance, gBBInput.getCustomer(), gBBInput.getRequestContext());
+ SDNCRequest sdncRequest = new SDNCRequest();
+ sdncRequest.setSDNCPayload(req);
+ sdncRequest.setTopology(SDNCTopology.SERVICE);
+ execution.setVariable("SDNCRequest", sdncRequest);
} catch(Exception ex) {
exceptionUtil.buildAndThrowWorkflowException(execution, 7000, ex);
}
@@ -71,9 +79,11 @@ public class SDNCChangeAssignTasks {
GeneralBuildingBlock gBBInput = execution.getGeneralBuildingBlock();
GenericVnf genericVnf = extractPojosForBB.extractByKey(execution, ResourceKey.GENERIC_VNF_ID, execution.getLookupMap().get(ResourceKey.GENERIC_VNF_ID));
ServiceInstance serviceInstance = extractPojosForBB.extractByKey(execution, ResourceKey.SERVICE_INSTANCE_ID, execution.getLookupMap().get(ResourceKey.SERVICE_INSTANCE_ID));
-
- String response = sdncVnfResources.changeModelVnf(genericVnf, serviceInstance, gBBInput.getCustomer(), gBBInput.getCloudRegion(), gBBInput.getRequestContext());
- execution.setVariable("SDNCChangeModelVnfResponse", response);
+ GenericResourceApiVnfOperationInformation req = sdncVnfResources.changeModelVnf(genericVnf, serviceInstance, gBBInput.getCustomer(), gBBInput.getCloudRegion(), gBBInput.getRequestContext());
+ SDNCRequest sdncRequest = new SDNCRequest();
+ sdncRequest.setSDNCPayload(req);
+ sdncRequest.setTopology(SDNCTopology.VNF);
+ execution.setVariable("SDNCRequest", sdncRequest);
} catch(Exception ex) {
exceptionUtil.buildAndThrowWorkflowException(execution, 7000, ex);
}
@@ -84,9 +94,11 @@ public class SDNCChangeAssignTasks {
GeneralBuildingBlock gBBInput = execution.getGeneralBuildingBlock();
L3Network network = extractPojosForBB.extractByKey(execution, ResourceKey.NETWORK_ID, execution.getLookupMap().get(ResourceKey.NETWORK_ID));
ServiceInstance serviceInstance = extractPojosForBB.extractByKey(execution, ResourceKey.SERVICE_INSTANCE_ID, execution.getLookupMap().get(ResourceKey.SERVICE_INSTANCE_ID));
-
- String sdncResponse = sdncNetworkResources.changeAssignNetwork(network, serviceInstance, gBBInput.getCustomer(), gBBInput.getRequestContext(), gBBInput.getCloudRegion());
- execution.setVariable("SDNCChangeAssignNetworkResponse", sdncResponse);
+ GenericResourceApiNetworkOperationInformation req = sdncNetworkResources.changeAssignNetwork(network, serviceInstance, gBBInput.getCustomer(), gBBInput.getRequestContext(), gBBInput.getCloudRegion());
+ SDNCRequest sdncRequest = new SDNCRequest();
+ sdncRequest.setSDNCPayload(req);
+ sdncRequest.setTopology(SDNCTopology.NETWORK);
+ execution.setVariable("SDNCRequest", sdncRequest);
} catch(Exception ex) {
exceptionUtil.buildAndThrowWorkflowException(execution, 7000, ex);
}
@@ -101,8 +113,11 @@ public class SDNCChangeAssignTasks {
GenericVnf vnf = extractPojosForBB.extractByKey(execution, ResourceKey.GENERIC_VNF_ID, execution.getLookupMap().get(ResourceKey.GENERIC_VNF_ID));
VfModule vfModule = extractPojosForBB.extractByKey(execution, ResourceKey.VF_MODULE_ID, execution.getLookupMap().get(ResourceKey.VF_MODULE_ID));
Customer customer = gBBInput.getCustomer();
- String response = sdncVfModuleResources.changeAssignVfModule(vfModule, vnf, serviceInstance, customer, cloudRegion, requestContext);
- execution.setVariable("SDNCChangeAssignVfModuleResponse", response);
+ GenericResourceApiVfModuleOperationInformation req = sdncVfModuleResources.changeAssignVfModule(vfModule, vnf, serviceInstance, customer, cloudRegion, requestContext);
+ SDNCRequest sdncRequest = new SDNCRequest();
+ sdncRequest.setSDNCPayload(req);
+ sdncRequest.setTopology(SDNCTopology.VFMODULE);
+ execution.setVariable("SDNCRequest", sdncRequest);
} catch (Exception ex) {
exceptionUtil.buildAndThrowWorkflowException(execution, 7000, ex);
}
diff --git a/bpmn/so-bpmn-tasks/src/main/java/org/onap/so/bpmn/infrastructure/sdnc/tasks/SDNCDeactivateTasks.java b/bpmn/so-bpmn-tasks/src/main/java/org/onap/so/bpmn/infrastructure/sdnc/tasks/SDNCDeactivateTasks.java
index 1f6ec72f34..eb078e04b4 100644
--- a/bpmn/so-bpmn-tasks/src/main/java/org/onap/so/bpmn/infrastructure/sdnc/tasks/SDNCDeactivateTasks.java
+++ b/bpmn/so-bpmn-tasks/src/main/java/org/onap/so/bpmn/infrastructure/sdnc/tasks/SDNCDeactivateTasks.java
@@ -20,6 +20,10 @@
package org.onap.so.bpmn.infrastructure.sdnc.tasks;
+import org.onap.sdnc.northbound.client.model.GenericResourceApiNetworkOperationInformation;
+import org.onap.sdnc.northbound.client.model.GenericResourceApiServiceOperationInformation;
+import org.onap.sdnc.northbound.client.model.GenericResourceApiVfModuleOperationInformation;
+import org.onap.sdnc.northbound.client.model.GenericResourceApiVnfOperationInformation;
import org.onap.so.bpmn.common.BuildingBlockExecution;
import org.onap.so.bpmn.servicedecomposition.bbobjects.CloudRegion;
import org.onap.so.bpmn.servicedecomposition.bbobjects.Customer;
@@ -36,6 +40,8 @@ import org.onap.so.client.orchestration.SDNCNetworkResources;
import org.onap.so.client.orchestration.SDNCServiceInstanceResources;
import org.onap.so.client.orchestration.SDNCVfModuleResources;
import org.onap.so.client.orchestration.SDNCVnfResources;
+import org.onap.so.client.sdnc.beans.SDNCRequest;
+import org.onap.so.client.sdnc.endpoint.SDNCTopology;
import org.onap.so.logger.MsoLogger;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Component;
@@ -61,23 +67,17 @@ public class SDNCDeactivateTasks {
try {
GeneralBuildingBlock gBBInput = execution.getGeneralBuildingBlock();
RequestContext requestContext = gBBInput.getRequestContext();
-
- ServiceInstance serviceInstance = extractPojosForBB.extractByKey(execution, ResourceKey.SERVICE_INSTANCE_ID,
- execution.getLookupMap().get(ResourceKey.SERVICE_INSTANCE_ID));
- GenericVnf vnf = extractPojosForBB.extractByKey(execution, ResourceKey.GENERIC_VNF_ID,
- execution.getLookupMap().get(ResourceKey.GENERIC_VNF_ID));
- VfModule vfModule = extractPojosForBB.extractByKey(execution, ResourceKey.VF_MODULE_ID,
- execution.getLookupMap().get(ResourceKey.VF_MODULE_ID));
-
+ ServiceInstance serviceInstance = extractPojosForBB.extractByKey(execution, ResourceKey.SERVICE_INSTANCE_ID, execution.getLookupMap().get(ResourceKey.SERVICE_INSTANCE_ID));
+ GenericVnf vnf = extractPojosForBB.extractByKey(execution, ResourceKey.GENERIC_VNF_ID, execution.getLookupMap().get(ResourceKey.GENERIC_VNF_ID));
+ VfModule vfModule = extractPojosForBB.extractByKey(execution, ResourceKey.VF_MODULE_ID, execution.getLookupMap().get(ResourceKey.VF_MODULE_ID));
Customer customer = gBBInput.getCustomer();
CloudRegion cloudRegion = gBBInput.getCloudRegion();
- execution.setVariable("sdncDeactivateVfModuleRollback", false);
-
- String response = sdncVfModuleResources.deactivateVfModule(vfModule, vnf, serviceInstance, customer,
+ GenericResourceApiVfModuleOperationInformation req = sdncVfModuleResources.deactivateVfModule(vfModule, vnf, serviceInstance, customer,
cloudRegion, requestContext);
- execution.setVariable("SDNCDeactivateVfModuleResponse", response);
- execution.setVariable("sdncDeactivateVfModuleRollback", true);
- } catch (Exception ex) {
+ SDNCRequest sdncRequest = new SDNCRequest();
+ sdncRequest.setSDNCPayload(req);
+ sdncRequest.setTopology(SDNCTopology.VFMODULE);
+ execution.setVariable("SDNCRequest", sdncRequest); } catch (Exception ex) {
exceptionUtil.buildAndThrowWorkflowException(execution, 7000, ex);
}
}
@@ -93,15 +93,15 @@ public class SDNCDeactivateTasks {
RequestContext requestContext = gBBInput.getRequestContext();
ServiceInstance serviceInstance = null;
GenericVnf vnf = null;
-
- serviceInstance = extractPojosForBB.extractByKey(execution, ResourceKey.SERVICE_INSTANCE_ID,
- execution.getLookupMap().get(ResourceKey.SERVICE_INSTANCE_ID));
- vnf = extractPojosForBB.extractByKey(execution, ResourceKey.GENERIC_VNF_ID,
- execution.getLookupMap().get(ResourceKey.GENERIC_VNF_ID));
+ serviceInstance = extractPojosForBB.extractByKey(execution, ResourceKey.SERVICE_INSTANCE_ID, execution.getLookupMap().get(ResourceKey.SERVICE_INSTANCE_ID));
+ vnf = extractPojosForBB.extractByKey(execution, ResourceKey.GENERIC_VNF_ID, execution.getLookupMap().get(ResourceKey.GENERIC_VNF_ID));
CloudRegion cloudRegion = gBBInput.getCloudRegion();
Customer customer = gBBInput.getCustomer();
- String response = sdncVnfResources.deactivateVnf(vnf, serviceInstance, customer, cloudRegion, requestContext);
- execution.setVariable("SDNCDeactivateVnfResponse", response);
+ GenericResourceApiVnfOperationInformation req = sdncVnfResources.deactivateVnf(vnf, serviceInstance, customer, cloudRegion, requestContext);
+ SDNCRequest sdncRequest = new SDNCRequest();
+ sdncRequest.setSDNCPayload(req);
+ sdncRequest.setTopology(SDNCTopology.VNF);
+ execution.setVariable("SDNCRequest", sdncRequest);
} catch (Exception ex) {
exceptionUtil.buildAndThrowWorkflowException(execution, 7000, ex);
}
@@ -119,10 +119,11 @@ public class SDNCDeactivateTasks {
ServiceInstance serviceInstance = extractPojosForBB.extractByKey(execution, ResourceKey.SERVICE_INSTANCE_ID,
execution.getLookupMap().get(ResourceKey.SERVICE_INSTANCE_ID));
Customer customer = gBBInput.getCustomer();
- execution.setVariable("sdncServiceInstanceRollback", false);
- String response = sdncSIResources.deactivateServiceInstance(serviceInstance, customer, requestContext);
- execution.setVariable("deactivateServiceInstanceSDNCResponse", response);
- execution.setVariable("sdncServiceInstanceRollback", true);
+ GenericResourceApiServiceOperationInformation req = sdncSIResources.deactivateServiceInstance(serviceInstance, customer, requestContext);
+ SDNCRequest sdncRequest = new SDNCRequest();
+ sdncRequest.setSDNCPayload(req);
+ sdncRequest.setTopology(SDNCTopology.SERVICE);
+ execution.setVariable("SDNCRequest", sdncRequest);
} catch (Exception ex) {
exceptionUtil.buildAndThrowWorkflowException(execution, 7000, ex);
}
@@ -134,7 +135,6 @@ public class SDNCDeactivateTasks {
* @param execution
*/
public void deactivateNetwork(BuildingBlockExecution execution) {
- execution.setVariable("SDNCDeactivateTasks.deactivateNetwork.rollback", false);
try {
GeneralBuildingBlock gBBInput = execution.getGeneralBuildingBlock();
L3Network l3Network = extractPojosForBB.extractByKey(execution, ResourceKey.NETWORK_ID, execution.getLookupMap().get(ResourceKey.NETWORK_ID));
@@ -142,11 +142,12 @@ public class SDNCDeactivateTasks {
Customer customer = gBBInput.getCustomer();
RequestContext requestContext = gBBInput.getRequestContext();
CloudRegion cloudRegion = gBBInput.getCloudRegion();
-
- String response = sdncNetworkResources.deactivateNetwork(l3Network, serviceInstance, customer,
+ GenericResourceApiNetworkOperationInformation req = sdncNetworkResources.deactivateNetwork(l3Network, serviceInstance, customer,
requestContext, cloudRegion);
- execution.setVariable("SDNCDeactivateTasks.deactivateNetwork.response", response);
- execution.setVariable("SDNCDeactivateTasks.deactivateNetwork.rollback", true);
+ SDNCRequest sdncRequest = new SDNCRequest();
+ sdncRequest.setSDNCPayload(req);
+ sdncRequest.setTopology(SDNCTopology.NETWORK);
+ execution.setVariable("SDNCRequest", sdncRequest);
} catch (Exception ex) {
exceptionUtil.buildAndThrowWorkflowException(execution, 7000, ex);
}
diff --git a/bpmn/so-bpmn-tasks/src/main/java/org/onap/so/bpmn/infrastructure/sdnc/tasks/SDNCUnassignTasks.java b/bpmn/so-bpmn-tasks/src/main/java/org/onap/so/bpmn/infrastructure/sdnc/tasks/SDNCUnassignTasks.java
index ab4a7f8a2c..960fb9988a 100644
--- a/bpmn/so-bpmn-tasks/src/main/java/org/onap/so/bpmn/infrastructure/sdnc/tasks/SDNCUnassignTasks.java
+++ b/bpmn/so-bpmn-tasks/src/main/java/org/onap/so/bpmn/infrastructure/sdnc/tasks/SDNCUnassignTasks.java
@@ -20,6 +20,10 @@
package org.onap.so.bpmn.infrastructure.sdnc.tasks;
+import org.onap.sdnc.northbound.client.model.GenericResourceApiNetworkOperationInformation;
+import org.onap.sdnc.northbound.client.model.GenericResourceApiServiceOperationInformation;
+import org.onap.sdnc.northbound.client.model.GenericResourceApiVfModuleOperationInformation;
+import org.onap.sdnc.northbound.client.model.GenericResourceApiVnfOperationInformation;
import org.onap.so.bpmn.common.BuildingBlockExecution;
import org.onap.so.bpmn.servicedecomposition.bbobjects.CloudRegion;
import org.onap.so.bpmn.servicedecomposition.bbobjects.Customer;
@@ -36,6 +40,8 @@ import org.onap.so.client.orchestration.SDNCNetworkResources;
import org.onap.so.client.orchestration.SDNCServiceInstanceResources;
import org.onap.so.client.orchestration.SDNCVfModuleResources;
import org.onap.so.client.orchestration.SDNCVnfResources;
+import org.onap.so.client.sdnc.beans.SDNCRequest;
+import org.onap.so.client.sdnc.endpoint.SDNCTopology;
import org.onap.so.logger.MsoLogger;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Component;
@@ -59,11 +65,14 @@ public class SDNCUnassignTasks {
public void unassignServiceInstance(BuildingBlockExecution execution) {
try {
GeneralBuildingBlock gBBInput = execution.getGeneralBuildingBlock();
- ServiceInstance serviceInstance = extractPojosForBB.extractByKey(execution, ResourceKey.SERVICE_INSTANCE_ID, execution.getLookupMap().get(ResourceKey.SERVICE_INSTANCE_ID));
+ ServiceInstance serviceInstance = extractPojosForBB.extractByKey(execution, ResourceKey.SERVICE_INSTANCE_ID, execution.getLookupMap().get(ResourceKey.SERVICE_INSTANCE_ID));
RequestContext requestContext = gBBInput.getRequestContext();
Customer customer = gBBInput.getCustomer();
- String sdncUnassignResponse = sdncSIResources.unassignServiceInstance(serviceInstance, customer, requestContext);
- execution.setVariable("sdncUnassignResponse", sdncUnassignResponse);
+ GenericResourceApiServiceOperationInformation req = sdncSIResources.unassignServiceInstance(serviceInstance, customer, requestContext);
+ SDNCRequest sdncRequest = new SDNCRequest();
+ sdncRequest.setSDNCPayload(req);
+ sdncRequest.setTopology(SDNCTopology.SERVICE);
+ execution.setVariable("SDNCRequest", sdncRequest);
} catch (Exception ex) {
exceptionUtil.buildAndThrowWorkflowException(execution, 7000, ex);
}
@@ -74,11 +83,11 @@ public class SDNCUnassignTasks {
ServiceInstance serviceInstance = extractPojosForBB.extractByKey(execution, ResourceKey.SERVICE_INSTANCE_ID, execution.getLookupMap().get(ResourceKey.SERVICE_INSTANCE_ID));
GenericVnf vnf = extractPojosForBB.extractByKey(execution, ResourceKey.GENERIC_VNF_ID, execution.getLookupMap().get(ResourceKey.GENERIC_VNF_ID));
VfModule vfModule = extractPojosForBB.extractByKey(execution, ResourceKey.VF_MODULE_ID, execution.getLookupMap().get(ResourceKey.VF_MODULE_ID));
- execution.setVariable("sdncVfModuleRollback", false);
- String response = sdncVfModuleResources.unassignVfModule(vfModule, vnf, serviceInstance);
- execution.setVariable("SDNCResponse", response);
- execution.setVariable("sdncVfModuleRollback", true);
- } catch (Exception ex) {
+ GenericResourceApiVfModuleOperationInformation req = sdncVfModuleResources.unassignVfModule(vfModule, vnf, serviceInstance);
+ SDNCRequest sdncRequest = new SDNCRequest();
+ sdncRequest.setSDNCPayload(req);
+ sdncRequest.setTopology(SDNCTopology.VFMODULE);
+ execution.setVariable("SDNCRequest", sdncRequest); } catch (Exception ex) {
exceptionUtil.buildAndThrowWorkflowException(execution, 7000, ex);
}
}
@@ -91,28 +100,31 @@ public class SDNCUnassignTasks {
RequestContext requestContext = gBBInput.getRequestContext();
Customer customer = gBBInput.getCustomer();
CloudRegion cloudRegion = gBBInput.getCloudRegion();
- execution.setVariable("sdncVnfRollback", false);
- String response = sdncVnfResources.unassignVnf(vnf, serviceInstance, customer, cloudRegion, requestContext);
- execution.setVariable("sdncUnassignVnfResponse", response);
- execution.setVariable("sdncVnfRollback", true);
+ GenericResourceApiVnfOperationInformation req = sdncVnfResources.unassignVnf(vnf, serviceInstance, customer, cloudRegion, requestContext);
+ SDNCRequest sdncRequest = new SDNCRequest();
+ sdncRequest.setSDNCPayload(req);
+ sdncRequest.setTopology(SDNCTopology.VNF);
+ execution.setVariable("SDNCRequest", sdncRequest);
} catch (Exception ex) {
exceptionUtil.buildAndThrowWorkflowException(execution, 7000, ex);
}
}
public void unassignNetwork(BuildingBlockExecution execution) throws Exception {
- GeneralBuildingBlock gBBInput = execution.getGeneralBuildingBlock();
- L3Network network = extractPojosForBB.extractByKey(execution, ResourceKey.NETWORK_ID, execution.getLookupMap().get(ResourceKey.NETWORK_ID));
- ServiceInstance serviceInstance = extractPojosForBB.extractByKey(execution, ResourceKey.SERVICE_INSTANCE_ID, execution.getLookupMap().get(ResourceKey.SERVICE_INSTANCE_ID));
- Customer customer = gBBInput.getCustomer();
- RequestContext requestContext = gBBInput.getRequestContext();
- CloudRegion cloudRegion = gBBInput.getCloudRegion();
- String cloudRegionSdnc = execution.getVariable("cloudRegionSdnc");
- cloudRegion.setLcpCloudRegionId(cloudRegionSdnc);
try {
- String response = sdncNetworkResources.unassignNetwork(network, serviceInstance, customer, requestContext, cloudRegion);
- execution.setVariable("SDNCUnAssignNetworkResponse", response);
- execution.setVariable("isRollbackNeeded", true);
+ GeneralBuildingBlock gBBInput = execution.getGeneralBuildingBlock();
+ L3Network network = extractPojosForBB.extractByKey(execution, ResourceKey.NETWORK_ID, execution.getLookupMap().get(ResourceKey.NETWORK_ID));
+ ServiceInstance serviceInstance = extractPojosForBB.extractByKey(execution, ResourceKey.SERVICE_INSTANCE_ID, execution.getLookupMap().get(ResourceKey.SERVICE_INSTANCE_ID));
+ Customer customer = gBBInput.getCustomer();
+ RequestContext requestContext = gBBInput.getRequestContext();
+ CloudRegion cloudRegion = gBBInput.getCloudRegion();
+ String cloudRegionSdnc = execution.getVariable("cloudRegionSdnc");
+ cloudRegion.setLcpCloudRegionId(cloudRegionSdnc);
+ GenericResourceApiNetworkOperationInformation req = sdncNetworkResources.unassignNetwork(network, serviceInstance, customer, requestContext, cloudRegion);
+ SDNCRequest sdncRequest = new SDNCRequest();
+ sdncRequest.setSDNCPayload(req);
+ sdncRequest.setTopology(SDNCTopology.NETWORK);
+ execution.setVariable("SDNCRequest", sdncRequest);
} catch (Exception ex) {
exceptionUtil.buildAndThrowWorkflowException(execution, 7000, ex);
}
diff --git a/bpmn/so-bpmn-tasks/src/main/java/org/onap/so/client/orchestration/SDNCNetworkResources.java b/bpmn/so-bpmn-tasks/src/main/java/org/onap/so/client/orchestration/SDNCNetworkResources.java
index d3589db101..8b53c28547 100644
--- a/bpmn/so-bpmn-tasks/src/main/java/org/onap/so/client/orchestration/SDNCNetworkResources.java
+++ b/bpmn/so-bpmn-tasks/src/main/java/org/onap/so/client/orchestration/SDNCNetworkResources.java
@@ -20,92 +20,81 @@
package org.onap.so.client.orchestration;
+import org.onap.sdnc.northbound.client.model.GenericResourceApiNetworkOperationInformation;
+import org.onap.sdnc.northbound.client.model.GenericResourceApiRequestActionEnumeration;
import org.onap.so.bpmn.servicedecomposition.bbobjects.CloudRegion;
import org.onap.so.bpmn.servicedecomposition.bbobjects.Customer;
import org.onap.so.bpmn.servicedecomposition.bbobjects.L3Network;
import org.onap.so.bpmn.servicedecomposition.bbobjects.ServiceInstance;
import org.onap.so.bpmn.servicedecomposition.generalobjects.RequestContext;
-import org.onap.so.client.exception.BadResponseException;
-import org.onap.so.client.exception.MapperException;
-import org.onap.so.client.sdnc.SDNCClient;
import org.onap.so.client.sdnc.beans.SDNCSvcAction;
import org.onap.so.client.sdnc.beans.SDNCSvcOperation;
-import org.onap.so.client.sdnc.endpoint.SDNCTopology;
import org.onap.so.client.sdnc.mapper.NetworkTopologyOperationRequestMapper;
import org.onap.so.logger.MsoLogger;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Component;
-import org.onap.sdnc.northbound.client.model.GenericResourceApiNetworkOperationInformation;
-import org.onap.sdnc.northbound.client.model.GenericResourceApiRequestActionEnumeration;
-
@Component
public class SDNCNetworkResources {
- private static final MsoLogger msoLogger = MsoLogger.getMsoLogger(MsoLogger.Catalog.BPEL, SDNCNetworkResources.class);
-
+ private static final MsoLogger msoLogger = MsoLogger.getMsoLogger(MsoLogger.Catalog.BPEL,
+ SDNCNetworkResources.class);
+
@Autowired
private NetworkTopologyOperationRequestMapper sdncRM;
-
- @Autowired
- private SDNCClient sdncClient;
- public String assignNetwork(L3Network network, ServiceInstance serviceInstance, Customer customer,
- RequestContext requestContext, CloudRegion cloudRegion)
- throws MapperException, BadResponseException {
-
- GenericResourceApiNetworkOperationInformation sdncReq = sdncRM.reqMapper(SDNCSvcOperation.NETWORK_TOPOLOGY_OPERATION,
- SDNCSvcAction.ASSIGN, GenericResourceApiRequestActionEnumeration.CREATENETWORKINSTANCE, network, serviceInstance, customer, requestContext, cloudRegion);
- return sdncClient.post(sdncReq, SDNCTopology.NETWORK);
+ public GenericResourceApiNetworkOperationInformation assignNetwork(L3Network network,
+ ServiceInstance serviceInstance, Customer customer, RequestContext requestContext,
+ CloudRegion cloudRegion) {
+ return sdncRM.reqMapper(SDNCSvcOperation.NETWORK_TOPOLOGY_OPERATION, SDNCSvcAction.ASSIGN,
+ GenericResourceApiRequestActionEnumeration.CREATENETWORKINSTANCE, network, serviceInstance, customer,
+ requestContext, cloudRegion);
}
-
- public String rollbackAssignNetwork(L3Network network, ServiceInstance serviceInstance, Customer customer,
- RequestContext requestContext, CloudRegion cloudRegion)
- throws MapperException, BadResponseException {
-
- GenericResourceApiNetworkOperationInformation sdncReq = sdncRM.reqMapper(SDNCSvcOperation.NETWORK_TOPOLOGY_OPERATION,
- SDNCSvcAction.UNASSIGN, GenericResourceApiRequestActionEnumeration.DELETENETWORKINSTANCE, network, serviceInstance, customer, requestContext, cloudRegion);
- return sdncClient.post(sdncReq, SDNCTopology.NETWORK);
+
+ public GenericResourceApiNetworkOperationInformation rollbackAssignNetwork(L3Network network,
+ ServiceInstance serviceInstance, Customer customer, RequestContext requestContext,
+ CloudRegion cloudRegion) {
+ return sdncRM.reqMapper(SDNCSvcOperation.NETWORK_TOPOLOGY_OPERATION, SDNCSvcAction.UNASSIGN,
+ GenericResourceApiRequestActionEnumeration.DELETENETWORKINSTANCE, network, serviceInstance, customer,
+ requestContext, cloudRegion);
}
- public String activateNetwork(L3Network network, ServiceInstance serviceInstance, Customer customer,
- RequestContext requestContext, CloudRegion cloudRegion)
- throws MapperException, BadResponseException {
-
- GenericResourceApiNetworkOperationInformation sdncReq = sdncRM.reqMapper(SDNCSvcOperation.NETWORK_TOPOLOGY_OPERATION,
- SDNCSvcAction.ACTIVATE, GenericResourceApiRequestActionEnumeration.CREATENETWORKINSTANCE, network, serviceInstance, customer, requestContext, cloudRegion);
- return sdncClient.post(sdncReq, SDNCTopology.NETWORK);
+ public GenericResourceApiNetworkOperationInformation activateNetwork(L3Network network,
+ ServiceInstance serviceInstance, Customer customer, RequestContext requestContext,
+ CloudRegion cloudRegion) {
+ return sdncRM.reqMapper(SDNCSvcOperation.NETWORK_TOPOLOGY_OPERATION, SDNCSvcAction.ACTIVATE,
+ GenericResourceApiRequestActionEnumeration.CREATENETWORKINSTANCE, network, serviceInstance, customer,
+ requestContext, cloudRegion);
}
-
- public String deactivateNetwork(L3Network network, ServiceInstance serviceInstance, Customer customer, RequestContext requestContext, CloudRegion cloudRegion) throws MapperException, BadResponseException {
- GenericResourceApiNetworkOperationInformation sdncReq = sdncRM.reqMapper(SDNCSvcOperation.NETWORK_TOPOLOGY_OPERATION,
- SDNCSvcAction.DEACTIVATE, GenericResourceApiRequestActionEnumeration.DELETENETWORKINSTANCE, network, serviceInstance, customer, requestContext, cloudRegion);
- return sdncClient.post(sdncReq, SDNCTopology.NETWORK);
+
+ public GenericResourceApiNetworkOperationInformation deactivateNetwork(L3Network network,
+ ServiceInstance serviceInstance, Customer customer, RequestContext requestContext,
+ CloudRegion cloudRegion) {
+ return sdncRM.reqMapper(SDNCSvcOperation.NETWORK_TOPOLOGY_OPERATION, SDNCSvcAction.DEACTIVATE,
+ GenericResourceApiRequestActionEnumeration.DELETENETWORKINSTANCE, network, serviceInstance, customer,
+ requestContext, cloudRegion);
}
- public String deleteNetwork(L3Network network, ServiceInstance serviceInstance, Customer customer,
- RequestContext requestContext, CloudRegion cloudRegion)
- throws MapperException, BadResponseException {
-
- GenericResourceApiNetworkOperationInformation sdncReq = sdncRM.reqMapper(SDNCSvcOperation.NETWORK_TOPOLOGY_OPERATION,
- SDNCSvcAction.DELETE, GenericResourceApiRequestActionEnumeration.DELETENETWORKINSTANCE, network, serviceInstance, customer, requestContext, cloudRegion);
- return sdncClient.post(sdncReq, SDNCTopology.NETWORK);
+ public GenericResourceApiNetworkOperationInformation deleteNetwork(L3Network network,
+ ServiceInstance serviceInstance, Customer customer, RequestContext requestContext,
+ CloudRegion cloudRegion) {
+ return sdncRM.reqMapper(SDNCSvcOperation.NETWORK_TOPOLOGY_OPERATION, SDNCSvcAction.DELETE,
+ GenericResourceApiRequestActionEnumeration.DELETENETWORKINSTANCE, network, serviceInstance, customer,
+ requestContext, cloudRegion);
}
-
- public String changeAssignNetwork(L3Network network, ServiceInstance serviceInstance, Customer customer,
- RequestContext requestContext, CloudRegion cloudRegion)
- throws MapperException, BadResponseException {
-
- GenericResourceApiNetworkOperationInformation sdncReq = sdncRM.reqMapper(SDNCSvcOperation.NETWORK_TOPOLOGY_OPERATION, SDNCSvcAction.CHANGE_ASSIGN, GenericResourceApiRequestActionEnumeration.CREATENETWORKINSTANCE, network, serviceInstance, customer, requestContext, cloudRegion);
- return sdncClient.post(sdncReq, SDNCTopology.NETWORK);
+
+ public GenericResourceApiNetworkOperationInformation changeAssignNetwork(L3Network network,
+ ServiceInstance serviceInstance, Customer customer, RequestContext requestContext,
+ CloudRegion cloudRegion) {
+ return sdncRM.reqMapper(SDNCSvcOperation.NETWORK_TOPOLOGY_OPERATION, SDNCSvcAction.CHANGE_ASSIGN,
+ GenericResourceApiRequestActionEnumeration.CREATENETWORKINSTANCE, network, serviceInstance, customer,
+ requestContext, cloudRegion);
}
- public String unassignNetwork(L3Network network, ServiceInstance serviceInstance, Customer customer,
- RequestContext requestContext, CloudRegion cloudRegion)
- throws MapperException, BadResponseException {
-
- GenericResourceApiNetworkOperationInformation sdncReq = sdncRM.reqMapper(SDNCSvcOperation.NETWORK_TOPOLOGY_OPERATION,
- SDNCSvcAction.UNASSIGN, GenericResourceApiRequestActionEnumeration.DELETENETWORKINSTANCE, network, serviceInstance, customer, requestContext, cloudRegion);
- return sdncClient.post(sdncReq, SDNCTopology.NETWORK);
- }
-
+ public GenericResourceApiNetworkOperationInformation unassignNetwork(L3Network network,
+ ServiceInstance serviceInstance, Customer customer, RequestContext requestContext,
+ CloudRegion cloudRegion) {
+ return sdncRM.reqMapper(SDNCSvcOperation.NETWORK_TOPOLOGY_OPERATION, SDNCSvcAction.UNASSIGN,
+ GenericResourceApiRequestActionEnumeration.DELETENETWORKINSTANCE, network, serviceInstance, customer,
+ requestContext, cloudRegion);
+ }
}
diff --git a/bpmn/so-bpmn-tasks/src/main/java/org/onap/so/client/orchestration/SDNCServiceInstanceResources.java b/bpmn/so-bpmn-tasks/src/main/java/org/onap/so/client/orchestration/SDNCServiceInstanceResources.java
index ad9e201862..a4c9b8fe05 100644
--- a/bpmn/so-bpmn-tasks/src/main/java/org/onap/so/client/orchestration/SDNCServiceInstanceResources.java
+++ b/bpmn/so-bpmn-tasks/src/main/java/org/onap/so/client/orchestration/SDNCServiceInstanceResources.java
@@ -20,37 +20,28 @@
package org.onap.so.client.orchestration;
+import org.onap.sdnc.northbound.client.model.GenericResourceApiRequestActionEnumeration;
+import org.onap.sdnc.northbound.client.model.GenericResourceApiServiceOperationInformation;
import org.onap.so.bpmn.servicedecomposition.bbobjects.Customer;
import org.onap.so.bpmn.servicedecomposition.bbobjects.ServiceInstance;
import org.onap.so.bpmn.servicedecomposition.generalobjects.RequestContext;
import org.onap.so.client.exception.BadResponseException;
import org.onap.so.client.exception.MapperException;
-import org.onap.so.client.sdnc.SDNCClient;
import org.onap.so.client.sdnc.beans.SDNCSvcAction;
import org.onap.so.client.sdnc.beans.SDNCSvcOperation;
-import org.onap.so.client.sdnc.endpoint.SDNCTopology;
import org.onap.so.client.sdnc.mapper.ServiceTopologyOperationMapper;
-import org.onap.so.logger.MsoLogger;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Component;
-import org.onap.sdnc.northbound.client.model.GenericResourceApiRequestActionEnumeration;
-import org.onap.sdnc.northbound.client.model.GenericResourceApiServiceOperationInformation;
-
@Component
public class SDNCServiceInstanceResources {
- private static final MsoLogger msoLogger = MsoLogger.getMsoLogger(MsoLogger.Catalog.BPEL,
- SDNCServiceInstanceResources.class);
-
@Autowired
private ServiceTopologyOperationMapper sdncRM;
-
- @Autowired
- private SDNCClient sdncClient;
-
+
/**
- * SDNC call to perform Service Topology Assign for ServiceInsatnce
+ * SDNC call to perform Service Topology Assign for ServiceInsatnce
+ *
* @param serviceInstance
* @param customer
* @param requestContext
@@ -58,16 +49,16 @@ public class SDNCServiceInstanceResources {
* @throws BadResponseException
* @return the response as a String
*/
- public String assignServiceInstance(ServiceInstance serviceInstance, Customer customer,
- RequestContext requestContext) throws MapperException, BadResponseException {
- GenericResourceApiServiceOperationInformation sdncReq = sdncRM.reqMapper(
- SDNCSvcOperation.SERVICE_TOPOLOGY_OPERATION, SDNCSvcAction.ASSIGN,GenericResourceApiRequestActionEnumeration.CREATESERVICEINSTANCE, serviceInstance, customer,
+ public GenericResourceApiServiceOperationInformation assignServiceInstance(ServiceInstance serviceInstance,
+ Customer customer, RequestContext requestContext) {
+ return sdncRM.reqMapper(SDNCSvcOperation.SERVICE_TOPOLOGY_OPERATION, SDNCSvcAction.ASSIGN,
+ GenericResourceApiRequestActionEnumeration.CREATESERVICEINSTANCE, serviceInstance, customer,
requestContext);
- return sdncClient.post(sdncReq, SDNCTopology.SERVICE);
}
/**
- * SDNC call to perform Service Topology Delete for ServiceInsatnce
+ * SDNC call to perform Service Topology Delete for ServiceInsatnce
+ *
* @param serviceInstance
* @param customer
* @param requestContext
@@ -75,24 +66,23 @@ public class SDNCServiceInstanceResources {
* @throws BadResponseException
* @return the response as a String
*/
- public String deleteServiceInstance(ServiceInstance serviceInstance, Customer customer,
- RequestContext requestContext) throws MapperException, BadResponseException {
- GenericResourceApiServiceOperationInformation sdncReq = sdncRM.reqMapper(
- SDNCSvcOperation.SERVICE_TOPOLOGY_OPERATION, SDNCSvcAction.DELETE, GenericResourceApiRequestActionEnumeration.DELETESERVICEINSTANCE, serviceInstance, customer,
+ public GenericResourceApiServiceOperationInformation deleteServiceInstance(ServiceInstance serviceInstance,
+ Customer customer, RequestContext requestContext) {
+ return sdncRM.reqMapper(SDNCSvcOperation.SERVICE_TOPOLOGY_OPERATION, SDNCSvcAction.DELETE,
+ GenericResourceApiRequestActionEnumeration.DELETESERVICEINSTANCE, serviceInstance, customer,
requestContext);
- return sdncClient.post(sdncReq, SDNCTopology.SERVICE);
}
-
- public String unassignServiceInstance(ServiceInstance serviceInstance, Customer customer,
- RequestContext requestContext) throws MapperException, BadResponseException {
- GenericResourceApiServiceOperationInformation sdncReq = sdncRM.reqMapper(
- SDNCSvcOperation.SERVICE_TOPOLOGY_OPERATION, SDNCSvcAction.DELETE, GenericResourceApiRequestActionEnumeration.DELETESERVICEINSTANCE, serviceInstance, customer,
+
+ public GenericResourceApiServiceOperationInformation unassignServiceInstance(ServiceInstance serviceInstance,
+ Customer customer, RequestContext requestContext) {
+ return sdncRM.reqMapper(SDNCSvcOperation.SERVICE_TOPOLOGY_OPERATION, SDNCSvcAction.DELETE,
+ GenericResourceApiRequestActionEnumeration.DELETESERVICEINSTANCE, serviceInstance, customer,
requestContext);
- return sdncClient.post(sdncReq, SDNCTopology.SERVICE);
}
-
+
/**
* SDNC call to perform Service Topology Deactivate for ServiceInstance
+ *
* @param serviceInstance
* @param customer
* @param requestContext
@@ -100,16 +90,17 @@ public class SDNCServiceInstanceResources {
* @throws BadResponseException
* @return the response as a String
*/
- public String deactivateServiceInstance(ServiceInstance serviceInstance, Customer customer,
- RequestContext requestContext) throws MapperException, BadResponseException {
- GenericResourceApiServiceOperationInformation sdncReq = sdncRM.reqMapper(
- SDNCSvcOperation.SERVICE_TOPOLOGY_OPERATION, SDNCSvcAction.DEACTIVATE, GenericResourceApiRequestActionEnumeration.DELETESERVICEINSTANCE, serviceInstance, customer,
+ public GenericResourceApiServiceOperationInformation deactivateServiceInstance(ServiceInstance serviceInstance,
+ Customer customer, RequestContext requestContext) {
+ return sdncRM.reqMapper(SDNCSvcOperation.SERVICE_TOPOLOGY_OPERATION, SDNCSvcAction.DEACTIVATE,
+ GenericResourceApiRequestActionEnumeration.DELETESERVICEINSTANCE, serviceInstance, customer,
requestContext);
- return sdncClient.post(sdncReq, SDNCTopology.SERVICE);
}
-
+
/**
- * SDNC call to perform Service Topology Change Assign for the ServiceInstance
+ * SDNC call to perform Service Topology Change Assign for the
+ * ServiceInstance
+ *
* @param serviceInstance
* @param customer
* @param requestContext
@@ -117,8 +108,10 @@ public class SDNCServiceInstanceResources {
* @throws BadResponseException
* @return the response as a String
*/
- public String changeModelServiceInstance(ServiceInstance serviceInstance, Customer customer, RequestContext requestContext) throws MapperException, BadResponseException {
- GenericResourceApiServiceOperationInformation sdncReq = sdncRM.reqMapper(SDNCSvcOperation.SERVICE_TOPOLOGY_OPERATION, SDNCSvcAction.CHANGE_ASSIGN, GenericResourceApiRequestActionEnumeration.CREATESERVICEINSTANCE, serviceInstance, customer, requestContext);
- return sdncClient.post(sdncReq, SDNCTopology.SERVICE);
+ public GenericResourceApiServiceOperationInformation changeModelServiceInstance(ServiceInstance serviceInstance,
+ Customer customer, RequestContext requestContext) {
+ return sdncRM.reqMapper(SDNCSvcOperation.SERVICE_TOPOLOGY_OPERATION, SDNCSvcAction.CHANGE_ASSIGN,
+ GenericResourceApiRequestActionEnumeration.CREATESERVICEINSTANCE, serviceInstance, customer,
+ requestContext);
}
}
diff --git a/bpmn/so-bpmn-tasks/src/main/java/org/onap/so/client/orchestration/SDNCVfModuleResources.java b/bpmn/so-bpmn-tasks/src/main/java/org/onap/so/client/orchestration/SDNCVfModuleResources.java
index 3c192e1b1c..e7f0a40d2a 100644
--- a/bpmn/so-bpmn-tasks/src/main/java/org/onap/so/client/orchestration/SDNCVfModuleResources.java
+++ b/bpmn/so-bpmn-tasks/src/main/java/org/onap/so/client/orchestration/SDNCVfModuleResources.java
@@ -33,7 +33,6 @@ import org.onap.so.client.exception.MapperException;
import org.onap.so.client.sdnc.SDNCClient;
import org.onap.so.client.sdnc.beans.SDNCSvcAction;
import org.onap.so.client.sdnc.beans.SDNCSvcOperation;
-import org.onap.so.client.sdnc.endpoint.SDNCTopology;
import org.onap.so.client.sdnc.mapper.VfModuleTopologyOperationRequestMapper;
import org.onap.so.logger.MsoLogger;
import org.springframework.beans.factory.annotation.Autowired;
@@ -41,59 +40,51 @@ import org.springframework.stereotype.Component;
@Component
public class SDNCVfModuleResources {
- private static final MsoLogger msoLogger = MsoLogger.getMsoLogger(MsoLogger.Catalog.BPEL, SDNCVfModuleResources.class);
-
+ private static final MsoLogger msoLogger = MsoLogger.getMsoLogger(MsoLogger.Catalog.BPEL,
+ SDNCVfModuleResources.class);
+
@Autowired
private VfModuleTopologyOperationRequestMapper sdncRM;
-
+
@Autowired
private SDNCClient sdncClient;
-
- public String assignVfModule(VfModule vfModule, VolumeGroup volumeGroup,GenericVnf vnf, ServiceInstance serviceInstance, Customer customer,
- CloudRegion cloudRegion, RequestContext requestContext)
- throws MapperException, BadResponseException {
-
- GenericResourceApiVfModuleOperationInformation sdncReq = sdncRM.reqMapper(SDNCSvcOperation.VF_MODULE_TOPOLOGY_OPERATION,
- SDNCSvcAction.ASSIGN, vfModule, volumeGroup, vnf, serviceInstance, customer, cloudRegion, requestContext, null);
- return sdncClient.post(sdncReq, SDNCTopology.VFMODULE);
- }
- public String unassignVfModule(VfModule vfModule, GenericVnf vnf, ServiceInstance serviceInstance)
- throws MapperException, BadResponseException {
-
- GenericResourceApiVfModuleOperationInformation sdncReq = sdncRM.reqMapper(SDNCSvcOperation.VF_MODULE_TOPOLOGY_OPERATION,
- SDNCSvcAction.UNASSIGN, vfModule, null, vnf, serviceInstance, null, null, null, null);
- return sdncClient.post(sdncReq, SDNCTopology.VFMODULE);
+ public GenericResourceApiVfModuleOperationInformation assignVfModule(VfModule vfModule, VolumeGroup volumeGroup,
+ GenericVnf vnf, ServiceInstance serviceInstance, Customer customer, CloudRegion cloudRegion,
+ RequestContext requestContext) throws MapperException {
+ return sdncRM.reqMapper(SDNCSvcOperation.VF_MODULE_TOPOLOGY_OPERATION, SDNCSvcAction.ASSIGN, vfModule,
+ volumeGroup, vnf, serviceInstance, customer, cloudRegion, requestContext, null);
}
- public String deactivateVfModule(VfModule vfModule, GenericVnf vnf, ServiceInstance serviceInstance,
- Customer customer, CloudRegion cloudRegion, RequestContext requestContext)
- throws MapperException, BadResponseException {
+ public GenericResourceApiVfModuleOperationInformation unassignVfModule(VfModule vfModule, GenericVnf vnf,
+ ServiceInstance serviceInstance) throws MapperException {
+ return sdncRM.reqMapper(SDNCSvcOperation.VF_MODULE_TOPOLOGY_OPERATION, SDNCSvcAction.UNASSIGN, vfModule, null,
+ vnf, serviceInstance, null, null, null, null);
+ }
- GenericResourceApiVfModuleOperationInformation sdncReq = sdncRM.reqMapper(
- SDNCSvcOperation.VF_MODULE_TOPOLOGY_OPERATION, SDNCSvcAction.DEACTIVATE, vfModule, null, vnf, serviceInstance,
- customer, cloudRegion, requestContext, null);
- return sdncClient.post(sdncReq, SDNCTopology.VFMODULE);
+ public GenericResourceApiVfModuleOperationInformation deactivateVfModule(VfModule vfModule, GenericVnf vnf,
+ ServiceInstance serviceInstance, Customer customer, CloudRegion cloudRegion, RequestContext requestContext)
+ throws MapperException {
+ return sdncRM.reqMapper(SDNCSvcOperation.VF_MODULE_TOPOLOGY_OPERATION, SDNCSvcAction.DEACTIVATE, vfModule, null,
+ vnf, serviceInstance, customer, cloudRegion, requestContext, null);
}
-
- public String queryVfModule(VfModule vfModule)
- throws MapperException, BadResponseException {
-
- String objectPath = vfModule.getSelflink();
+
+ public String queryVfModule(VfModule vfModule) throws MapperException, BadResponseException {
+ String objectPath = vfModule.getSelflink();
return sdncClient.get(objectPath);
}
-
- public String activateVfModule(VfModule vfModule, GenericVnf vnf, ServiceInstance serviceInstance, Customer customer,
- CloudRegion cloudRegion, RequestContext requestContext)
- throws MapperException, BadResponseException {
-
- GenericResourceApiVfModuleOperationInformation sdncReq = sdncRM.reqMapper(SDNCSvcOperation.VF_MODULE_TOPOLOGY_OPERATION,
- SDNCSvcAction.ACTIVATE, vfModule, null, vnf, serviceInstance, customer, cloudRegion, requestContext, null);
- return sdncClient.post(sdncReq, SDNCTopology.VFMODULE);
+
+ public GenericResourceApiVfModuleOperationInformation activateVfModule(VfModule vfModule, GenericVnf vnf,
+ ServiceInstance serviceInstance, Customer customer, CloudRegion cloudRegion, RequestContext requestContext)
+ throws MapperException {
+ return sdncRM.reqMapper(SDNCSvcOperation.VF_MODULE_TOPOLOGY_OPERATION, SDNCSvcAction.ACTIVATE, vfModule, null,
+ vnf, serviceInstance, customer, cloudRegion, requestContext, null);
}
-
- public String changeAssignVfModule(VfModule vfModule, GenericVnf vnf, ServiceInstance serviceInstance, Customer customer, CloudRegion cloudRegion, RequestContext requestContext) throws MapperException, BadResponseException {
- GenericResourceApiVfModuleOperationInformation sdncReq = sdncRM.reqMapper(SDNCSvcOperation.VF_MODULE_TOPOLOGY_OPERATION, SDNCSvcAction.CHANGE_ASSIGN, vfModule, null, vnf, serviceInstance, customer, cloudRegion, requestContext, null);
- return sdncClient.post(sdncReq, SDNCTopology.VFMODULE);
+
+ public GenericResourceApiVfModuleOperationInformation changeAssignVfModule(VfModule vfModule, GenericVnf vnf,
+ ServiceInstance serviceInstance, Customer customer, CloudRegion cloudRegion, RequestContext requestContext)
+ throws MapperException {
+ return sdncRM.reqMapper(SDNCSvcOperation.VF_MODULE_TOPOLOGY_OPERATION, SDNCSvcAction.CHANGE_ASSIGN, vfModule,
+ null, vnf, serviceInstance, customer, cloudRegion, requestContext, null);
}
}
diff --git a/bpmn/so-bpmn-tasks/src/main/java/org/onap/so/client/orchestration/SDNCVnfResources.java b/bpmn/so-bpmn-tasks/src/main/java/org/onap/so/client/orchestration/SDNCVnfResources.java
index b30fc932c0..e5194e3e37 100644
--- a/bpmn/so-bpmn-tasks/src/main/java/org/onap/so/client/orchestration/SDNCVnfResources.java
+++ b/bpmn/so-bpmn-tasks/src/main/java/org/onap/so/client/orchestration/SDNCVnfResources.java
@@ -32,7 +32,6 @@ import org.onap.so.client.exception.MapperException;
import org.onap.so.client.sdnc.SDNCClient;
import org.onap.so.client.sdnc.beans.SDNCSvcAction;
import org.onap.so.client.sdnc.beans.SDNCSvcOperation;
-import org.onap.so.client.sdnc.endpoint.SDNCTopology;
import org.onap.so.client.sdnc.mapper.VnfTopologyOperationRequestMapper;
import org.onap.so.logger.MsoLogger;
import org.springframework.beans.factory.annotation.Autowired;
@@ -49,52 +48,41 @@ public class SDNCVnfResources {
private SDNCClient sdncClient;
public GenericResourceApiVnfOperationInformation assignVnf(GenericVnf vnf, ServiceInstance serviceInstance, Customer customer,
- CloudRegion cloudRegion, RequestContext requestContext, boolean homing)
- throws MapperException, BadResponseException {
+ CloudRegion cloudRegion, RequestContext requestContext, boolean homing) {
return sdncRM.reqMapper(SDNCSvcOperation.VNF_TOPOLOGY_OPERATION,
SDNCSvcAction.ASSIGN,GenericResourceApiRequestActionEnumeration.CREATEVNFINSTANCE, vnf, serviceInstance, customer, cloudRegion, requestContext, homing);
}
- public String activateVnf(GenericVnf vnf, ServiceInstance serviceInstance, Customer customer,
- CloudRegion cloudRegion, RequestContext requestContext)
- throws MapperException, BadResponseException {
- GenericResourceApiVnfOperationInformation sdncReq = sdncRM.reqMapper(SDNCSvcOperation.VNF_TOPOLOGY_OPERATION,
+ public GenericResourceApiVnfOperationInformation activateVnf(GenericVnf vnf, ServiceInstance serviceInstance, Customer customer,
+ CloudRegion cloudRegion, RequestContext requestContext) {
+ return sdncRM.reqMapper(SDNCSvcOperation.VNF_TOPOLOGY_OPERATION,
SDNCSvcAction.ACTIVATE,GenericResourceApiRequestActionEnumeration.CREATEVNFINSTANCE, vnf, serviceInstance, customer,cloudRegion, requestContext, false);
- return sdncClient.post(sdncReq, SDNCTopology.VNF);
}
- public String deactivateVnf(GenericVnf vnf, ServiceInstance serviceInstance, Customer customer,
- CloudRegion cloudRegion, RequestContext requestContext)
- throws MapperException, BadResponseException {
- GenericResourceApiVnfOperationInformation sdncReq = sdncRM.reqMapper(SDNCSvcOperation.VNF_TOPOLOGY_OPERATION,
+ public GenericResourceApiVnfOperationInformation deactivateVnf(GenericVnf vnf, ServiceInstance serviceInstance, Customer customer,
+ CloudRegion cloudRegion, RequestContext requestContext) {
+ return sdncRM.reqMapper(SDNCSvcOperation.VNF_TOPOLOGY_OPERATION,
SDNCSvcAction.DEACTIVATE,GenericResourceApiRequestActionEnumeration.DELETEVNFINSTANCE, vnf, serviceInstance, customer,cloudRegion, requestContext, false);
- return sdncClient.post(sdncReq, SDNCTopology.VNF);
}
- public String unassignVnf(GenericVnf vnf, ServiceInstance serviceInstance, Customer customer,
- CloudRegion cloudRegion, RequestContext requestContext)
- throws MapperException, BadResponseException {
- GenericResourceApiVnfOperationInformation sdncReq = sdncRM.reqMapper(SDNCSvcOperation.VNF_TOPOLOGY_OPERATION,
+ public GenericResourceApiVnfOperationInformation unassignVnf(GenericVnf vnf, ServiceInstance serviceInstance, Customer customer,
+ CloudRegion cloudRegion, RequestContext requestContext) {
+ return sdncRM.reqMapper(SDNCSvcOperation.VNF_TOPOLOGY_OPERATION,
SDNCSvcAction.UNASSIGN,GenericResourceApiRequestActionEnumeration.DELETEVNFINSTANCE, vnf, serviceInstance, customer, cloudRegion, requestContext, false);
- return sdncClient.post(sdncReq, SDNCTopology.VNF);
}
- public String deleteVnf(GenericVnf vnf, ServiceInstance serviceInstance, Customer customer,
- CloudRegion cloudRegion, RequestContext requestContext)
- throws MapperException, BadResponseException {
- GenericResourceApiVnfOperationInformation sdncReq = sdncRM.reqMapper(SDNCSvcOperation.VNF_TOPOLOGY_OPERATION,
+ public GenericResourceApiVnfOperationInformation deleteVnf(GenericVnf vnf, ServiceInstance serviceInstance, Customer customer,
+ CloudRegion cloudRegion, RequestContext requestContext) {
+ return sdncRM.reqMapper(SDNCSvcOperation.VNF_TOPOLOGY_OPERATION,
SDNCSvcAction.DEACTIVATE, GenericResourceApiRequestActionEnumeration.DELETEVNFINSTANCE,vnf, serviceInstance, customer, cloudRegion, requestContext, false);
- return sdncClient.post(sdncReq, SDNCTopology.VNF);
}
- public String changeModelVnf(GenericVnf vnf, ServiceInstance serviceInstance, Customer customer,
- CloudRegion cloudRegion, RequestContext requestContext)
- throws MapperException, BadResponseException {
- GenericResourceApiVnfOperationInformation sdncReq = sdncRM.reqMapper(SDNCSvcOperation.VNF_TOPOLOGY_OPERATION,
+ public GenericResourceApiVnfOperationInformation changeModelVnf(GenericVnf vnf, ServiceInstance serviceInstance, Customer customer,
+ CloudRegion cloudRegion, RequestContext requestContext) {
+ return sdncRM.reqMapper(SDNCSvcOperation.VNF_TOPOLOGY_OPERATION,
SDNCSvcAction.CHANGE_ASSIGN,GenericResourceApiRequestActionEnumeration.CREATEVNFINSTANCE, vnf, serviceInstance, customer, cloudRegion, requestContext, false);
- return sdncClient.post(sdncReq, SDNCTopology.VNF);
}
public String queryVnf(GenericVnf vnf) throws MapperException, BadResponseException {
diff --git a/bpmn/so-bpmn-tasks/src/test/java/org/onap/so/bpmn/infrastructure/sdnc/tasks/SDNCActivateTaskTest.java b/bpmn/so-bpmn-tasks/src/test/java/org/onap/so/bpmn/infrastructure/sdnc/tasks/SDNCActivateTaskTest.java
index a556346252..65e7d249c5 100644
--- a/bpmn/so-bpmn-tasks/src/test/java/org/onap/so/bpmn/infrastructure/sdnc/tasks/SDNCActivateTaskTest.java
+++ b/bpmn/so-bpmn-tasks/src/test/java/org/onap/so/bpmn/infrastructure/sdnc/tasks/SDNCActivateTaskTest.java
@@ -20,6 +20,7 @@
package org.onap.so.bpmn.infrastructure.sdnc.tasks;
+import static org.junit.Assert.assertEquals;
import static org.mockito.ArgumentMatchers.any;
import static org.mockito.ArgumentMatchers.eq;
import static org.mockito.ArgumentMatchers.isA;
@@ -34,6 +35,9 @@ import org.junit.Before;
import org.junit.Test;
import org.mockito.ArgumentMatchers;
import org.mockito.InjectMocks;
+import org.onap.sdnc.northbound.client.model.GenericResourceApiNetworkOperationInformation;
+import org.onap.sdnc.northbound.client.model.GenericResourceApiVfModuleOperationInformation;
+import org.onap.sdnc.northbound.client.model.GenericResourceApiVnfOperationInformation;
import org.onap.so.bpmn.BaseTaskTest;
import org.onap.so.bpmn.common.BuildingBlockExecution;
import org.onap.so.bpmn.servicedecomposition.bbobjects.CloudRegion;
@@ -45,8 +49,8 @@ import org.onap.so.bpmn.servicedecomposition.bbobjects.VfModule;
import org.onap.so.bpmn.servicedecomposition.entities.ResourceKey;
import org.onap.so.bpmn.servicedecomposition.generalobjects.RequestContext;
import org.onap.so.client.exception.BBObjectNotFoundException;
-import org.springframework.beans.factory.annotation.Autowired;
-
+import org.onap.so.client.sdnc.beans.SDNCRequest;
+import org.onap.so.client.sdnc.endpoint.SDNCTopology;
public class SDNCActivateTaskTest extends BaseTaskTest{
@@ -83,47 +87,48 @@ public class SDNCActivateTaskTest extends BaseTaskTest{
@Test
public void activateVnfTest() throws Exception {
- doReturn("success").when(sdncVnfResources).activateVnf(genericVnf,serviceInstance, customer, cloudRegion,requestContext);
+ doReturn(new GenericResourceApiVnfOperationInformation()).when(sdncVnfResources).activateVnf(genericVnf,serviceInstance, customer, cloudRegion,requestContext);
sdncActivateTasks.activateVnf(execution);
verify(sdncVnfResources, times(1)).activateVnf(genericVnf,serviceInstance, customer,cloudRegion,requestContext);
+ SDNCRequest sdncRequest = execution.getVariable("SDNCRequest");
+ assertEquals(SDNCTopology.VNF,sdncRequest.getTopology());
}
@Test
public void activateVnfTestException() throws Exception {
expectedException.expect(BpmnError.class);
-
doThrow(RuntimeException.class).when(sdncVnfResources).activateVnf(genericVnf,serviceInstance, customer,cloudRegion,requestContext);
sdncActivateTasks.activateVnf(execution);
}
@Test
public void activateNetworkTest() throws Exception {
- doReturn("response").when(sdncNetworkResources).activateNetwork(isA(L3Network.class), isA(ServiceInstance.class), isA(Customer.class), isA(RequestContext.class), isA(CloudRegion.class));
+ doReturn(new GenericResourceApiNetworkOperationInformation()).when(sdncNetworkResources).activateNetwork(isA(L3Network.class), isA(ServiceInstance.class), isA(Customer.class), isA(RequestContext.class), isA(CloudRegion.class));
sdncActivateTasks.activateNetwork(execution);
verify(sdncNetworkResources, times(1)).activateNetwork(network, serviceInstance, customer, requestContext, cloudRegion);
+ SDNCRequest sdncRequest = execution.getVariable("SDNCRequest");
+ assertEquals(SDNCTopology.NETWORK,sdncRequest.getTopology());
}
@Test
public void activateNetworkExceptionTest() throws Exception {
expectedException.expect(BpmnError.class);
-
doThrow(RuntimeException.class).when(sdncNetworkResources).activateNetwork(isA(L3Network.class), isA(ServiceInstance.class), isA(Customer.class), isA(RequestContext.class), isA(CloudRegion.class));
sdncActivateTasks.activateNetwork(execution);
}
@Test
public void activateVfModuleTest() throws Exception {
- doReturn("success").when(sdncVfModuleResources).activateVfModule(vfModule, genericVnf, serviceInstance, customer, cloudRegion, requestContext);
-
+ doReturn(new GenericResourceApiVfModuleOperationInformation()).when(sdncVfModuleResources).activateVfModule(vfModule, genericVnf, serviceInstance, customer, cloudRegion, requestContext);
sdncActivateTasks.activateVfModule(execution);
-
verify(sdncVfModuleResources, times(1)).activateVfModule(vfModule, genericVnf, serviceInstance, customer, cloudRegion, requestContext);
+ SDNCRequest sdncRequest = execution.getVariable("SDNCRequest");
+ assertEquals(SDNCTopology.VFMODULE,sdncRequest.getTopology());
}
@Test
public void activateVfModuleTestException() throws Exception {
expectedException.expect(BpmnError.class);
-
doThrow(RuntimeException.class).when(sdncVfModuleResources).activateVfModule(vfModule, genericVnf, serviceInstance, customer, cloudRegion, requestContext);
sdncActivateTasks.activateVfModule(execution);
}
diff --git a/bpmn/so-bpmn-tasks/src/test/java/org/onap/so/bpmn/infrastructure/sdnc/tasks/SDNCAssignTasksTest.java b/bpmn/so-bpmn-tasks/src/test/java/org/onap/so/bpmn/infrastructure/sdnc/tasks/SDNCAssignTasksTest.java
index 24ae88b98c..d021df56e0 100644
--- a/bpmn/so-bpmn-tasks/src/test/java/org/onap/so/bpmn/infrastructure/sdnc/tasks/SDNCAssignTasksTest.java
+++ b/bpmn/so-bpmn-tasks/src/test/java/org/onap/so/bpmn/infrastructure/sdnc/tasks/SDNCAssignTasksTest.java
@@ -21,7 +21,6 @@
package org.onap.so.bpmn.infrastructure.sdnc.tasks;
import static org.junit.Assert.assertEquals;
-import static org.junit.Assert.assertTrue;
import static org.mockito.ArgumentMatchers.any;
import static org.mockito.ArgumentMatchers.eq;
import static org.mockito.Mockito.doReturn;
@@ -35,6 +34,9 @@ import org.junit.Before;
import org.junit.Test;
import org.mockito.ArgumentMatchers;
import org.mockito.InjectMocks;
+import org.onap.sdnc.northbound.client.model.GenericResourceApiNetworkOperationInformation;
+import org.onap.sdnc.northbound.client.model.GenericResourceApiServiceOperationInformation;
+import org.onap.sdnc.northbound.client.model.GenericResourceApiVfModuleOperationInformation;
import org.onap.sdnc.northbound.client.model.GenericResourceApiVnfOperationInformation;
import org.onap.so.bpmn.BaseTaskTest;
import org.onap.so.bpmn.common.BuildingBlockExecution;
@@ -87,30 +89,25 @@ public class SDNCAssignTasksTest extends BaseTaskTest{
@Test
public void assignServiceInstanceTest() throws Exception {
- doReturn("response").when(sdncServiceInstanceResources).assignServiceInstance(serviceInstance, customer, requestContext);
-
+ doReturn(new GenericResourceApiServiceOperationInformation()).when(sdncServiceInstanceResources).assignServiceInstance(serviceInstance, customer, requestContext);
sdncAssignTasks.assignServiceInstance(execution);
-
verify(sdncServiceInstanceResources, times(1)).assignServiceInstance(serviceInstance, customer, requestContext);
- assertTrue(execution.getVariable("SDNCResponse").equals("response"));
+ SDNCRequest sdncRequest = execution.getVariable("SDNCRequest");
+ assertEquals(SDNCTopology.SERVICE,sdncRequest.getTopology());
}
@Test
public void assignServiceInstanceExceptionTest() throws Exception {
expectedException.expect(BpmnError.class);
-
doThrow(RuntimeException.class).when(sdncServiceInstanceResources).assignServiceInstance(serviceInstance, customer, requestContext);
-
sdncAssignTasks.assignServiceInstance(execution);
}
@Test
public void assignVnfTest() throws Exception {
doReturn(new GenericResourceApiVnfOperationInformation()).when(sdncVnfResources).assignVnf(genericVnf, serviceInstance, customer, cloudRegion, requestContext, false);
-
execution.setVariable("generalBuildingBlock", gBBInput);
sdncAssignTasks.assignVnf(execution);
-
verify(sdncVnfResources, times(1)).assignVnf(genericVnf, serviceInstance,customer, cloudRegion, requestContext, false);
SDNCRequest sdncRequest = execution.getVariable("SDNCRequest");
assertEquals(SDNCTopology.VNF,sdncRequest.getTopology());
@@ -119,46 +116,39 @@ public class SDNCAssignTasksTest extends BaseTaskTest{
@Test
public void assignVnfExceptionTest() throws Exception {
expectedException.expect(BpmnError.class);
-
doThrow(RuntimeException.class).when(sdncVnfResources).assignVnf(genericVnf, serviceInstance, customer, cloudRegion, requestContext, false);
-
sdncAssignTasks.assignVnf(execution);
}
@Test
public void assignVfModuleTest() throws Exception {
- doReturn("response").when(sdncVfModuleResources).assignVfModule(vfModule, volumeGroup, genericVnf, serviceInstance, customer, cloudRegion, requestContext);
-
+ doReturn(new GenericResourceApiVfModuleOperationInformation()).when(sdncVfModuleResources).assignVfModule(vfModule, volumeGroup, genericVnf, serviceInstance, customer, cloudRegion, requestContext);
sdncAssignTasks.assignVfModule(execution);
-
verify(sdncVfModuleResources, times(1)).assignVfModule(vfModule, volumeGroup, genericVnf, serviceInstance, customer, cloudRegion, requestContext);
- assertTrue(execution.getVariable("SDNCAssignResponse_" + vfModule.getVfModuleId()).equals("response"));
+ SDNCRequest sdncRequest = execution.getVariable("SDNCRequest");
+ assertEquals(SDNCTopology.VFMODULE,sdncRequest.getTopology());
}
@Test
public void assignVfModuleExceptionTest() throws Exception {
expectedException.expect(BpmnError.class);
-
doThrow(RuntimeException.class).when(sdncVfModuleResources).assignVfModule(vfModule, volumeGroup, genericVnf, serviceInstance, customer, cloudRegion, requestContext);
-
sdncAssignTasks.assignVfModule(execution);
}
@Test
public void assignNetworkTest() throws Exception {
- doReturn("response").when(sdncNetworkResources).assignNetwork(network, serviceInstance, customer, requestContext, cloudRegion);
-
+ doReturn(new GenericResourceApiNetworkOperationInformation()).when(sdncNetworkResources).assignNetwork(network, serviceInstance, customer, requestContext, cloudRegion);
sdncAssignTasks.assignNetwork(execution);
-
verify(sdncNetworkResources, times(1)).assignNetwork(network, serviceInstance, customer, requestContext, cloudRegion);
+ SDNCRequest sdncRequest = execution.getVariable("SDNCRequest");
+ assertEquals(SDNCTopology.NETWORK,sdncRequest.getTopology());
}
@Test
public void assignNetworkExceptionTest() throws Exception {
expectedException.expect(BpmnError.class);
-
doThrow(RuntimeException.class).when(sdncNetworkResources).assignNetwork(network, serviceInstance, customer, requestContext, cloudRegion);
-
sdncAssignTasks.assignNetwork(execution);
}
}
diff --git a/bpmn/so-bpmn-tasks/src/test/java/org/onap/so/bpmn/infrastructure/sdnc/tasks/SDNCChangeAssignTasksTest.java b/bpmn/so-bpmn-tasks/src/test/java/org/onap/so/bpmn/infrastructure/sdnc/tasks/SDNCChangeAssignTasksTest.java
index 99c680d8bb..f01596c86f 100644
--- a/bpmn/so-bpmn-tasks/src/test/java/org/onap/so/bpmn/infrastructure/sdnc/tasks/SDNCChangeAssignTasksTest.java
+++ b/bpmn/so-bpmn-tasks/src/test/java/org/onap/so/bpmn/infrastructure/sdnc/tasks/SDNCChangeAssignTasksTest.java
@@ -20,7 +20,6 @@
package org.onap.so.bpmn.infrastructure.sdnc.tasks;
import static org.junit.Assert.assertEquals;
-import static org.junit.Assert.assertTrue;
import static org.mockito.ArgumentMatchers.any;
import static org.mockito.ArgumentMatchers.eq;
import static org.mockito.Mockito.doReturn;
@@ -34,6 +33,8 @@ import org.junit.Before;
import org.junit.Test;
import org.mockito.ArgumentMatchers;
import org.mockito.InjectMocks;
+import org.onap.sdnc.northbound.client.model.GenericResourceApiVfModuleOperationInformation;
+import org.onap.sdnc.northbound.client.model.GenericResourceApiVnfOperationInformation;
import org.onap.so.bpmn.BaseTaskTest;
import org.onap.so.bpmn.common.BuildingBlockExecution;
import org.onap.so.bpmn.servicedecomposition.bbobjects.CloudRegion;
@@ -44,7 +45,8 @@ import org.onap.so.bpmn.servicedecomposition.bbobjects.VfModule;
import org.onap.so.bpmn.servicedecomposition.entities.ResourceKey;
import org.onap.so.bpmn.servicedecomposition.generalobjects.RequestContext;
import org.onap.so.client.exception.BBObjectNotFoundException;
-import org.springframework.beans.factory.annotation.Autowired;
+import org.onap.so.client.sdnc.beans.SDNCRequest;
+import org.onap.so.client.sdnc.endpoint.SDNCTopology;
public class SDNCChangeAssignTasksTest extends BaseTaskTest{
@InjectMocks
@@ -74,15 +76,11 @@ public class SDNCChangeAssignTasksTest extends BaseTaskTest{
@Test
public void changeModelVnfTest() throws Exception {
- String response = "sdncChangeModelServiceInstance";
-
- doReturn(response).when(sdncServiceInstanceResources).changeModelServiceInstance(serviceInstance, customer, requestContext);
-
- sdncChangeAssignTasks.changeModelServiceInstance(execution);
-
- verify(sdncServiceInstanceResources, times(1)).changeModelServiceInstance(serviceInstance, customer, requestContext);
-
- assertEquals(response, execution.getVariable("SDNCChangeAssignTasks.changeModelServiceInstance.response"));
+ doReturn(new GenericResourceApiVnfOperationInformation()).when(sdncVnfResources).changeModelVnf(genericVnf, serviceInstance, customer, cloudRegion, requestContext);
+ sdncChangeAssignTasks.changeModelVnf(execution);
+ verify(sdncVnfResources, times(1)).changeModelVnf(genericVnf, serviceInstance, customer, cloudRegion, requestContext);
+ SDNCRequest sdncRequest = execution.getVariable("SDNCRequest");
+ assertEquals(SDNCTopology.VNF,sdncRequest.getTopology());
}
@Test
@@ -94,13 +92,11 @@ public class SDNCChangeAssignTasksTest extends BaseTaskTest{
@Test
public void changeAssignModelVfModuleTest() throws Exception {
- String response = "response";
- doReturn(response).when(sdncVfModuleResources).changeAssignVfModule(vfModule, genericVnf, serviceInstance, customer, cloudRegion, requestContext);
-
+ doReturn(new GenericResourceApiVfModuleOperationInformation()).when(sdncVfModuleResources).changeAssignVfModule(vfModule, genericVnf, serviceInstance, customer, cloudRegion, requestContext);
sdncChangeAssignTasks.changeAssignModelVfModule(execution);
-
verify(sdncVfModuleResources, times(1)).changeAssignVfModule(vfModule, genericVnf, serviceInstance, customer, cloudRegion, requestContext);
- assertTrue(execution.getVariable("SDNCChangeAssignVfModuleResponse").equals(response));
+ SDNCRequest sdncRequest = execution.getVariable("SDNCRequest");
+ assertEquals(SDNCTopology.VFMODULE,sdncRequest.getTopology());
}
@Test
diff --git a/bpmn/so-bpmn-tasks/src/test/java/org/onap/so/bpmn/infrastructure/sdnc/tasks/SDNCDeactivateTaskTest.java b/bpmn/so-bpmn-tasks/src/test/java/org/onap/so/bpmn/infrastructure/sdnc/tasks/SDNCDeactivateTaskTest.java
index 66b8ecfb20..3d25addb9c 100644
--- a/bpmn/so-bpmn-tasks/src/test/java/org/onap/so/bpmn/infrastructure/sdnc/tasks/SDNCDeactivateTaskTest.java
+++ b/bpmn/so-bpmn-tasks/src/test/java/org/onap/so/bpmn/infrastructure/sdnc/tasks/SDNCDeactivateTaskTest.java
@@ -21,9 +21,6 @@
package org.onap.so.bpmn.infrastructure.sdnc.tasks;
import static org.junit.Assert.assertEquals;
-import static org.junit.Assert.assertFalse;
-import static org.junit.Assert.assertNull;
-import static org.junit.Assert.assertTrue;
import static org.mockito.ArgumentMatchers.any;
import static org.mockito.ArgumentMatchers.eq;
import static org.mockito.Mockito.doReturn;
@@ -37,6 +34,10 @@ import org.junit.Before;
import org.junit.Test;
import org.mockito.ArgumentMatchers;
import org.mockito.InjectMocks;
+import org.onap.sdnc.northbound.client.model.GenericResourceApiNetworkOperationInformation;
+import org.onap.sdnc.northbound.client.model.GenericResourceApiServiceOperationInformation;
+import org.onap.sdnc.northbound.client.model.GenericResourceApiVfModuleOperationInformation;
+import org.onap.sdnc.northbound.client.model.GenericResourceApiVnfOperationInformation;
import org.onap.so.bpmn.BaseTaskTest;
import org.onap.so.bpmn.common.BuildingBlockExecution;
import org.onap.so.bpmn.servicedecomposition.bbobjects.CloudRegion;
@@ -48,7 +49,8 @@ import org.onap.so.bpmn.servicedecomposition.bbobjects.VfModule;
import org.onap.so.bpmn.servicedecomposition.entities.ResourceKey;
import org.onap.so.bpmn.servicedecomposition.generalobjects.RequestContext;
import org.onap.so.client.exception.BBObjectNotFoundException;
-import org.springframework.beans.factory.annotation.Autowired;
+import org.onap.so.client.sdnc.beans.SDNCRequest;
+import org.onap.so.client.sdnc.endpoint.SDNCTopology;
public class SDNCDeactivateTaskTest extends BaseTaskTest {
@InjectMocks
@@ -82,29 +84,27 @@ public class SDNCDeactivateTaskTest extends BaseTaskTest {
@Test
public void deactivateVfModuleTest() throws Exception {
- doReturn("success").when(sdncVfModuleResources).deactivateVfModule(vfModule, genericVnf, serviceInstance, customer, cloudRegion, requestContext);
-
+ doReturn(new GenericResourceApiVfModuleOperationInformation()).when(sdncVfModuleResources).deactivateVfModule(vfModule, genericVnf, serviceInstance, customer, cloudRegion, requestContext);
sdncDeactivateTasks.deactivateVfModule(execution);
-
verify(sdncVfModuleResources, times(1)).deactivateVfModule(vfModule, genericVnf, serviceInstance, customer, cloudRegion, requestContext);
+ SDNCRequest sdncRequest = execution.getVariable("SDNCRequest");
+ assertEquals(SDNCTopology.VFMODULE,sdncRequest.getTopology());
}
@Test
public void deactivateVfModuleExceptionTest() throws Exception {
expectedException.expect(BpmnError.class);
-
doThrow(RuntimeException.class).when(sdncVfModuleResources).deactivateVfModule(vfModule, genericVnf, serviceInstance, customer, cloudRegion, requestContext);
-
sdncDeactivateTasks.deactivateVfModule(execution);
}
@Test
public void deactivateVnfTest() throws Exception {
- doReturn("success").when(sdncVnfResources).deactivateVnf(genericVnf, serviceInstance, customer, cloudRegion, requestContext);
-
+ doReturn(new GenericResourceApiVnfOperationInformation()).when(sdncVnfResources).deactivateVnf(genericVnf, serviceInstance, customer, cloudRegion, requestContext);
sdncDeactivateTasks.deactivateVnf(execution);
-
verify(sdncVnfResources, times(1)).deactivateVnf(genericVnf, serviceInstance, customer, cloudRegion, requestContext);
+ SDNCRequest sdncRequest = execution.getVariable("SDNCRequest");
+ assertEquals(SDNCTopology.VNF,sdncRequest.getTopology());
}
@Test
@@ -116,13 +116,11 @@ public class SDNCDeactivateTaskTest extends BaseTaskTest {
@Test
public void deactivateServiceInstanceTest() throws Exception {
- doReturn("response").when(sdncServiceInstanceResources).deactivateServiceInstance(serviceInstance, customer, requestContext);
-
+ doReturn(new GenericResourceApiServiceOperationInformation()).when(sdncServiceInstanceResources).deactivateServiceInstance(serviceInstance, customer, requestContext);
sdncDeactivateTasks.deactivateServiceInstance(execution);
-
verify(sdncServiceInstanceResources, times(1)).deactivateServiceInstance(serviceInstance, customer, requestContext);
- assertEquals("response", execution.getVariable("deactivateServiceInstanceSDNCResponse"));
- assertTrue(execution.getVariable("sdncServiceInstanceRollback"));
+ SDNCRequest sdncRequest = execution.getVariable("SDNCRequest");
+ assertEquals(SDNCTopology.SERVICE,sdncRequest.getTopology());
}
@Test
@@ -134,34 +132,18 @@ public class SDNCDeactivateTaskTest extends BaseTaskTest {
@Test
public void test_deactivateNetwork() throws Exception {
- String expectedResponse = "return";
-
- doReturn(expectedResponse).when(sdncNetworkResources).deactivateNetwork(network, serviceInstance, customer, requestContext, cloudRegion);
-
+ doReturn(new GenericResourceApiNetworkOperationInformation()).when(sdncNetworkResources).deactivateNetwork(network, serviceInstance, customer, requestContext, cloudRegion);
sdncDeactivateTasks.deactivateNetwork(execution);
-
verify(sdncNetworkResources, times(1)).deactivateNetwork(network, serviceInstance, customer, requestContext, cloudRegion);
-
- assertEquals(expectedResponse, execution.getVariable("SDNCDeactivateTasks.deactivateNetwork.response"));
-
- assertTrue(execution.getVariable("SDNCDeactivateTasks.deactivateNetwork.rollback"));
+ SDNCRequest sdncRequest = execution.getVariable("SDNCRequest");
+ assertEquals(SDNCTopology.NETWORK,sdncRequest.getTopology());
}
@Test
public void test_deactivateNetwork_exception() throws Exception {
expectedException.expect(BpmnError.class);
-
- try {
- doThrow(RuntimeException.class).when(extractPojosForBB).extractByKey(any(),ArgumentMatchers.eq(ResourceKey.NETWORK_ID), any());
-
- sdncDeactivateTasks.deactivateNetwork(execution);
- } finally {
- verify(sdncNetworkResources, times(0)).deactivateNetwork(network, serviceInstance, customer, requestContext, cloudRegion);
-
- assertNull(execution.getVariable("SDNCDeactivateTasks.deactivateNetwork.response"));
-
- assertFalse(execution.getVariable("SDNCDeactivateTasks.deactivateNetwork.rollback"));
- }
+ doThrow(RuntimeException.class).when(extractPojosForBB).extractByKey(any(),ArgumentMatchers.eq(ResourceKey.NETWORK_ID), any());
+ sdncDeactivateTasks.deactivateNetwork(execution);
+ verify(sdncNetworkResources, times(0)).deactivateNetwork(network, serviceInstance, customer, requestContext, cloudRegion);
}
-
}
diff --git a/bpmn/so-bpmn-tasks/src/test/java/org/onap/so/bpmn/infrastructure/sdnc/tasks/SDNCUnassignTasksTest.java b/bpmn/so-bpmn-tasks/src/test/java/org/onap/so/bpmn/infrastructure/sdnc/tasks/SDNCUnassignTasksTest.java
index 07f03b592b..1301787dff 100644
--- a/bpmn/so-bpmn-tasks/src/test/java/org/onap/so/bpmn/infrastructure/sdnc/tasks/SDNCUnassignTasksTest.java
+++ b/bpmn/so-bpmn-tasks/src/test/java/org/onap/so/bpmn/infrastructure/sdnc/tasks/SDNCUnassignTasksTest.java
@@ -23,7 +23,6 @@ package org.onap.so.bpmn.infrastructure.sdnc.tasks;
import static org.junit.Assert.assertEquals;
import static org.junit.Assert.assertNotEquals;
import static org.junit.Assert.assertNull;
-import static org.junit.Assert.assertTrue;
import static org.mockito.ArgumentMatchers.any;
import static org.mockito.ArgumentMatchers.eq;
import static org.mockito.Mockito.doReturn;
@@ -37,6 +36,10 @@ import org.junit.Before;
import org.junit.Test;
import org.mockito.ArgumentMatchers;
import org.mockito.InjectMocks;
+import org.onap.sdnc.northbound.client.model.GenericResourceApiNetworkOperationInformation;
+import org.onap.sdnc.northbound.client.model.GenericResourceApiServiceOperationInformation;
+import org.onap.sdnc.northbound.client.model.GenericResourceApiVfModuleOperationInformation;
+import org.onap.sdnc.northbound.client.model.GenericResourceApiVnfOperationInformation;
import org.onap.so.bpmn.BaseTaskTest;
import org.onap.so.bpmn.common.BuildingBlockExecution;
import org.onap.so.bpmn.servicedecomposition.bbobjects.CloudRegion;
@@ -48,8 +51,8 @@ import org.onap.so.bpmn.servicedecomposition.bbobjects.VfModule;
import org.onap.so.bpmn.servicedecomposition.entities.ResourceKey;
import org.onap.so.bpmn.servicedecomposition.generalobjects.RequestContext;
import org.onap.so.client.exception.BBObjectNotFoundException;
-import org.onap.so.db.catalog.beans.OrchestrationStatus;
-import org.springframework.beans.factory.annotation.Autowired;
+import org.onap.so.client.sdnc.beans.SDNCRequest;
+import org.onap.so.client.sdnc.endpoint.SDNCTopology;
public class SDNCUnassignTasksTest extends BaseTaskTest{
@InjectMocks
@@ -81,11 +84,11 @@ public class SDNCUnassignTasksTest extends BaseTaskTest{
@Test
public void unassignServiceInstanceTest() throws Exception {
- doReturn("test").when(sdncServiceInstanceResources).unassignServiceInstance(serviceInstance, customer, requestContext);
-
+ doReturn(new GenericResourceApiServiceOperationInformation()).when(sdncServiceInstanceResources).unassignServiceInstance(serviceInstance, customer, requestContext);
sdncUnassignTasks.unassignServiceInstance(execution);
-
verify(sdncServiceInstanceResources, times(1)).unassignServiceInstance(serviceInstance, customer, requestContext);
+ SDNCRequest sdncRequest = execution.getVariable("SDNCRequest");
+ assertEquals(SDNCTopology.SERVICE,sdncRequest.getTopology());
}
@@ -93,20 +96,17 @@ public class SDNCUnassignTasksTest extends BaseTaskTest{
@Test
public void unassignServiceInstanceExceptionTest() throws Exception {
expectedException.expect(BpmnError.class);
-
doThrow(RuntimeException.class).when(sdncServiceInstanceResources).unassignServiceInstance(serviceInstance, customer, requestContext);
-
sdncUnassignTasks.unassignServiceInstance(execution);
}
@Test
public void unassignVfModuleTest() throws Exception {
- doReturn("response").when(sdncVfModuleResources).unassignVfModule(vfModule, genericVnf, serviceInstance);
-
+ doReturn(new GenericResourceApiVfModuleOperationInformation()).when(sdncVfModuleResources).unassignVfModule(vfModule, genericVnf, serviceInstance);
sdncUnassignTasks.unassignVfModule(execution);
-
verify(sdncVfModuleResources, times(1)).unassignVfModule(vfModule, genericVnf, serviceInstance);
- assertEquals("response", execution.getVariable("SDNCResponse"));
+ SDNCRequest sdncRequest = execution.getVariable("SDNCRequest");
+ assertEquals(SDNCTopology.VFMODULE,sdncRequest.getTopology());
}
@@ -115,20 +115,17 @@ public class SDNCUnassignTasksTest extends BaseTaskTest{
@Test
public void unassignVfModuleExceptionTest() throws Exception {
expectedException.expect(BpmnError.class);
-
doThrow(RuntimeException.class).when(sdncVfModuleResources).unassignVfModule(vfModule, genericVnf, serviceInstance);
-
sdncUnassignTasks.unassignVfModule(execution);
}
@Test
public void unassignVnfTest() throws Exception {
- doReturn("response").when(sdncVnfResources).unassignVnf(genericVnf, serviceInstance, customer, cloudRegion, requestContext);
-
+ doReturn(new GenericResourceApiVnfOperationInformation()).when(sdncVnfResources).unassignVnf(genericVnf, serviceInstance, customer, cloudRegion, requestContext);
sdncUnassignTasks.unassignVnf(execution);
-
verify(sdncVnfResources, times(1)).unassignVnf(genericVnf, serviceInstance, customer, cloudRegion, requestContext);
- assertTrue(execution.getVariable("sdncUnassignVnfResponse").equals("response"));
+ SDNCRequest sdncRequest = execution.getVariable("SDNCRequest");
+ assertEquals(SDNCTopology.VNF,sdncRequest.getTopology());
}
@@ -142,18 +139,14 @@ public class SDNCUnassignTasksTest extends BaseTaskTest{
@Test
public void unassignNetworkTest() throws Exception {
String cloudRegionSdnc = "AAIAIC25";
-
cloudRegion.setCloudRegionVersion("2.5");
-
execution.setVariable("cloudRegionSdnc", cloudRegionSdnc);
-
- doReturn("response").when(sdncNetworkResources).unassignNetwork(network, serviceInstance, customer, requestContext, cloudRegion);
-
+ doReturn(new GenericResourceApiNetworkOperationInformation()).when(sdncNetworkResources).unassignNetwork(network, serviceInstance, customer, requestContext, cloudRegion);
assertNotEquals(cloudRegionSdnc, cloudRegion.getLcpCloudRegionId());
sdncUnassignTasks.unassignNetwork(execution);
-
verify(sdncNetworkResources, times(1)).unassignNetwork(network, serviceInstance, customer, requestContext, cloudRegion);
- assertEquals("response", execution.getVariable("SDNCUnAssignNetworkResponse"));
assertEquals(cloudRegionSdnc, cloudRegion.getLcpCloudRegionId());
+ SDNCRequest sdncRequest = execution.getVariable("SDNCRequest");
+ assertEquals(SDNCTopology.NETWORK,sdncRequest.getTopology());
}
}
diff --git a/bpmn/so-bpmn-tasks/src/test/java/org/onap/so/client/orchestration/SDNCNetworkResourcesTest.java b/bpmn/so-bpmn-tasks/src/test/java/org/onap/so/client/orchestration/SDNCNetworkResourcesTest.java
index b93328ffe8..f275f3c484 100644
--- a/bpmn/so-bpmn-tasks/src/test/java/org/onap/so/client/orchestration/SDNCNetworkResourcesTest.java
+++ b/bpmn/so-bpmn-tasks/src/test/java/org/onap/so/client/orchestration/SDNCNetworkResourcesTest.java
@@ -20,10 +20,6 @@
package org.onap.so.client.orchestration;
-import static org.junit.Assert.assertEquals;
-import static org.mockito.ArgumentMatchers.any;
-import static org.mockito.Matchers.eq;
-import static org.mockito.ArgumentMatchers.isA;
import static org.mockito.Mockito.doReturn;
import static org.mockito.Mockito.times;
import static org.mockito.Mockito.verify;
@@ -31,47 +27,42 @@ import static org.mockito.Mockito.verify;
import org.junit.Before;
import org.junit.Test;
import org.junit.runner.RunWith;
-import org.mockito.ArgumentMatchers;
import org.mockito.InjectMocks;
import org.mockito.Mock;
import org.mockito.junit.MockitoJUnitRunner;
+import org.onap.sdnc.northbound.client.model.GenericResourceApiNetworkOperationInformation;
+import org.onap.sdnc.northbound.client.model.GenericResourceApiRequestActionEnumeration;
import org.onap.so.bpmn.common.data.TestDataSetup;
import org.onap.so.bpmn.servicedecomposition.bbobjects.CloudRegion;
import org.onap.so.bpmn.servicedecomposition.bbobjects.Customer;
import org.onap.so.bpmn.servicedecomposition.bbobjects.L3Network;
import org.onap.so.bpmn.servicedecomposition.bbobjects.ServiceInstance;
-import org.onap.so.bpmn.servicedecomposition.bbobjects.ServiceSubscription;
import org.onap.so.bpmn.servicedecomposition.generalobjects.RequestContext;
import org.onap.so.client.exception.BadResponseException;
import org.onap.so.client.exception.MapperException;
import org.onap.so.client.sdnc.SDNCClient;
import org.onap.so.client.sdnc.beans.SDNCSvcAction;
import org.onap.so.client.sdnc.beans.SDNCSvcOperation;
-import org.onap.so.client.sdnc.endpoint.SDNCTopology;
import org.onap.so.client.sdnc.mapper.NetworkTopologyOperationRequestMapper;
-import org.onap.so.db.catalog.beans.OrchestrationStatus;
-
-import org.onap.sdnc.northbound.client.model.GenericResourceApiNetworkOperationInformation;
-import org.onap.sdnc.northbound.client.model.GenericResourceApiRequestActionEnumeration;
@RunWith(MockitoJUnitRunner.Silent.class)
-public class SDNCNetworkResourcesTest extends TestDataSetup{
-
+public class SDNCNetworkResourcesTest extends TestDataSetup {
+
@InjectMocks
private SDNCNetworkResources sdncNetworkResources;
-
+
@Mock
protected SDNCClient MOCK_sdncClient;
-
+
@Mock
- protected NetworkTopologyOperationRequestMapper MOCK_networkTopologyOperationRequestMapper;
-
+ protected NetworkTopologyOperationRequestMapper MOCK_networkTopologyOperationRequestMapper;
+
private L3Network network;
private ServiceInstance serviceInstance;
private Customer customer;
private RequestContext requestContext;
private CloudRegion cloudRegion;
-
+
@Before
public void before() {
network = buildL3Network();
@@ -81,125 +72,98 @@ public class SDNCNetworkResourcesTest extends TestDataSetup{
serviceInstance = buildServiceInstance();
requestContext = buildRequestContext();
-
+
cloudRegion = new CloudRegion();
}
@Test
public void assignNetworkTest() throws Exception {
- network.setOrchestrationStatus(OrchestrationStatus.ASSIGNED);
-
- doReturn("test").when(MOCK_sdncClient).post(isA(GenericResourceApiNetworkOperationInformation.class), eq(SDNCTopology.NETWORK));
-
+ doReturn(new GenericResourceApiNetworkOperationInformation()).when(MOCK_networkTopologyOperationRequestMapper)
+ .reqMapper(SDNCSvcOperation.NETWORK_TOPOLOGY_OPERATION, SDNCSvcAction.ASSIGN,
+ GenericResourceApiRequestActionEnumeration.CREATENETWORKINSTANCE, network, serviceInstance,
+ customer, requestContext, cloudRegion);
sdncNetworkResources.assignNetwork(network, serviceInstance, customer, requestContext, cloudRegion);
-
- verify(MOCK_sdncClient, times(1)).post(ArgumentMatchers.isNull(), eq(SDNCTopology.NETWORK));
-
- assertEquals(OrchestrationStatus.ASSIGNED, network.getOrchestrationStatus());
+ verify(MOCK_networkTopologyOperationRequestMapper, times(1)).reqMapper(
+ SDNCSvcOperation.NETWORK_TOPOLOGY_OPERATION, SDNCSvcAction.ASSIGN,
+ GenericResourceApiRequestActionEnumeration.CREATENETWORKINSTANCE, network, serviceInstance, customer,
+ requestContext, cloudRegion);
}
-
+
@Test
public void rollbackAssignNetworkTest() throws Exception {
- network.setOrchestrationStatus(OrchestrationStatus.ASSIGNED);
-
- doReturn("test").when(MOCK_sdncClient).post(isA(GenericResourceApiNetworkOperationInformation.class), eq(SDNCTopology.NETWORK));
-
+ doReturn(new GenericResourceApiNetworkOperationInformation()).when(MOCK_networkTopologyOperationRequestMapper)
+ .reqMapper(SDNCSvcOperation.NETWORK_TOPOLOGY_OPERATION, SDNCSvcAction.UNASSIGN,
+ GenericResourceApiRequestActionEnumeration.DELETENETWORKINSTANCE, network, serviceInstance,
+ customer, requestContext, cloudRegion);
sdncNetworkResources.rollbackAssignNetwork(network, serviceInstance, customer, requestContext, cloudRegion);
-
- verify(MOCK_sdncClient, times(1)).post(ArgumentMatchers.isNull(), eq(SDNCTopology.NETWORK));
-
- assertEquals(OrchestrationStatus.ASSIGNED, network.getOrchestrationStatus());
+ verify(MOCK_networkTopologyOperationRequestMapper, times(1)).reqMapper(
+ SDNCSvcOperation.NETWORK_TOPOLOGY_OPERATION, SDNCSvcAction.UNASSIGN,
+ GenericResourceApiRequestActionEnumeration.DELETENETWORKINSTANCE, network, serviceInstance, customer,
+ requestContext, cloudRegion);
}
-
+
@Test
public void activateNetworkTest() throws Exception {
- network.setOrchestrationStatus(OrchestrationStatus.ASSIGNED);
-
- doReturn("test").when(MOCK_sdncClient).post(isA(GenericResourceApiNetworkOperationInformation.class), eq(SDNCTopology.NETWORK));
-
+ doReturn(new GenericResourceApiNetworkOperationInformation()).when(MOCK_networkTopologyOperationRequestMapper)
+ .reqMapper(SDNCSvcOperation.NETWORK_TOPOLOGY_OPERATION, SDNCSvcAction.ACTIVATE,
+ GenericResourceApiRequestActionEnumeration.CREATENETWORKINSTANCE, network, serviceInstance,
+ customer, requestContext, cloudRegion);
sdncNetworkResources.activateNetwork(network, serviceInstance, customer, requestContext, cloudRegion);
-
- verify(MOCK_sdncClient, times(1)).post(ArgumentMatchers.isNull(), eq(SDNCTopology.NETWORK));
-
- assertEquals(OrchestrationStatus.ASSIGNED, network.getOrchestrationStatus());
+ verify(MOCK_networkTopologyOperationRequestMapper, times(1)).reqMapper(
+ SDNCSvcOperation.NETWORK_TOPOLOGY_OPERATION, SDNCSvcAction.ACTIVATE,
+ GenericResourceApiRequestActionEnumeration.CREATENETWORKINSTANCE, network, serviceInstance, customer,
+ requestContext, cloudRegion);
}
-
+
@Test
public void deleteNetworkTest() throws Exception {
- network.setOrchestrationStatus(OrchestrationStatus.ASSIGNED);
-
- doReturn("test").when(MOCK_sdncClient).post(isA(GenericResourceApiNetworkOperationInformation.class), eq(SDNCTopology.NETWORK));
-
+ doReturn(new GenericResourceApiNetworkOperationInformation()).when(MOCK_networkTopologyOperationRequestMapper)
+ .reqMapper(SDNCSvcOperation.NETWORK_TOPOLOGY_OPERATION, SDNCSvcAction.DELETE,
+ GenericResourceApiRequestActionEnumeration.DELETENETWORKINSTANCE, network, serviceInstance,
+ customer, requestContext, cloudRegion);
sdncNetworkResources.deleteNetwork(network, serviceInstance, customer, requestContext, cloudRegion);
-
- verify(MOCK_sdncClient, times(1)).post(ArgumentMatchers.isNull(), eq(SDNCTopology.NETWORK));
-
- assertEquals(OrchestrationStatus.ASSIGNED, network.getOrchestrationStatus());
+ verify(MOCK_networkTopologyOperationRequestMapper, times(1)).reqMapper(
+ SDNCSvcOperation.NETWORK_TOPOLOGY_OPERATION, SDNCSvcAction.DELETE,
+ GenericResourceApiRequestActionEnumeration.DELETENETWORKINSTANCE, network, serviceInstance, customer,
+ requestContext, cloudRegion);
}
-
+
@Test
public void test_deactivateNetwork() throws MapperException, BadResponseException {
- serviceInstance.getNetworks().add(network);
-
- Customer customer = new Customer();
- customer.setGlobalCustomerId("gcustId");
- customer.setServiceSubscription(new ServiceSubscription());
- // set Customer on service instance
- customer.getServiceSubscription().getServiceInstances().add(serviceInstance);
-
- GenericResourceApiNetworkOperationInformation expectedGenericResourceApiNetworkOperationInformation = new GenericResourceApiNetworkOperationInformation();
-
- String expectedResponse = "response";
-
- doReturn(expectedResponse).when(MOCK_sdncClient).post(expectedGenericResourceApiNetworkOperationInformation, SDNCTopology.NETWORK);
-
- doReturn(expectedGenericResourceApiNetworkOperationInformation).when(MOCK_networkTopologyOperationRequestMapper).reqMapper(SDNCSvcOperation.NETWORK_TOPOLOGY_OPERATION, SDNCSvcAction.DEACTIVATE, GenericResourceApiRequestActionEnumeration.DELETENETWORKINSTANCE, network, serviceInstance, customer, requestContext, cloudRegion);
-
- String actualResponse = sdncNetworkResources.deactivateNetwork(network, serviceInstance, customer, requestContext, cloudRegion);
-
- verify(MOCK_networkTopologyOperationRequestMapper, times(1)).reqMapper(SDNCSvcOperation.NETWORK_TOPOLOGY_OPERATION, SDNCSvcAction.DEACTIVATE, GenericResourceApiRequestActionEnumeration.DELETENETWORKINSTANCE, network, serviceInstance, customer, requestContext, cloudRegion);
-
- verify(MOCK_sdncClient).post(expectedGenericResourceApiNetworkOperationInformation, SDNCTopology.NETWORK);
-
- assertEquals(expectedResponse, actualResponse);
+ doReturn(new GenericResourceApiNetworkOperationInformation()).when(MOCK_networkTopologyOperationRequestMapper)
+ .reqMapper(SDNCSvcOperation.NETWORK_TOPOLOGY_OPERATION, SDNCSvcAction.DEACTIVATE,
+ GenericResourceApiRequestActionEnumeration.DELETENETWORKINSTANCE, network, serviceInstance,
+ customer, requestContext, cloudRegion);
+ sdncNetworkResources.deactivateNetwork(network, serviceInstance, customer, requestContext, cloudRegion);
+ verify(MOCK_networkTopologyOperationRequestMapper, times(1)).reqMapper(
+ SDNCSvcOperation.NETWORK_TOPOLOGY_OPERATION, SDNCSvcAction.DEACTIVATE,
+ GenericResourceApiRequestActionEnumeration.DELETENETWORKINSTANCE, network, serviceInstance, customer,
+ requestContext, cloudRegion);
}
-
+
@Test
public void changeAssignNetworkTest() throws MapperException, BadResponseException {
- String expectedSdncResponse = "SDNCChangeAssignNetworkResponse";
-
- serviceInstance.getNetworks().add(network);
-
- Customer customer = new Customer();
- customer.setGlobalCustomerId("globalCustomerId");
- customer.setServiceSubscription(new ServiceSubscription());
- // set Customer on service instance
- customer.getServiceSubscription().getServiceInstances().add(serviceInstance);
-
- GenericResourceApiNetworkOperationInformation sdncReq = new GenericResourceApiNetworkOperationInformation();
-
- doReturn(sdncReq).when(MOCK_networkTopologyOperationRequestMapper).reqMapper(isA(SDNCSvcOperation.class), isA(SDNCSvcAction.class), isA(GenericResourceApiRequestActionEnumeration.class), isA(L3Network.class), isA(ServiceInstance.class), isA(Customer.class), isA(RequestContext.class), isA(CloudRegion.class));
-
- doReturn(expectedSdncResponse).when(MOCK_sdncClient).post(isA(GenericResourceApiNetworkOperationInformation.class), isA(SDNCTopology.class));
-
- String actualSdncResponse = sdncNetworkResources.changeAssignNetwork(network, serviceInstance, customer, requestContext, cloudRegion);
-
- verify(MOCK_networkTopologyOperationRequestMapper, times(1)).reqMapper(SDNCSvcOperation.NETWORK_TOPOLOGY_OPERATION, SDNCSvcAction.CHANGE_ASSIGN, GenericResourceApiRequestActionEnumeration.CREATENETWORKINSTANCE, network, serviceInstance, customer, requestContext, cloudRegion);
- verify(MOCK_sdncClient, times(1)).post(sdncReq, SDNCTopology.NETWORK);
- assertEquals(actualSdncResponse, expectedSdncResponse);
+ doReturn(new GenericResourceApiNetworkOperationInformation()).when(MOCK_networkTopologyOperationRequestMapper)
+ .reqMapper(SDNCSvcOperation.NETWORK_TOPOLOGY_OPERATION, SDNCSvcAction.CHANGE_ASSIGN,
+ GenericResourceApiRequestActionEnumeration.CREATENETWORKINSTANCE, network, serviceInstance,
+ customer, requestContext, cloudRegion);
+ sdncNetworkResources.changeAssignNetwork(network, serviceInstance, customer, requestContext, cloudRegion);
+ verify(MOCK_networkTopologyOperationRequestMapper, times(1)).reqMapper(
+ SDNCSvcOperation.NETWORK_TOPOLOGY_OPERATION, SDNCSvcAction.CHANGE_ASSIGN,
+ GenericResourceApiRequestActionEnumeration.CREATENETWORKINSTANCE, network, serviceInstance, customer,
+ requestContext, cloudRegion);
}
-
+
@Test
public void unassignNetwork_Test() throws Exception {
- network.setOrchestrationStatus(OrchestrationStatus.CREATED);
-
- doReturn("test").when(MOCK_sdncClient).post(isA(GenericResourceApiNetworkOperationInformation.class), eq(SDNCTopology.NETWORK));
-
- sdncNetworkResources.unassignNetwork(network, serviceInstance, customer,
- requestContext, cloudRegion);
-
- verify(MOCK_sdncClient, times(1)).post(ArgumentMatchers.isNull(), eq(SDNCTopology.NETWORK));
-
- assertEquals(OrchestrationStatus.CREATED, network.getOrchestrationStatus());
- }
+ doReturn(new GenericResourceApiNetworkOperationInformation()).when(MOCK_networkTopologyOperationRequestMapper)
+ .reqMapper(SDNCSvcOperation.NETWORK_TOPOLOGY_OPERATION, SDNCSvcAction.UNASSIGN,
+ GenericResourceApiRequestActionEnumeration.DELETENETWORKINSTANCE, network, serviceInstance,
+ customer, requestContext, cloudRegion);
+ sdncNetworkResources.unassignNetwork(network, serviceInstance, customer, requestContext, cloudRegion);
+ verify(MOCK_networkTopologyOperationRequestMapper, times(1)).reqMapper(
+ SDNCSvcOperation.NETWORK_TOPOLOGY_OPERATION, SDNCSvcAction.UNASSIGN,
+ GenericResourceApiRequestActionEnumeration.DELETENETWORKINSTANCE, network, serviceInstance, customer,
+ requestContext, cloudRegion);
+ }
} \ No newline at end of file
diff --git a/bpmn/so-bpmn-tasks/src/test/java/org/onap/so/client/orchestration/SDNCServiceInstanceResourcesTest.java b/bpmn/so-bpmn-tasks/src/test/java/org/onap/so/client/orchestration/SDNCServiceInstanceResourcesTest.java
index 42672e1180..509dc1de0d 100644
--- a/bpmn/so-bpmn-tasks/src/test/java/org/onap/so/client/orchestration/SDNCServiceInstanceResourcesTest.java
+++ b/bpmn/so-bpmn-tasks/src/test/java/org/onap/so/client/orchestration/SDNCServiceInstanceResourcesTest.java
@@ -21,7 +21,7 @@
package org.onap.so.client.orchestration;
import static org.mockito.ArgumentMatchers.any;
-import static org.mockito.Matchers.eq;
+import static org.mockito.ArgumentMatchers.eq;
import static org.mockito.Mockito.doReturn;
import static org.mockito.Mockito.doThrow;
import static org.mockito.Mockito.times;
@@ -30,121 +30,100 @@ import static org.mockito.Mockito.verify;
import org.junit.Before;
import org.junit.Test;
import org.junit.runner.RunWith;
-import org.mockito.ArgumentMatchers;
import org.mockito.InjectMocks;
import org.mockito.Mock;
import org.mockito.junit.MockitoJUnitRunner;
+import org.onap.sdnc.northbound.client.model.GenericResourceApiRequestActionEnumeration;
+import org.onap.sdnc.northbound.client.model.GenericResourceApiServiceOperationInformation;
import org.onap.so.bpmn.common.data.TestDataSetup;
import org.onap.so.bpmn.servicedecomposition.bbobjects.Customer;
import org.onap.so.bpmn.servicedecomposition.bbobjects.ServiceInstance;
import org.onap.so.bpmn.servicedecomposition.generalobjects.RequestContext;
import org.onap.so.client.exception.BadResponseException;
import org.onap.so.client.exception.MapperException;
-import org.onap.so.client.sdnc.SDNCClient;
import org.onap.so.client.sdnc.beans.SDNCSvcAction;
import org.onap.so.client.sdnc.beans.SDNCSvcOperation;
-import org.onap.so.client.sdnc.endpoint.SDNCTopology;
import org.onap.so.client.sdnc.mapper.ServiceTopologyOperationMapper;
-import org.onap.sdnc.northbound.client.model.GenericResourceApiRequestActionEnumeration;
-import org.onap.sdnc.northbound.client.model.GenericResourceApiServiceOperationInformation;
-
@RunWith(MockitoJUnitRunner.Silent.class)
public class SDNCServiceInstanceResourcesTest extends TestDataSetup{
+
@InjectMocks
private SDNCServiceInstanceResources sdncServiceInstanceResources;
-
-
@Mock
protected ServiceTopologyOperationMapper MOCK_serviceTopologyOperationMapper;
-
private RequestContext requestContext;
private ServiceInstance serviceInstance;
private Customer customer;
- @Mock
- protected SDNCClient MOCK_sdncClient;
-
@Before
public void before() {
requestContext = buildRequestContext();
-
serviceInstance = buildServiceInstance();
-
customer = buildCustomer();
-
customer.getServiceSubscription().getServiceInstances().add(serviceInstance);
}
@Test
public void assignServiceInstanceSuccessTest() throws Exception {
doReturn(new GenericResourceApiServiceOperationInformation()).when(MOCK_serviceTopologyOperationMapper).reqMapper(eq(SDNCSvcOperation.SERVICE_TOPOLOGY_OPERATION), eq(SDNCSvcAction.ASSIGN), eq(GenericResourceApiRequestActionEnumeration.CREATESERVICEINSTANCE), any(ServiceInstance.class), any(Customer.class), any(RequestContext.class));
- doReturn("test").when(MOCK_sdncClient).post(any(GenericResourceApiServiceOperationInformation.class), eq(SDNCTopology.SERVICE));
sdncServiceInstanceResources.assignServiceInstance(serviceInstance, customer, requestContext);
- verify(MOCK_sdncClient, times(1)).post(any(GenericResourceApiServiceOperationInformation.class), eq(SDNCTopology.SERVICE));
+ verify(MOCK_serviceTopologyOperationMapper, times(1)).reqMapper(eq(SDNCSvcOperation.SERVICE_TOPOLOGY_OPERATION), eq(SDNCSvcAction.ASSIGN), eq(GenericResourceApiRequestActionEnumeration.CREATESERVICEINSTANCE), any(ServiceInstance.class), any(Customer.class), any(RequestContext.class));
}
@Test
public void assignServiceInstanceExceptionTest() throws Exception {
expectedException.expect(Exception.class);
- doReturn(new GenericResourceApiServiceOperationInformation()).when(MOCK_serviceTopologyOperationMapper).reqMapper(eq(SDNCSvcOperation.SERVICE_TOPOLOGY_OPERATION), eq(SDNCSvcAction.ASSIGN), eq(GenericResourceApiRequestActionEnumeration.CREATESERVICEINSTANCE), any(ServiceInstance.class), any(Customer.class), any(RequestContext.class));
- doThrow(Exception.class).when(MOCK_sdncClient).post(any(GenericResourceApiServiceOperationInformation.class), eq(SDNCTopology.SERVICE));
+ doThrow(Exception.class).when(MOCK_serviceTopologyOperationMapper).reqMapper(eq(SDNCSvcOperation.SERVICE_TOPOLOGY_OPERATION), eq(SDNCSvcAction.ASSIGN), eq(GenericResourceApiRequestActionEnumeration.CREATESERVICEINSTANCE), any(ServiceInstance.class), any(Customer.class), any(RequestContext.class));
sdncServiceInstanceResources.assignServiceInstance(serviceInstance, customer, requestContext);
}
@Test
public void deleteServiceInstanceSuccessTest() throws Exception {
doReturn(new GenericResourceApiServiceOperationInformation()).when(MOCK_serviceTopologyOperationMapper).reqMapper(eq(SDNCSvcOperation.SERVICE_TOPOLOGY_OPERATION), eq(SDNCSvcAction.DELETE), eq(GenericResourceApiRequestActionEnumeration.DELETESERVICEINSTANCE), any(ServiceInstance.class), any(Customer.class), any(RequestContext.class));
- doReturn("test").when(MOCK_sdncClient).post(any(GenericResourceApiServiceOperationInformation.class), eq(SDNCTopology.SERVICE));
sdncServiceInstanceResources.deleteServiceInstance(serviceInstance, customer, requestContext);
- verify(MOCK_sdncClient, times(1)).post(any(GenericResourceApiServiceOperationInformation.class), eq(SDNCTopology.SERVICE));
+ verify(MOCK_serviceTopologyOperationMapper, times(1)).reqMapper(eq(SDNCSvcOperation.SERVICE_TOPOLOGY_OPERATION), eq(SDNCSvcAction.DELETE), eq(GenericResourceApiRequestActionEnumeration.DELETESERVICEINSTANCE), any(ServiceInstance.class), any(Customer.class), any(RequestContext.class));
}
@Test
public void deleteServiceInstanceExceptionTest() throws Exception {
expectedException.expect(Exception.class);
- doReturn(new GenericResourceApiServiceOperationInformation()).when(MOCK_serviceTopologyOperationMapper).reqMapper(eq(SDNCSvcOperation.SERVICE_TOPOLOGY_OPERATION), eq(SDNCSvcAction.DELETE), eq(GenericResourceApiRequestActionEnumeration.DELETESERVICEINSTANCE), any(ServiceInstance.class), any(Customer.class), any(RequestContext.class));
- doThrow(Exception.class).when(MOCK_sdncClient).post(any(GenericResourceApiServiceOperationInformation.class), eq(SDNCTopology.SERVICE));
+ doThrow(Exception.class).when(MOCK_serviceTopologyOperationMapper).reqMapper(eq(SDNCSvcOperation.SERVICE_TOPOLOGY_OPERATION), eq(SDNCSvcAction.DELETE), eq(GenericResourceApiRequestActionEnumeration.DELETESERVICEINSTANCE), any(ServiceInstance.class), any(Customer.class), any(RequestContext.class));
sdncServiceInstanceResources.deleteServiceInstance(serviceInstance, customer, requestContext);
}
@Test
public void unassignServiceInstanceSuccessTest() throws Exception {
doReturn(new GenericResourceApiServiceOperationInformation()).when(MOCK_serviceTopologyOperationMapper).reqMapper(eq(SDNCSvcOperation.SERVICE_TOPOLOGY_OPERATION), eq(SDNCSvcAction.DELETE), eq(GenericResourceApiRequestActionEnumeration.DELETESERVICEINSTANCE), any(ServiceInstance.class), any(Customer.class), any(RequestContext.class));
- doReturn("test").when(MOCK_sdncClient).post(any(GenericResourceApiServiceOperationInformation.class), eq(SDNCTopology.SERVICE));
sdncServiceInstanceResources.unassignServiceInstance(serviceInstance, customer, requestContext);
- verify(MOCK_sdncClient, times(1)).post(any(GenericResourceApiServiceOperationInformation.class), eq(SDNCTopology.SERVICE));
+ verify(MOCK_serviceTopologyOperationMapper, times(1)).reqMapper(eq(SDNCSvcOperation.SERVICE_TOPOLOGY_OPERATION), eq(SDNCSvcAction.DELETE), eq(GenericResourceApiRequestActionEnumeration.DELETESERVICEINSTANCE), any(ServiceInstance.class), any(Customer.class), any(RequestContext.class));
}
@Test
public void unassignServiceInstanceExceptionTest() throws Exception {
expectedException.expect(Exception.class);
- doReturn(new GenericResourceApiServiceOperationInformation()).when(MOCK_serviceTopologyOperationMapper).reqMapper(eq(SDNCSvcOperation.SERVICE_TOPOLOGY_OPERATION), eq(SDNCSvcAction.DELETE), eq(GenericResourceApiRequestActionEnumeration.DELETESERVICEINSTANCE), any(ServiceInstance.class), any(Customer.class), any(RequestContext.class));
- doThrow(Exception.class).when(MOCK_sdncClient).post(any(GenericResourceApiServiceOperationInformation.class), eq(SDNCTopology.SERVICE));
+ doThrow(Exception.class).when(MOCK_serviceTopologyOperationMapper).reqMapper(eq(SDNCSvcOperation.SERVICE_TOPOLOGY_OPERATION), eq(SDNCSvcAction.DELETE), eq(GenericResourceApiRequestActionEnumeration.DELETESERVICEINSTANCE), any(ServiceInstance.class), any(Customer.class), any(RequestContext.class));
sdncServiceInstanceResources.unassignServiceInstance(serviceInstance,customer, requestContext);
}
@Test
public void deactivateServiceInstanceSuccessTest() throws Exception {
- doReturn(new GenericResourceApiServiceOperationInformation()).when(MOCK_serviceTopologyOperationMapper).reqMapper(eq(SDNCSvcOperation.SERVICE_TOPOLOGY_OPERATION), eq(SDNCSvcAction.DEACTIVATE), eq(GenericResourceApiRequestActionEnumeration.CREATESERVICEINSTANCE), any(ServiceInstance.class), any(Customer.class), any(RequestContext.class));
- doReturn("test").when(MOCK_sdncClient).post(any(GenericResourceApiServiceOperationInformation.class), eq(SDNCTopology.SERVICE));
+ doReturn(new GenericResourceApiServiceOperationInformation()).when(MOCK_serviceTopologyOperationMapper).reqMapper(eq(SDNCSvcOperation.SERVICE_TOPOLOGY_OPERATION), eq(SDNCSvcAction.DEACTIVATE), eq(GenericResourceApiRequestActionEnumeration.DELETESERVICEINSTANCE), any(ServiceInstance.class), any(Customer.class), any(RequestContext.class));
sdncServiceInstanceResources.deactivateServiceInstance(serviceInstance, customer, requestContext);
- verify(MOCK_sdncClient, times(1)).post(ArgumentMatchers.isNull(), eq(SDNCTopology.SERVICE));
+ verify(MOCK_serviceTopologyOperationMapper, times(1)).reqMapper(eq(SDNCSvcOperation.SERVICE_TOPOLOGY_OPERATION), eq(SDNCSvcAction.DEACTIVATE), eq(GenericResourceApiRequestActionEnumeration.DELETESERVICEINSTANCE), any(ServiceInstance.class), any(Customer.class), any(RequestContext.class));
}
@Test
public void deactivateServiceInstanceExceptionTest() throws Exception {
expectedException.expect(Exception.class);
- doReturn(new GenericResourceApiServiceOperationInformation()).when(MOCK_serviceTopologyOperationMapper).reqMapper(eq(SDNCSvcOperation.SERVICE_TOPOLOGY_OPERATION), eq(SDNCSvcAction.DEACTIVATE), eq(GenericResourceApiRequestActionEnumeration.CREATESERVICEINSTANCE), any(ServiceInstance.class), any(Customer.class), any(RequestContext.class));
- doThrow(Exception.class).when(MOCK_sdncClient).post(any(GenericResourceApiServiceOperationInformation.class), eq(SDNCTopology.SERVICE));
+ doThrow(Exception.class).when(MOCK_serviceTopologyOperationMapper).reqMapper(eq(SDNCSvcOperation.SERVICE_TOPOLOGY_OPERATION), eq(SDNCSvcAction.DEACTIVATE), eq(GenericResourceApiRequestActionEnumeration.DELETESERVICEINSTANCE), any(ServiceInstance.class), any(Customer.class), any(RequestContext.class));
sdncServiceInstanceResources.deactivateServiceInstance(serviceInstance, customer, requestContext);
}
@Test
public void test_changeModelServiceInstance() throws MapperException, BadResponseException {
doReturn(new GenericResourceApiServiceOperationInformation()).when(MOCK_serviceTopologyOperationMapper).reqMapper(eq(SDNCSvcOperation.SERVICE_TOPOLOGY_OPERATION), eq(SDNCSvcAction.CHANGE_ASSIGN), eq(GenericResourceApiRequestActionEnumeration.CREATESERVICEINSTANCE), any(ServiceInstance.class), any(Customer.class), any(RequestContext.class));
- doReturn("test").when(MOCK_sdncClient).post(any(GenericResourceApiServiceOperationInformation.class), eq(SDNCTopology.SERVICE));
sdncServiceInstanceResources.changeModelServiceInstance(serviceInstance, customer, requestContext);
- verify(MOCK_sdncClient, times(1)).post(any(GenericResourceApiServiceOperationInformation.class), eq(SDNCTopology.SERVICE));
+ verify(MOCK_serviceTopologyOperationMapper, times(1)).reqMapper(eq(SDNCSvcOperation.SERVICE_TOPOLOGY_OPERATION), eq(SDNCSvcAction.CHANGE_ASSIGN), eq(GenericResourceApiRequestActionEnumeration.CREATESERVICEINSTANCE), any(ServiceInstance.class), any(Customer.class), any(RequestContext.class));
}
}
diff --git a/bpmn/so-bpmn-tasks/src/test/java/org/onap/so/client/orchestration/SDNCVfModuleResourcesTest.java b/bpmn/so-bpmn-tasks/src/test/java/org/onap/so/client/orchestration/SDNCVfModuleResourcesTest.java
index e27f0fcfa1..7d05758129 100644
--- a/bpmn/so-bpmn-tasks/src/test/java/org/onap/so/client/orchestration/SDNCVfModuleResourcesTest.java
+++ b/bpmn/so-bpmn-tasks/src/test/java/org/onap/so/client/orchestration/SDNCVfModuleResourcesTest.java
@@ -20,8 +20,6 @@
package org.onap.so.client.orchestration;
-import static org.mockito.Matchers.eq;
-import static org.mockito.ArgumentMatchers.isA;
import static org.mockito.Mockito.doReturn;
import static org.mockito.Mockito.times;
import static org.mockito.Mockito.verify;
@@ -31,8 +29,8 @@ import org.junit.Test;
import org.junit.runner.RunWith;
import org.mockito.InjectMocks;
import org.mockito.Mock;
-import org.mockito.Spy;
import org.mockito.junit.MockitoJUnitRunner;
+import org.onap.sdnc.northbound.client.model.GenericResourceApiVfModuleOperationInformation;
import org.onap.so.bpmn.common.data.TestDataSetup;
import org.onap.so.bpmn.servicedecomposition.bbobjects.CloudRegion;
import org.onap.so.bpmn.servicedecomposition.bbobjects.Customer;
@@ -43,16 +41,18 @@ import org.onap.so.bpmn.servicedecomposition.bbobjects.VolumeGroup;
import org.onap.so.bpmn.servicedecomposition.generalobjects.RequestContext;
import org.onap.so.client.exception.BadResponseException;
import org.onap.so.client.exception.MapperException;
-import org.onap.so.client.sdnc.SDNCClient;
-import org.onap.so.client.sdnc.endpoint.SDNCTopology;
-import org.onap.so.client.sdnc.mapper.VfModuleTopologyOperationRequestMapper;
-
-import org.onap.sdnc.northbound.client.model.GenericResourceApiVfModuleOperationInformation;;
+import org.onap.so.client.sdnc.beans.SDNCSvcAction;
+import org.onap.so.client.sdnc.beans.SDNCSvcOperation;
+import org.onap.so.client.sdnc.mapper.VfModuleTopologyOperationRequestMapper;;
@RunWith(MockitoJUnitRunner.Silent.class)
public class SDNCVfModuleResourcesTest extends TestDataSetup{
+
@InjectMocks
- private SDNCVfModuleResources sdncVfModuleResources = new SDNCVfModuleResources();
+ private SDNCVfModuleResources sdncVfModuleResources;
+
+ @Mock
+ protected VfModuleTopologyOperationRequestMapper vfModuleTopologyMapper;
private VfModule vfModule;
private GenericVnf vnf;
@@ -61,12 +61,7 @@ public class SDNCVfModuleResourcesTest extends TestDataSetup{
private Customer customer;
private CloudRegion cloudRegion;
private RequestContext requestContext;
-
- @Mock
- protected SDNCClient MOCK_sdncClient;
-
- @Spy
- protected VfModuleTopologyOperationRequestMapper vfModuleTopologyMapper;
+ private GenericResourceApiVfModuleOperationInformation sdncReq;
@Before
public void before() {
@@ -77,50 +72,51 @@ public class SDNCVfModuleResourcesTest extends TestDataSetup{
customer = buildCustomer();
cloudRegion = buildCloudRegion();
requestContext = buildRequestContext();
+ sdncReq = new GenericResourceApiVfModuleOperationInformation();
}
@Test
- public void assignVfModuleTest() throws MapperException, BadResponseException {
- doReturn("test").when(MOCK_sdncClient).post(isA(GenericResourceApiVfModuleOperationInformation.class), isA(SDNCTopology.class));
-
+ public void assignVfModuleTest() throws MapperException {
+ doReturn(sdncReq).when(vfModuleTopologyMapper).reqMapper(SDNCSvcOperation.VF_MODULE_TOPOLOGY_OPERATION, SDNCSvcAction.ASSIGN, vfModule,
+ volumeGroup, vnf, serviceInstance, customer, cloudRegion, requestContext, null);
sdncVfModuleResources.assignVfModule(vfModule, volumeGroup, vnf, serviceInstance, customer, cloudRegion, requestContext);
-
- verify(MOCK_sdncClient, times(1)).post(isA(GenericResourceApiVfModuleOperationInformation.class), eq(SDNCTopology.VFMODULE));
+ verify(vfModuleTopologyMapper, times(1)).reqMapper(SDNCSvcOperation.VF_MODULE_TOPOLOGY_OPERATION, SDNCSvcAction.ASSIGN, vfModule,
+ volumeGroup, vnf, serviceInstance, customer, cloudRegion, requestContext, null);
}
@Test
- public void unassignVfModuleTest() throws MapperException, BadResponseException {
- doReturn("test").when(MOCK_sdncClient).post(isA(GenericResourceApiVfModuleOperationInformation.class), eq(SDNCTopology.VFMODULE));
-
+ public void unassignVfModuleTest() throws MapperException {
+ doReturn(sdncReq).when(vfModuleTopologyMapper).reqMapper(SDNCSvcOperation.VF_MODULE_TOPOLOGY_OPERATION, SDNCSvcAction.UNASSIGN, vfModule, null,
+ vnf, serviceInstance, null, null, null, null);
sdncVfModuleResources.unassignVfModule(vfModule, vnf, serviceInstance);
-
- verify(MOCK_sdncClient, times(1)).post(isA(GenericResourceApiVfModuleOperationInformation.class), eq(SDNCTopology.VFMODULE));
+ verify(vfModuleTopologyMapper, times(1)).reqMapper(SDNCSvcOperation.VF_MODULE_TOPOLOGY_OPERATION, SDNCSvcAction.UNASSIGN, vfModule, null,
+ vnf, serviceInstance, null, null, null, null);
}
@Test
- public void activateVfModuleTest() throws MapperException, BadResponseException {
- doReturn("test").when(MOCK_sdncClient).post(isA(GenericResourceApiVfModuleOperationInformation.class), isA(SDNCTopology.class));
-
+ public void activateVfModuleTest() throws MapperException {
+ doReturn(sdncReq).when(vfModuleTopologyMapper).reqMapper(SDNCSvcOperation.VF_MODULE_TOPOLOGY_OPERATION, SDNCSvcAction.ACTIVATE, vfModule, null,
+ vnf, serviceInstance, customer, cloudRegion, requestContext, null);
sdncVfModuleResources.activateVfModule(vfModule, vnf, serviceInstance, customer, cloudRegion, requestContext);
-
- verify(MOCK_sdncClient, times(1)).post(isA(GenericResourceApiVfModuleOperationInformation.class), eq(SDNCTopology.VFMODULE));
+ verify(vfModuleTopologyMapper, times(1)).reqMapper(SDNCSvcOperation.VF_MODULE_TOPOLOGY_OPERATION, SDNCSvcAction.ACTIVATE, vfModule, null,
+ vnf, serviceInstance, customer, cloudRegion, requestContext, null);
}
@Test
- public void deactivateVfModuleTest() throws MapperException, BadResponseException {
- doReturn("test").when(MOCK_sdncClient).post(isA(GenericResourceApiVfModuleOperationInformation.class), isA(SDNCTopology.class));
-
+ public void deactivateVfModuleTest() throws MapperException {
+ doReturn(sdncReq).when(vfModuleTopologyMapper).reqMapper(SDNCSvcOperation.VF_MODULE_TOPOLOGY_OPERATION, SDNCSvcAction.DEACTIVATE, vfModule, null,
+ vnf, serviceInstance, customer, cloudRegion, requestContext, null);
sdncVfModuleResources.deactivateVfModule(vfModule, vnf, serviceInstance, customer, cloudRegion, requestContext);
-
- verify(MOCK_sdncClient, times(1)).post(isA(GenericResourceApiVfModuleOperationInformation.class), eq(SDNCTopology.VFMODULE));
+ verify(vfModuleTopologyMapper, times(1)).reqMapper(SDNCSvcOperation.VF_MODULE_TOPOLOGY_OPERATION, SDNCSvcAction.DEACTIVATE, vfModule, null,
+ vnf, serviceInstance, customer, cloudRegion, requestContext, null);
}
@Test
public void changeAssignVfModuleTest() throws MapperException, BadResponseException {
- doReturn("test").when(MOCK_sdncClient).post(isA(GenericResourceApiVfModuleOperationInformation.class), isA(SDNCTopology.class));
-
+ doReturn(sdncReq).when(vfModuleTopologyMapper).reqMapper(SDNCSvcOperation.VF_MODULE_TOPOLOGY_OPERATION, SDNCSvcAction.CHANGE_ASSIGN, vfModule,
+ null, vnf, serviceInstance, customer, cloudRegion, requestContext, null);
sdncVfModuleResources.changeAssignVfModule(vfModule, vnf, serviceInstance, customer, cloudRegion, requestContext);
-
- verify(MOCK_sdncClient, times(1)).post(isA(GenericResourceApiVfModuleOperationInformation.class), eq(SDNCTopology.VFMODULE));
+ verify(vfModuleTopologyMapper, times(1)).reqMapper(SDNCSvcOperation.VF_MODULE_TOPOLOGY_OPERATION, SDNCSvcAction.CHANGE_ASSIGN, vfModule,
+ null, vnf, serviceInstance, customer, cloudRegion, requestContext, null);
}
}
diff --git a/bpmn/so-bpmn-tasks/src/test/java/org/onap/so/client/orchestration/SDNCVnfResourcesTest.java b/bpmn/so-bpmn-tasks/src/test/java/org/onap/so/client/orchestration/SDNCVnfResourcesTest.java
index 3329842924..9bbf790ecb 100644
--- a/bpmn/so-bpmn-tasks/src/test/java/org/onap/so/client/orchestration/SDNCVnfResourcesTest.java
+++ b/bpmn/so-bpmn-tasks/src/test/java/org/onap/so/client/orchestration/SDNCVnfResourcesTest.java
@@ -20,10 +20,9 @@
package org.onap.so.client.orchestration;
-import static org.junit.Assert.assertEquals;
import static org.mockito.ArgumentMatchers.any;
-import static org.mockito.Matchers.anyBoolean;
-import static org.mockito.Matchers.eq;
+import static org.mockito.ArgumentMatchers.anyBoolean;
+import static org.mockito.ArgumentMatchers.eq;
import static org.mockito.ArgumentMatchers.isA;
import static org.mockito.Mockito.doReturn;
import static org.mockito.Mockito.doThrow;
@@ -49,7 +48,6 @@ import org.onap.so.client.exception.MapperException;
import org.onap.so.client.sdnc.SDNCClient;
import org.onap.so.client.sdnc.beans.SDNCSvcAction;
import org.onap.so.client.sdnc.beans.SDNCSvcOperation;
-import org.onap.so.client.sdnc.endpoint.SDNCTopology;
import org.onap.so.client.sdnc.mapper.VnfTopologyOperationRequestMapper;
@RunWith(MockitoJUnitRunner.Silent.class)
@@ -73,112 +71,83 @@ public class SDNCVnfResourcesTest extends TestDataSetup{
@Before
public void before() {
serviceInstance = buildServiceInstance();
-
genericVnf = buildGenericVnf();
-
customer = buildCustomer();
-
cloudRegion = buildCloudRegion();
-
requestContext = buildRequestContext();
-
sdncReq = new GenericResourceApiVnfOperationInformation();
}
@Test
- public void assignVnfTest() throws MapperException, BadResponseException {
+ public void assignVnfTest() {
doReturn(sdncReq).when(MOCK_vnfTopologyOperationRequestMapper).reqMapper(isA(SDNCSvcOperation.class), isA(SDNCSvcAction.class),isA(GenericResourceApiRequestActionEnumeration.class), isA(GenericVnf.class), isA(ServiceInstance.class), isA(Customer.class), isA(CloudRegion.class), isA(RequestContext.class), anyBoolean());
-
sdncVnfResources.assignVnf(genericVnf, serviceInstance, customer, cloudRegion, requestContext, false);
-
verify(MOCK_vnfTopologyOperationRequestMapper, times(1)).reqMapper(isA(SDNCSvcOperation.class), isA(SDNCSvcAction.class),isA(GenericResourceApiRequestActionEnumeration.class), isA(GenericVnf.class), isA(ServiceInstance.class), isA(Customer.class), isA(CloudRegion.class), isA(RequestContext.class), anyBoolean());
}
@Test
- public void activateVnfTest() throws MapperException, BadResponseException {
+ public void activateVnfTest() {
doReturn(sdncReq).when(MOCK_vnfTopologyOperationRequestMapper).reqMapper(isA(SDNCSvcOperation.class), isA(SDNCSvcAction.class),isA(GenericResourceApiRequestActionEnumeration.class), isA(GenericVnf.class), isA(ServiceInstance.class), isA(Customer.class), isA(CloudRegion.class), isA(RequestContext.class), anyBoolean());
- doReturn("test").when(MOCK_sdncClient).post(isA(GenericResourceApiVnfOperationInformation.class), eq(SDNCTopology.VNF));
-
sdncVnfResources.activateVnf(genericVnf, serviceInstance, customer, cloudRegion, requestContext);
-
- verify(MOCK_sdncClient, times(1)).post(isA(GenericResourceApiVnfOperationInformation.class), eq(SDNCTopology.VNF));
+ verify(MOCK_vnfTopologyOperationRequestMapper, times(1)).reqMapper(isA(SDNCSvcOperation.class), isA(SDNCSvcAction.class),isA(GenericResourceApiRequestActionEnumeration.class), isA(GenericVnf.class), isA(ServiceInstance.class), isA(Customer.class), isA(CloudRegion.class), isA(RequestContext.class), anyBoolean());
}
@Test
- public void deleteVnfTest() throws MapperException, BadResponseException {
- doReturn(sdncReq).when(MOCK_vnfTopologyOperationRequestMapper).reqMapper(isA(SDNCSvcOperation.class), isA(SDNCSvcAction.class),isA(GenericResourceApiRequestActionEnumeration.class), isA(GenericVnf.class), isA(ServiceInstance.class), isA(Customer.class), isA(CloudRegion.class), isA(RequestContext.class), anyBoolean());
- doReturn("test").when(MOCK_sdncClient).post(isA(GenericResourceApiVnfOperationInformation.class), eq(SDNCTopology.VNF));
-
+ public void deleteVnfTest() {
+ doReturn(sdncReq).when(MOCK_vnfTopologyOperationRequestMapper).reqMapper(isA(SDNCSvcOperation.class), isA(SDNCSvcAction.class),isA(GenericResourceApiRequestActionEnumeration.class), isA(GenericVnf.class), isA(ServiceInstance.class), isA(Customer.class), isA(CloudRegion.class), isA(RequestContext.class), anyBoolean());
sdncVnfResources.deleteVnf(genericVnf, serviceInstance, customer, cloudRegion, requestContext);
-
- verify(MOCK_sdncClient, times(1)).post(isA(GenericResourceApiVnfOperationInformation.class), eq(SDNCTopology.VNF));
+ verify(MOCK_vnfTopologyOperationRequestMapper, times(1)).reqMapper(isA(SDNCSvcOperation.class), isA(SDNCSvcAction.class),isA(GenericResourceApiRequestActionEnumeration.class), isA(GenericVnf.class), isA(ServiceInstance.class), isA(Customer.class), isA(CloudRegion.class), isA(RequestContext.class), anyBoolean());
}
@Test
public void queryVnfTest() throws MapperException, BadResponseException {
doReturn("test").when(MOCK_sdncClient).get(isA(String.class));
-
genericVnf.setSelflink("testSelflink");
-
sdncVnfResources.queryVnf(genericVnf);
-
verify(MOCK_sdncClient, times(1)).get(isA(String.class));
}
@Test
public void queryVnfWithResourcePrefixTest() throws MapperException, BadResponseException {
doReturn("test").when(MOCK_sdncClient).get(isA(String.class));
-
genericVnf.setSelflink("restconf/test:testSelflink");
-
sdncVnfResources.queryVnf(genericVnf);
-
verify(MOCK_sdncClient, times(1)).get(isA(String.class));
}
@Test
- public void changeModelVnfTest() throws MapperException, BadResponseException {
+ public void changeModelVnfTest() {
doReturn(sdncReq).when(MOCK_vnfTopologyOperationRequestMapper).reqMapper(isA(SDNCSvcOperation.class), isA(SDNCSvcAction.class),isA(GenericResourceApiRequestActionEnumeration.class), isA(GenericVnf.class), isA(ServiceInstance.class), isA(Customer.class), isA(CloudRegion.class), isA(RequestContext.class), anyBoolean());
- doReturn("SDNCChangeModelVnfResponse").when(MOCK_sdncClient).post(isA(GenericResourceApiVnfOperationInformation.class), isA(SDNCTopology.class));
-
- String actualResponse = sdncVnfResources.changeModelVnf(genericVnf, serviceInstance, customer, cloudRegion, requestContext);
-
+ sdncVnfResources.changeModelVnf(genericVnf, serviceInstance, customer, cloudRegion, requestContext);
verify(MOCK_vnfTopologyOperationRequestMapper, times(1)).reqMapper(SDNCSvcOperation.VNF_TOPOLOGY_OPERATION, SDNCSvcAction.CHANGE_ASSIGN,GenericResourceApiRequestActionEnumeration.CREATEVNFINSTANCE, genericVnf, serviceInstance, customer, cloudRegion, requestContext, false);
- verify(MOCK_sdncClient, times(1)).post(sdncReq, SDNCTopology.VNF);
- assertEquals("SDNCChangeModelVnfResponse", actualResponse);
}
@Test
- public void deactivateVnfSuccessTest() throws Exception {
+ public void deactivateVnfSuccessTest() {
doReturn(sdncReq).when(MOCK_vnfTopologyOperationRequestMapper).reqMapper(eq(SDNCSvcOperation.VNF_TOPOLOGY_OPERATION), eq(SDNCSvcAction.DEACTIVATE),isA(GenericResourceApiRequestActionEnumeration.class), any(GenericVnf.class),any(ServiceInstance.class), any(Customer.class), any(CloudRegion.class),any(RequestContext.class), anyBoolean());
- doReturn("test").when(MOCK_sdncClient).post(any(GenericResourceApiVnfOperationInformation.class), eq(SDNCTopology.VNF));
sdncVnfResources.deactivateVnf(genericVnf, serviceInstance, customer, cloudRegion, requestContext);
- verify(MOCK_sdncClient, times(1)).post(any(GenericResourceApiVnfOperationInformation.class), eq(SDNCTopology.VNF));
+ verify(MOCK_vnfTopologyOperationRequestMapper, times(1)).reqMapper(eq(SDNCSvcOperation.VNF_TOPOLOGY_OPERATION), eq(SDNCSvcAction.DEACTIVATE),isA(GenericResourceApiRequestActionEnumeration.class), any(GenericVnf.class),any(ServiceInstance.class), any(Customer.class), any(CloudRegion.class),any(RequestContext.class), anyBoolean());
}
- @Test(expected = Exception.class)
- public void deactivateVnfExceptionTest() throws Exception {
- doReturn(sdncReq).when(MOCK_vnfTopologyOperationRequestMapper).reqMapper(eq(SDNCSvcOperation.VNF_TOPOLOGY_OPERATION), eq(SDNCSvcAction.DEACTIVATE),isA(GenericResourceApiRequestActionEnumeration.class), any(GenericVnf.class),any(ServiceInstance.class), any(Customer.class), any(CloudRegion.class),any(RequestContext.class), anyBoolean());
- doThrow(Exception.class).when(MOCK_sdncClient).post(any(GenericResourceApiVnfOperationInformation.class), eq(SDNCTopology.VNF));
+ @Test
+ public void deactivateVnfExceptionTest() {
+ expectedException.expect(Exception.class);
+ doThrow(Exception.class).when(MOCK_vnfTopologyOperationRequestMapper).reqMapper(eq(SDNCSvcOperation.VNF_TOPOLOGY_OPERATION), eq(SDNCSvcAction.DEACTIVATE),isA(GenericResourceApiRequestActionEnumeration.class), any(GenericVnf.class),any(ServiceInstance.class), any(Customer.class), any(CloudRegion.class),any(RequestContext.class), anyBoolean());
sdncVnfResources.deactivateVnf(genericVnf, serviceInstance, customer, cloudRegion, requestContext);
- verify(MOCK_sdncClient, times(1)).post(any(GenericResourceApiVnfOperationInformation.class), eq(SDNCTopology.VNF));
}
@Test
public void unassignVnfSuccessTest() throws Exception {
doReturn(sdncReq).when(MOCK_vnfTopologyOperationRequestMapper).reqMapper(eq(SDNCSvcOperation.VNF_TOPOLOGY_OPERATION), eq(SDNCSvcAction.UNASSIGN),isA(GenericResourceApiRequestActionEnumeration.class), any(GenericVnf.class),any(ServiceInstance.class), any(Customer.class), any(CloudRegion.class),any(RequestContext.class), anyBoolean());
- doReturn("test").when(MOCK_sdncClient).post(any(GenericResourceApiVnfOperationInformation.class), eq(SDNCTopology.VNF));
sdncVnfResources.unassignVnf(genericVnf, serviceInstance, customer, cloudRegion, requestContext);
- verify(MOCK_sdncClient, times(1)).post(any(GenericResourceApiVnfOperationInformation.class), eq(SDNCTopology.VNF));
+ verify(MOCK_vnfTopologyOperationRequestMapper, times(1)).reqMapper(eq(SDNCSvcOperation.VNF_TOPOLOGY_OPERATION), eq(SDNCSvcAction.UNASSIGN),isA(GenericResourceApiRequestActionEnumeration.class), any(GenericVnf.class),any(ServiceInstance.class), any(Customer.class), any(CloudRegion.class),any(RequestContext.class), anyBoolean());
}
- @Test(expected = Exception.class)
+ @Test
public void unassignVnfExceptionTest() throws Exception {
- doReturn(sdncReq).when(MOCK_vnfTopologyOperationRequestMapper).reqMapper(eq(SDNCSvcOperation.VNF_TOPOLOGY_OPERATION), eq(SDNCSvcAction.UNASSIGN),isA(GenericResourceApiRequestActionEnumeration.class), any(GenericVnf.class),any(ServiceInstance.class), any(Customer.class), any(CloudRegion.class),any(RequestContext.class), anyBoolean());
- doThrow(Exception.class).when(MOCK_sdncClient).post(any(GenericResourceApiVnfOperationInformation.class), eq(SDNCTopology.VNF));
+ expectedException.expect(Exception.class);
+ doThrow(Exception.class).when(MOCK_vnfTopologyOperationRequestMapper).reqMapper(eq(SDNCSvcOperation.VNF_TOPOLOGY_OPERATION), eq(SDNCSvcAction.UNASSIGN),isA(GenericResourceApiRequestActionEnumeration.class), any(GenericVnf.class),any(ServiceInstance.class), any(Customer.class), any(CloudRegion.class),any(RequestContext.class), anyBoolean());
sdncVnfResources.unassignVnf(genericVnf, serviceInstance, customer, cloudRegion, requestContext);
- //verify(client, times(1)).post(any(GenericResourceApiServiceOperationInformation.class), eq(SDNCTopology.VNF));
}
-
}