aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--bpmn/so-bpmn-building-blocks/src/main/resources/subprocess/BuildingBlock/AssignVnfBB.bpmn100
-rw-r--r--bpmn/so-bpmn-building-blocks/src/test/java/org/onap/so/bpmn/infrastructure/bpmn/subprocess/AssignVnfBBTest.java4
-rw-r--r--bpmn/so-bpmn-infrastructure-common/src/main/groovy/org/onap/so/bpmn/infrastructure/scripts/ReplaceVnfInfra.groovy6
-rw-r--r--bpmn/so-bpmn-infrastructure-common/src/main/groovy/org/onap/so/bpmn/infrastructure/scripts/UpdateVfModuleInfraV2.groovy6
-rw-r--r--bpmn/so-bpmn-infrastructure-common/src/main/groovy/org/onap/so/bpmn/infrastructure/scripts/UpdateVnfInfra.groovy6
-rw-r--r--bpmn/so-bpmn-infrastructure-common/src/main/groovy/org/onap/so/bpmn/infrastructure/scripts/VnfCmBase.groovy6
-rw-r--r--bpmn/so-bpmn-infrastructure-common/src/main/groovy/org/onap/so/bpmn/infrastructure/scripts/VnfConfigUpdate.groovy6
-rw-r--r--bpmn/so-bpmn-infrastructure-common/src/main/groovy/org/onap/so/bpmn/infrastructure/scripts/VnfInPlaceUpdate.groovy6
-rw-r--r--bpmn/so-bpmn-infrastructure-flows/src/main/resources/process/CreateVcpeResCustService_simplified.bpmn195
-rw-r--r--bpmn/so-bpmn-tasks/src/main/java/org/onap/so/bpmn/infrastructure/sdnc/tasks/SDNCAssignTasks.java10
-rw-r--r--bpmn/so-bpmn-tasks/src/main/java/org/onap/so/client/orchestration/SDNCVnfResources.java5
-rw-r--r--bpmn/so-bpmn-tasks/src/test/java/org/onap/so/bpmn/infrastructure/sdnc/tasks/SDNCAssignTasksTest.java9
-rw-r--r--bpmn/so-bpmn-tasks/src/test/java/org/onap/so/client/orchestration/SDNCVnfResourcesTest.java3
-rw-r--r--common/src/main/java/org/onap/so/client/aai/AAIRestClientI.java2
-rw-r--r--common/src/main/java/org/onap/so/client/aai/AAIRestClientImpl.java2
-rw-r--r--common/src/main/java/org/onap/so/client/aai/AAIValidator.java4
-rw-r--r--common/src/main/java/org/onap/so/client/aai/AAIValidatorImpl.java6
-rw-r--r--common/src/test/java/org/onap/so/client/aai/AAIValidatorTest.java16
18 files changed, 253 insertions, 139 deletions
diff --git a/bpmn/so-bpmn-building-blocks/src/main/resources/subprocess/BuildingBlock/AssignVnfBB.bpmn b/bpmn/so-bpmn-building-blocks/src/main/resources/subprocess/BuildingBlock/AssignVnfBB.bpmn
index cf284e8ed9..0a067483ff 100644
--- a/bpmn/so-bpmn-building-blocks/src/main/resources/subprocess/BuildingBlock/AssignVnfBB.bpmn
+++ b/bpmn/so-bpmn-building-blocks/src/main/resources/subprocess/BuildingBlock/AssignVnfBB.bpmn
@@ -4,9 +4,9 @@
<bpmn:startEvent id="Start_AssignVnfBB">
<bpmn:outgoing>SequenceFlow_0zaz9o2</bpmn:outgoing>
</bpmn:startEvent>
- <bpmn:serviceTask id="Task_SDNCAdapterVnfTopologyAssign" name="&#10;SDNC &#10;Assign&#10;(vnf)&#10;" camunda:expression="${SDNCAssignTasks.assignVnf(InjectExecution.execute(execution, execution.getVariable(&#34;gBuildingBlockExecution&#34;)))}">
- <bpmn:incoming>SequenceFlow_14mpqit</bpmn:incoming>
- <bpmn:outgoing>SequenceFlow_1ks8kmt</bpmn:outgoing>
+ <bpmn:serviceTask id="Task_SDNCAdapterVnfTopologyAssign" name="&#10;SDNC &#10;Create Request&#10;(vnf)&#10;" camunda:expression="${SDNCAssignTasks.assignVnf(InjectExecution.execute(execution, execution.getVariable(&#34;gBuildingBlockExecution&#34;)))}">
+ <bpmn:incoming>SequenceFlow_1samncw</bpmn:incoming>
+ <bpmn:outgoing>SequenceFlow_1qkhm79</bpmn:outgoing>
</bpmn:serviceTask>
<bpmn:endEvent id="End_AssignVnfBB">
<bpmn:incoming>SequenceFlow_0csh9dc</bpmn:incoming>
@@ -16,10 +16,9 @@
<bpmn:outgoing>SequenceFlow_1jwsja5</bpmn:outgoing>
</bpmn:serviceTask>
<bpmn:sequenceFlow id="SequenceFlow_0zaz9o2" sourceRef="Start_AssignVnfBB" targetRef="Task_CreateVnf" />
- <bpmn:sequenceFlow id="SequenceFlow_1ks8kmt" sourceRef="Task_SDNCAdapterVnfTopologyAssign" targetRef="Task_UpdateVnfOrchestrationStatusAssigned" />
<bpmn:sequenceFlow id="SequenceFlow_0csh9dc" sourceRef="Task_UpdateVnfOrchestrationStatusAssigned" targetRef="End_AssignVnfBB" />
<bpmn:serviceTask id="Task_UpdateVnfOrchestrationStatusAssigned" name="&#10;AAI&#10;Update&#10;(vnf)&#10;" camunda:expression="${AAIUpdateTasks.updateOrchestrationStatusAssignedVnf(InjectExecution.execute(execution, execution.getVariable(&#34;gBuildingBlockExecution&#34;)))}">
- <bpmn:incoming>SequenceFlow_1ks8kmt</bpmn:incoming>
+ <bpmn:incoming>SequenceFlow_1vw20wu</bpmn:incoming>
<bpmn:outgoing>SequenceFlow_0csh9dc</bpmn:outgoing>
</bpmn:serviceTask>
<bpmn:serviceTask id="Task_createInstanceGroups" name="&#10;AAI&#10;Create&#10;(instance grp)&#10;" camunda:expression="${AssignVnf.createInstanceGroups(InjectExecution.execute(execution, execution.getVariable(&#34;gBuildingBlockExecution&#34;)))}">
@@ -28,11 +27,9 @@
</bpmn:serviceTask>
<bpmn:sequenceFlow id="SequenceFlow_1jwsja5" sourceRef="Task_CreateVnf" targetRef="Task_createPlatform" />
<bpmn:sequenceFlow id="SequenceFlow_1nle8kc" sourceRef="Task_createInstanceGroups" targetRef="ExclusiveGateway_02tchpp" />
- <bpmn:sequenceFlow id="SequenceFlow_11jum90" name="no" sourceRef="ExclusiveGateway_02tchpp" targetRef="ExclusiveGateway_1blf52g">
- <bpmn:conditionExpression xsi:type="bpmn:tFormalExpression"><![CDATA[${execution.getVariable("callHoming") == false}]]></bpmn:conditionExpression>
- </bpmn:sequenceFlow>
+ <bpmn:sequenceFlow id="SequenceFlow_11jum90" name="no" sourceRef="ExclusiveGateway_02tchpp" targetRef="ExclusiveGateway_1blf52g" />
<bpmn:sequenceFlow id="SequenceFlow_1uiok7v" name="yes" sourceRef="ExclusiveGateway_02tchpp" targetRef="Task_callHoming">
- <bpmn:conditionExpression xsi:type="bpmn:tFormalExpression"><![CDATA[${execution.getVariable("callHoming") == true}]]></bpmn:conditionExpression>
+ <bpmn:conditionExpression xsi:type="bpmn:tFormalExpression"><![CDATA[${execution.getVariable("callHoming")}]]></bpmn:conditionExpression>
</bpmn:sequenceFlow>
<bpmn:sequenceFlow id="SequenceFlow_0v8d14a" sourceRef="Task_callHoming" targetRef="ExclusiveGateway_1blf52g" />
<bpmn:callActivity id="Task_callHoming" name="Call Homing" calledElement="HomingBB">
@@ -40,6 +37,7 @@
<camunda:in source="gBuildingBlockExecution" target="gBuildingBlockExecution" />
<camunda:in source="mso-request-id" target="mso-request-id" />
<camunda:out source="generalBuildingBlock" target="gBBInput" />
+ <camunda:out source="WorkflowException" target="WorkflowException" />
</bpmn:extensionElements>
<bpmn:incoming>SequenceFlow_1uiok7v</bpmn:incoming>
<bpmn:outgoing>SequenceFlow_0v8d14a</bpmn:outgoing>
@@ -65,8 +63,7 @@
</bpmn:endEvent>
<bpmn:sequenceFlow id="SequenceFlow_1i52a7x" sourceRef="StartEvent_1c3cyuv" targetRef="EndEvent_1bywujf" />
</bpmn:subProcess>
- <bpmn:sequenceFlow id="SequenceFlow_14mpqit" sourceRef="ExclusiveGateway_1blf52g" targetRef="Task_SDNCAdapterVnfTopologyAssign" />
- <bpmn:inclusiveGateway id="ExclusiveGateway_02tchpp" name="Call Homing?">
+ <bpmn:inclusiveGateway id="ExclusiveGateway_02tchpp" name="Call Homing?" default="SequenceFlow_11jum90">
<bpmn:incoming>SequenceFlow_1nle8kc</bpmn:incoming>
<bpmn:outgoing>SequenceFlow_11jum90</bpmn:outgoing>
<bpmn:outgoing>SequenceFlow_1uiok7v</bpmn:outgoing>
@@ -74,8 +71,19 @@
<bpmn:inclusiveGateway id="ExclusiveGateway_1blf52g">
<bpmn:incoming>SequenceFlow_11jum90</bpmn:incoming>
<bpmn:incoming>SequenceFlow_0v8d14a</bpmn:incoming>
- <bpmn:outgoing>SequenceFlow_14mpqit</bpmn:outgoing>
+ <bpmn:outgoing>SequenceFlow_1samncw</bpmn:outgoing>
</bpmn:inclusiveGateway>
+ <bpmn:callActivity id="CallActivity_sdncAssign" name="SDNC Assign (vnf)" calledElement="SDNCHandler">
+ <bpmn:extensionElements>
+ <camunda:in source="SDNCRequest" target="SDNCRequest" />
+ <camunda:out source="SDNCResponse" target="SDNCResponse" />
+ </bpmn:extensionElements>
+ <bpmn:incoming>SequenceFlow_1qkhm79</bpmn:incoming>
+ <bpmn:outgoing>SequenceFlow_1vw20wu</bpmn:outgoing>
+ </bpmn:callActivity>
+ <bpmn:sequenceFlow id="SequenceFlow_1samncw" sourceRef="ExclusiveGateway_1blf52g" targetRef="Task_SDNCAdapterVnfTopologyAssign" />
+ <bpmn:sequenceFlow id="SequenceFlow_1qkhm79" sourceRef="Task_SDNCAdapterVnfTopologyAssign" targetRef="CallActivity_sdncAssign" />
+ <bpmn:sequenceFlow id="SequenceFlow_1vw20wu" sourceRef="CallActivity_sdncAssign" targetRef="Task_UpdateVnfOrchestrationStatusAssigned" />
</bpmn:process>
<bpmn:error id="Error_0rgauy1" name="gDelegateError" errorCode="7000" />
<bpmndi:BPMNDiagram id="BPMNDiagram_1">
@@ -90,9 +98,9 @@
<dc:Bounds x="930" y="94" width="100" height="80" />
</bpmndi:BPMNShape>
<bpmndi:BPMNShape id="EndEvent_1h93h9d_di" bpmnElement="End_AssignVnfBB">
- <dc:Bounds x="1229" y="116" width="36" height="36" />
+ <dc:Bounds x="1323" y="116" width="36" height="36" />
<bpmndi:BPMNLabel>
- <dc:Bounds x="1238" y="156" width="18" height="12" />
+ <dc:Bounds x="1296" y="156" width="90" height="12" />
</bpmndi:BPMNLabel>
</bpmndi:BPMNShape>
<bpmndi:BPMNShape id="ServiceTask_1r380lg_di" bpmnElement="Task_CreateVnf">
@@ -105,22 +113,15 @@
<dc:Bounds x="83" y="113" width="90" height="12" />
</bpmndi:BPMNLabel>
</bpmndi:BPMNEdge>
- <bpmndi:BPMNEdge id="SequenceFlow_1ks8kmt_di" bpmnElement="SequenceFlow_1ks8kmt">
- <di:waypoint xsi:type="dc:Point" x="1030" y="134" />
- <di:waypoint xsi:type="dc:Point" x="1056" y="134" />
- <bpmndi:BPMNLabel>
- <dc:Bounds x="998" y="113" width="90" height="12" />
- </bpmndi:BPMNLabel>
- </bpmndi:BPMNEdge>
<bpmndi:BPMNEdge id="SequenceFlow_0csh9dc_di" bpmnElement="SequenceFlow_0csh9dc">
- <di:waypoint xsi:type="dc:Point" x="1156" y="134" />
- <di:waypoint xsi:type="dc:Point" x="1229" y="134" />
+ <di:waypoint xsi:type="dc:Point" x="1303" y="134" />
+ <di:waypoint xsi:type="dc:Point" x="1323" y="134" />
<bpmndi:BPMNLabel>
- <dc:Bounds x="1147.5" y="113" width="90" height="12" />
+ <dc:Bounds x="1268" y="113" width="90" height="12" />
</bpmndi:BPMNLabel>
</bpmndi:BPMNEdge>
<bpmndi:BPMNShape id="ServiceTask_0s6d1be_di" bpmnElement="Task_UpdateVnfOrchestrationStatusAssigned">
- <dc:Bounds x="1056" y="94" width="100" height="80" />
+ <dc:Bounds x="1203" y="94" width="100" height="80" />
</bpmndi:BPMNShape>
<bpmndi:BPMNShape id="ServiceTask_0wjy7za_di" bpmnElement="Task_createInstanceGroups">
<dc:Bounds x="534" y="94" width="100" height="80" />
@@ -188,38 +189,31 @@
<dc:Bounds x="404" y="94" width="100" height="80" />
</bpmndi:BPMNShape>
<bpmndi:BPMNShape id="SubProcess_19596dp_di" bpmnElement="SubProcess_19596dp" isExpanded="true">
- <dc:Bounds x="249" y="267" width="231" height="135" />
+ <dc:Bounds x="673" y="239" width="231" height="135" />
</bpmndi:BPMNShape>
<bpmndi:BPMNShape id="StartEvent_1c3cyuv_di" bpmnElement="StartEvent_1c3cyuv">
- <dc:Bounds x="286" y="323" width="36" height="36" />
+ <dc:Bounds x="710" y="295" width="36" height="36" />
<bpmndi:BPMNLabel>
- <dc:Bounds x="259" y="359" width="0" height="12" />
+ <dc:Bounds x="638" y="331" width="90" height="12" />
</bpmndi:BPMNLabel>
</bpmndi:BPMNShape>
<bpmndi:BPMNShape id="EndEvent_1bywujf_di" bpmnElement="EndEvent_1bywujf">
- <dc:Bounds x="422" y="323" width="36" height="36" />
+ <dc:Bounds x="846" y="295" width="36" height="36" />
<bpmndi:BPMNLabel>
- <dc:Bounds x="395" y="359" width="0" height="12" />
+ <dc:Bounds x="774" y="331" width="90" height="12" />
</bpmndi:BPMNLabel>
</bpmndi:BPMNShape>
<bpmndi:BPMNEdge id="SequenceFlow_1i52a7x_di" bpmnElement="SequenceFlow_1i52a7x">
- <di:waypoint xsi:type="dc:Point" x="322" y="341" />
- <di:waypoint xsi:type="dc:Point" x="422" y="341" />
+ <di:waypoint xsi:type="dc:Point" x="746" y="313" />
+ <di:waypoint xsi:type="dc:Point" x="846" y="313" />
<bpmndi:BPMNLabel>
- <dc:Bounds x="372" y="320" width="0" height="12" />
- </bpmndi:BPMNLabel>
- </bpmndi:BPMNEdge>
- <bpmndi:BPMNEdge id="SequenceFlow_14mpqit_di" bpmnElement="SequenceFlow_14mpqit">
- <di:waypoint xsi:type="dc:Point" x="899" y="134" />
- <di:waypoint xsi:type="dc:Point" x="930" y="134" />
- <bpmndi:BPMNLabel>
- <dc:Bounds x="914.5" y="113" width="0" height="12" />
+ <dc:Bounds x="751" y="292" width="90" height="12" />
</bpmndi:BPMNLabel>
</bpmndi:BPMNEdge>
<bpmndi:BPMNShape id="InclusiveGateway_0x0c3kk_di" bpmnElement="ExclusiveGateway_02tchpp">
<dc:Bounds x="679" y="109" width="50" height="50" />
<bpmndi:BPMNLabel>
- <dc:Bounds x="731" y="128" width="67" height="13" />
+ <dc:Bounds x="732" y="128" width="64" height="12" />
</bpmndi:BPMNLabel>
</bpmndi:BPMNShape>
<bpmndi:BPMNShape id="InclusiveGateway_0ijggth_di" bpmnElement="ExclusiveGateway_1blf52g">
@@ -228,6 +222,30 @@
<dc:Bounds x="896" y="163" width="0" height="12" />
</bpmndi:BPMNLabel>
</bpmndi:BPMNShape>
+ <bpmndi:BPMNShape id="CallActivity_12uxg1m_di" bpmnElement="CallActivity_sdncAssign">
+ <dc:Bounds x="1060" y="94" width="100" height="80" />
+ </bpmndi:BPMNShape>
+ <bpmndi:BPMNEdge id="SequenceFlow_1samncw_di" bpmnElement="SequenceFlow_1samncw">
+ <di:waypoint xsi:type="dc:Point" x="899" y="134" />
+ <di:waypoint xsi:type="dc:Point" x="930" y="134" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="914.5" y="113" width="0" height="12" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNEdge>
+ <bpmndi:BPMNEdge id="SequenceFlow_1qkhm79_di" bpmnElement="SequenceFlow_1qkhm79">
+ <di:waypoint xsi:type="dc:Point" x="1030" y="134" />
+ <di:waypoint xsi:type="dc:Point" x="1060" y="134" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="1045" y="113" width="0" height="12" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNEdge>
+ <bpmndi:BPMNEdge id="SequenceFlow_1vw20wu_di" bpmnElement="SequenceFlow_1vw20wu">
+ <di:waypoint xsi:type="dc:Point" x="1160" y="134" />
+ <di:waypoint xsi:type="dc:Point" x="1203" y="134" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="1181.5" y="113" width="0" height="12" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNEdge>
</bpmndi:BPMNPlane>
</bpmndi:BPMNDiagram>
</bpmn:definitions>
diff --git a/bpmn/so-bpmn-building-blocks/src/test/java/org/onap/so/bpmn/infrastructure/bpmn/subprocess/AssignVnfBBTest.java b/bpmn/so-bpmn-building-blocks/src/test/java/org/onap/so/bpmn/infrastructure/bpmn/subprocess/AssignVnfBBTest.java
index 3fb8faa6c8..f675440ead 100644
--- a/bpmn/so-bpmn-building-blocks/src/test/java/org/onap/so/bpmn/infrastructure/bpmn/subprocess/AssignVnfBBTest.java
+++ b/bpmn/so-bpmn-building-blocks/src/test/java/org/onap/so/bpmn/infrastructure/bpmn/subprocess/AssignVnfBBTest.java
@@ -35,11 +35,11 @@ public class AssignVnfBBTest extends BaseBPMNTest {
@Test
public void sunnyDayAssignVnfBBTest() throws InterruptedException, IOException {
variables.put("callHoming", true);
- mockSubprocess("ReceiveWorkflowMessage", "Mocked ReceiveWorkflowMessage", "GenericStub");
+ mockSubprocess("SDNCHandler", "My Mock Process Name", "GenericStub");
ProcessInstance pi = runtimeService.startProcessInstanceByKey("AssignVnfBB", variables);
assertThat(pi).isNotNull();
assertThat(pi).isStarted().hasPassedInOrder("Start_AssignVnfBB", "Task_CreateVnf", "Task_createPlatform", "Task_createLineOfBusiness", "Task_createInstanceGroups",
- "Task_callHoming", "Task_SDNCAdapterVnfTopologyAssign", "Task_UpdateVnfOrchestrationStatusAssigned",
+ "Task_callHoming", "Task_SDNCAdapterVnfTopologyAssign","CallActivity_sdncAssign", "Task_UpdateVnfOrchestrationStatusAssigned",
"End_AssignVnfBB");
assertThat(pi).isEnded();
}
diff --git a/bpmn/so-bpmn-infrastructure-common/src/main/groovy/org/onap/so/bpmn/infrastructure/scripts/ReplaceVnfInfra.groovy b/bpmn/so-bpmn-infrastructure-common/src/main/groovy/org/onap/so/bpmn/infrastructure/scripts/ReplaceVnfInfra.groovy
index f45e97fa6e..3a20992bdb 100644
--- a/bpmn/so-bpmn-infrastructure-common/src/main/groovy/org/onap/so/bpmn/infrastructure/scripts/ReplaceVnfInfra.groovy
+++ b/bpmn/so-bpmn-infrastructure-common/src/main/groovy/org/onap/so/bpmn/infrastructure/scripts/ReplaceVnfInfra.groovy
@@ -341,12 +341,11 @@ public class ReplaceVnfInfra extends VnfCmBase {
msoLogger.trace('Entered ' + method)
try {
- def transactionLoggingUuid = UUID.randomUUID().toString()
AAIRestClientImpl client = new AAIRestClientImpl()
AAIValidatorImpl aaiValidator = new AAIValidatorImpl()
aaiValidator.setClient(client)
def vnfId = execution.getVariable("vnfId")
- boolean isInMaint = aaiValidator.isVNFLocked(vnfId, transactionLoggingUuid)
+ boolean isInMaint = aaiValidator.isVNFLocked(vnfId)
msoLogger.debug("isInMaint result: " + isInMaint)
execution.setVariable('isVnfInMaintenance', isInMaint)
@@ -385,12 +384,11 @@ public class ReplaceVnfInfra extends VnfCmBase {
execution.setVariable("failedActivity", "AAI")
try {
- def transactionLoggingUuid = UUID.randomUUID().toString()
AAIRestClientImpl client = new AAIRestClientImpl()
AAIValidatorImpl aaiValidator = new AAIValidatorImpl()
aaiValidator.setClient(client)
def vnfId = execution.getVariable("vnfId")
- boolean areLocked = aaiValidator.isPhysicalServerLocked(vnfId, transactionLoggingUuid)
+ boolean areLocked = aaiValidator.isPhysicalServerLocked(vnfId)
msoLogger.debug("areLocked result: " + areLocked)
execution.setVariable('arePserversLocked', areLocked)
diff --git a/bpmn/so-bpmn-infrastructure-common/src/main/groovy/org/onap/so/bpmn/infrastructure/scripts/UpdateVfModuleInfraV2.groovy b/bpmn/so-bpmn-infrastructure-common/src/main/groovy/org/onap/so/bpmn/infrastructure/scripts/UpdateVfModuleInfraV2.groovy
index 0972ee184e..1a8df1664f 100644
--- a/bpmn/so-bpmn-infrastructure-common/src/main/groovy/org/onap/so/bpmn/infrastructure/scripts/UpdateVfModuleInfraV2.groovy
+++ b/bpmn/so-bpmn-infrastructure-common/src/main/groovy/org/onap/so/bpmn/infrastructure/scripts/UpdateVfModuleInfraV2.groovy
@@ -285,9 +285,8 @@ public class UpdateVfModuleInfraV2 {
System.out.println("*****************************CheckingPserverFlag*************************")
String vnfId = (String)execution.getVariable('vnfId')
- String uuid = (String)execution.getVariable('moduleUuid')
AAIValidatorImpl aaiVI = new AAIValidatorImpl()
- boolean flag = aaiVI.isPhysicalServerLocked(vnfId, uuid)
+ boolean flag = aaiVI.isPhysicalServerLocked(vnfId)
}
//check to see if the VFFlag is locked
@@ -295,9 +294,8 @@ public class UpdateVfModuleInfraV2 {
System.out.print("*****************************VfFlagCheck*************************")
String vnfId = (String)execution.getVariable('vnfId')
- String uuid = (String)execution.getVariable('moduleUuid')
AAIValidatorImpl aaiVI = new AAIValidatorImpl()
- boolean flag = aaiVI.isVNFLocked(vnfId, uuid)
+ boolean flag = aaiVI.isVNFLocked(vnfId)
}
//lock the VF Flag
diff --git a/bpmn/so-bpmn-infrastructure-common/src/main/groovy/org/onap/so/bpmn/infrastructure/scripts/UpdateVnfInfra.groovy b/bpmn/so-bpmn-infrastructure-common/src/main/groovy/org/onap/so/bpmn/infrastructure/scripts/UpdateVnfInfra.groovy
index 4978faf46c..8c1df9b2e7 100644
--- a/bpmn/so-bpmn-infrastructure-common/src/main/groovy/org/onap/so/bpmn/infrastructure/scripts/UpdateVnfInfra.groovy
+++ b/bpmn/so-bpmn-infrastructure-common/src/main/groovy/org/onap/so/bpmn/infrastructure/scripts/UpdateVnfInfra.groovy
@@ -321,12 +321,11 @@ public class UpdateVnfInfra extends VnfCmBase {
msoLogger.trace('Entered ' + method)
try {
- def transactionLoggingUuid = UUID.randomUUID().toString()
AAIRestClientImpl client = new AAIRestClientImpl()
AAIValidatorImpl aaiValidator = new AAIValidatorImpl()
aaiValidator.setClient(client)
def vnfId = execution.getVariable("vnfId")
- boolean isInMaint = aaiValidator.isVNFLocked(vnfId, transactionLoggingUuid)
+ boolean isInMaint = aaiValidator.isVNFLocked(vnfId)
msoLogger.debug("isInMaint result: " + isInMaint)
execution.setVariable('isVnfInMaintenance', isInMaint)
@@ -365,12 +364,11 @@ public class UpdateVnfInfra extends VnfCmBase {
execution.setVariable("failedActivity", "AAI")
try {
- def transactionLoggingUuid = UUID.randomUUID().toString()
AAIRestClientImpl client = new AAIRestClientImpl()
AAIValidatorImpl aaiValidator = new AAIValidatorImpl()
aaiValidator.setClient(client)
def vnfId = execution.getVariable("vnfId")
- boolean areLocked = aaiValidator.isPhysicalServerLocked(vnfId, transactionLoggingUuid)
+ boolean areLocked = aaiValidator.isPhysicalServerLocked(vnfId)
msoLogger.debug("areLocked result: " + areLocked)
execution.setVariable('arePserversLocked', areLocked)
diff --git a/bpmn/so-bpmn-infrastructure-common/src/main/groovy/org/onap/so/bpmn/infrastructure/scripts/VnfCmBase.groovy b/bpmn/so-bpmn-infrastructure-common/src/main/groovy/org/onap/so/bpmn/infrastructure/scripts/VnfCmBase.groovy
index fd9d9cc8a3..ae89fa52dd 100644
--- a/bpmn/so-bpmn-infrastructure-common/src/main/groovy/org/onap/so/bpmn/infrastructure/scripts/VnfCmBase.groovy
+++ b/bpmn/so-bpmn-infrastructure-common/src/main/groovy/org/onap/so/bpmn/infrastructure/scripts/VnfCmBase.groovy
@@ -167,12 +167,11 @@ public abstract class VnfCmBase extends AbstractServiceTaskProcessor {
msoLogger.trace('Entered ' + method)
try {
- def transactionLoggingUuid = UUID.randomUUID().toString()
AAIRestClientImpl client = new AAIRestClientImpl()
AAIValidatorImpl aaiValidator = new AAIValidatorImpl()
aaiValidator.setClient(client)
def vnfId = execution.getVariable("vnfId")
- boolean isInMaint = aaiValidator.isVNFLocked(vnfId, transactionLoggingUuid)
+ boolean isInMaint = aaiValidator.isVNFLocked(vnfId)
msoLogger.debug("isInMaint result: " + isInMaint)
execution.setVariable('isVnfInMaintenance', isInMaint)
@@ -355,12 +354,11 @@ public abstract class VnfCmBase extends AbstractServiceTaskProcessor {
execution.setVariable("failedActivity", "AAI")
try {
- def transactionLoggingUuid = UUID.randomUUID().toString()
AAIRestClientImpl client = new AAIRestClientImpl()
AAIValidatorImpl aaiValidator = new AAIValidatorImpl()
aaiValidator.setClient(client)
def vnfId = execution.getVariable("vnfId")
- boolean areLocked = aaiValidator.isPhysicalServerLocked(vnfId, transactionLoggingUuid)
+ boolean areLocked = aaiValidator.isPhysicalServerLocked(vnfId)
msoLogger.debug("areLocked result: " + areLocked)
execution.setVariable('arePserversLocked', areLocked)
diff --git a/bpmn/so-bpmn-infrastructure-common/src/main/groovy/org/onap/so/bpmn/infrastructure/scripts/VnfConfigUpdate.groovy b/bpmn/so-bpmn-infrastructure-common/src/main/groovy/org/onap/so/bpmn/infrastructure/scripts/VnfConfigUpdate.groovy
index 8ca2871916..7de3359f51 100644
--- a/bpmn/so-bpmn-infrastructure-common/src/main/groovy/org/onap/so/bpmn/infrastructure/scripts/VnfConfigUpdate.groovy
+++ b/bpmn/so-bpmn-infrastructure-common/src/main/groovy/org/onap/so/bpmn/infrastructure/scripts/VnfConfigUpdate.groovy
@@ -219,12 +219,11 @@ public class VnfConfigUpdate extends VnfCmBase {
msoLogger.trace('Entered ' + method)
try {
- def transactionLoggingUuid = UUID.randomUUID().toString()
AAIRestClientImpl client = new AAIRestClientImpl()
AAIValidatorImpl aaiValidator = new AAIValidatorImpl()
aaiValidator.setClient(client)
def vnfId = execution.getVariable("vnfId")
- boolean isInMaint = aaiValidator.isVNFLocked(vnfId, transactionLoggingUuid)
+ boolean isInMaint = aaiValidator.isVNFLocked(vnfId)
msoLogger.debug("isInMaint result: " + isInMaint)
execution.setVariable('isVnfInMaintenance', isInMaint)
@@ -262,12 +261,11 @@ public class VnfConfigUpdate extends VnfCmBase {
execution.setVariable("failedActivity", "AAI")
try {
- def transactionLoggingUuid = UUID.randomUUID().toString()
AAIRestClientImpl client = new AAIRestClientImpl()
AAIValidatorImpl aaiValidator = new AAIValidatorImpl()
aaiValidator.setClient(client)
def vnfId = execution.getVariable("vnfId")
- boolean areLocked = aaiValidator.isPhysicalServerLocked(vnfId, transactionLoggingUuid)
+ boolean areLocked = aaiValidator.isPhysicalServerLocked(vnfId)
msoLogger.debug("areLocked result: " + areLocked)
execution.setVariable('arePserversLocked', areLocked)
diff --git a/bpmn/so-bpmn-infrastructure-common/src/main/groovy/org/onap/so/bpmn/infrastructure/scripts/VnfInPlaceUpdate.groovy b/bpmn/so-bpmn-infrastructure-common/src/main/groovy/org/onap/so/bpmn/infrastructure/scripts/VnfInPlaceUpdate.groovy
index 2c1b66ded5..f6788fb745 100644
--- a/bpmn/so-bpmn-infrastructure-common/src/main/groovy/org/onap/so/bpmn/infrastructure/scripts/VnfInPlaceUpdate.groovy
+++ b/bpmn/so-bpmn-infrastructure-common/src/main/groovy/org/onap/so/bpmn/infrastructure/scripts/VnfInPlaceUpdate.groovy
@@ -240,12 +240,11 @@ public class VnfInPlaceUpdate extends VnfCmBase {
msoLogger.trace('Entered ' + method)
try {
- def transactionLoggingUuid = UUID.randomUUID().toString()
AAIRestClientImpl client = new AAIRestClientImpl()
AAIValidatorImpl aaiValidator = new AAIValidatorImpl()
aaiValidator.setClient(client)
def vnfId = execution.getVariable("vnfId")
- boolean isInMaint = aaiValidator.isVNFLocked(vnfId, transactionLoggingUuid)
+ boolean isInMaint = aaiValidator.isVNFLocked(vnfId)
msoLogger.debug("isInMaint result: " + isInMaint)
execution.setVariable('isVnfInMaintenance', isInMaint)
@@ -284,12 +283,11 @@ public class VnfInPlaceUpdate extends VnfCmBase {
execution.setVariable("failedActivity", "AAI")
try {
- def transactionLoggingUuid = UUID.randomUUID().toString()
AAIRestClientImpl client = new AAIRestClientImpl()
AAIValidatorImpl aaiValidator = new AAIValidatorImpl()
aaiValidator.setClient(client)
def vnfId = execution.getVariable("vnfId")
- boolean areLocked = aaiValidator.isPhysicalServerLocked(vnfId, transactionLoggingUuid)
+ boolean areLocked = aaiValidator.isPhysicalServerLocked(vnfId)
msoLogger.debug("areLocked result: " + areLocked)
execution.setVariable('arePserversLocked', areLocked)
diff --git a/bpmn/so-bpmn-infrastructure-flows/src/main/resources/process/CreateVcpeResCustService_simplified.bpmn b/bpmn/so-bpmn-infrastructure-flows/src/main/resources/process/CreateVcpeResCustService_simplified.bpmn
index 3b1c56628e..02b564e81f 100644
--- a/bpmn/so-bpmn-infrastructure-flows/src/main/resources/process/CreateVcpeResCustService_simplified.bpmn
+++ b/bpmn/so-bpmn-infrastructure-flows/src/main/resources/process/CreateVcpeResCustService_simplified.bpmn
@@ -315,7 +315,7 @@ CreateVcpeResCustService.postProcessRollback(execution)]]></bpmn2:script>
<bpmn2:sequenceFlow id="SequenceFlow_0afe2pg" sourceRef="setPONR_ScriptTask" targetRef="postProcessAndCompletionRequest_ScriptTask" />
<bpmn2:intermediateThrowEvent id="IntermediateThrowEvent_0prlju0" name="GoTo StartService">
<bpmn2:incoming>SequenceFlow_11efpvh</bpmn2:incoming>
- <bpmn2:linkEventDefinition name="CreateAllottedResourcesBRG" />
+ <bpmn2:linkEventDefinition name="StartService" />
</bpmn2:intermediateThrowEvent>
<bpmn2:callActivity id="DecomposeService" name="Call Decompose Service" calledElement="DecomposeService">
<bpmn2:extensionElements>
@@ -339,9 +339,9 @@ CreateVcpeResCustService.prepareDecomposeService(execution)]]></bpmn2:script>
<bpmn2:sequenceFlow id="SequenceFlow_1eu60rt" sourceRef="IntermediateCatchEvent_3" targetRef="ScriptTask_0cdtchu" />
<bpmn2:sequenceFlow id="SequenceFlow_00h6hmd" sourceRef="ScriptTask_0cdtchu" targetRef="DecomposeService" />
<bpmn2:sequenceFlow id="SequenceFlow_17g05fd" sourceRef="DecomposeService" targetRef="ScriptTask_0lpv2da" />
- <bpmn2:intermediateCatchEvent id="IntermediateCatchEvent_17pzn7m" name="CreateAllottedResourcesBRG">
+ <bpmn2:intermediateCatchEvent id="IntermediateCatchEvent_17pzn7m" name="PnfCreateAndActivate">
<bpmn2:outgoing>SequenceFlow_0gj4vud</bpmn2:outgoing>
- <bpmn2:linkEventDefinition name="CreateAllottedResourcesBRG" />
+ <bpmn2:linkEventDefinition name="PnfCreateAndActivate" />
</bpmn2:intermediateCatchEvent>
<bpmn2:intermediateThrowEvent id="IntermediateThrowEvent_0lt5ltv" name="GoToFinishProcess">
<bpmn2:incoming>SequenceFlow_0clhseq</bpmn2:incoming>
@@ -366,25 +366,75 @@ CreateVcpeResCustService.processDecomposition(execution)]]></bpmn2:script>
<bpmn2:incoming>SequenceFlow_0gj4vud</bpmn2:incoming>
<bpmn2:outgoing>SequenceFlow_0clhseq</bpmn2:outgoing>
</bpmn2:callActivity>
+ <bpmn2:callActivity id="CallActivity_1vc4jeh" name="Call Create &#10;ServiceInstance&#10;" calledElement="DoCreateServiceInstance">
+ <bpmn2:extensionElements>
+ <camunda:in source="msoRequestId" target="msoRequestId" />
+ <camunda:in source="globalSubscriberId" target="globalSubscriberId" />
+ <camunda:in source="subscriptionServiceType" target="subscriptionServiceType" />
+ <camunda:in source="serviceInstanceId" target="serviceInstanceId" />
+ <camunda:out source="rollbackData" target="DCRESI_rollbackData" />
+ <camunda:in source="serviceInstanceName" target="serviceInstanceName" />
+ <camunda:in source="serviceModelInfo" target="serviceModelInfo" />
+ <camunda:in source="failIfExists" target="failIfExists" />
+ <camunda:in source="disableRollback" target="disableRollback" />
+ <camunda:in source="serviceInputParams" target="serviceInputParams" />
+ <camunda:out source="rolledBack" target="rolledBack" />
+ <camunda:out source="WorkflowException" target="WorkflowException" />
+ <camunda:out source="serviceInstanceName" target="serviceInstanceName" />
+ <camunda:in source="isDebugLogEnabled" target="isDebugLogEnabled" />
+ <camunda:in source="subscriptionServiceType" target="subscriptionServiceType" />
+ <camunda:in source="productFamilyId" target="productFamilyId" />
+ <camunda:in source="sdncVersion" target="sdncVersion" />
+ <camunda:in source="bpmnRequest" target="requestJson" />
+ </bpmn2:extensionElements>
+ <bpmn2:incoming>SequenceFlow_0bt420h</bpmn2:incoming>
+ <bpmn2:outgoing>SequenceFlow_0ocy2qp</bpmn2:outgoing>
+ </bpmn2:callActivity>
+ <bpmn2:scriptTask id="ScriptTask_1y241p8" name="Prepare&#10;Create&#10;Service&#10;" scriptFormat="groovy">
+ <bpmn2:incoming>SequenceFlow_1429lyc</bpmn2:incoming>
+ <bpmn2:outgoing>SequenceFlow_0bt420h</bpmn2:outgoing>
+ <bpmn2:script><![CDATA[import org.onap.so.bpmn.vcpe.scripts.*
+def CreateVcpeResCustService = new CreateVcpeResCustService()
+CreateVcpeResCustService.prepareCreateServiceInstance(execution)]]></bpmn2:script>
+ </bpmn2:scriptTask>
+ <bpmn2:scriptTask id="ScriptTask_1y5lvl7" name="Post Process&#10;Create&#10;Service&#10;" scriptFormat="groovy">
+ <bpmn2:incoming>SequenceFlow_0ocy2qp</bpmn2:incoming>
+ <bpmn2:outgoing>SequenceFlow_11gw54u</bpmn2:outgoing>
+ <bpmn2:script><![CDATA[import org.onap.so.bpmn.vcpe.scripts.*
+def CreateVcpeResCustService = new CreateVcpeResCustService()
+CreateVcpeResCustService.postProcessServiceInstanceCreate(execution)]]></bpmn2:script>
+ </bpmn2:scriptTask>
+ <bpmn2:intermediateCatchEvent id="IntermediateCatchEvent_0m5yuay" name="StartService">
+ <bpmn2:outgoing>SequenceFlow_1429lyc</bpmn2:outgoing>
+ <bpmn2:linkEventDefinition name="StartService" />
+ </bpmn2:intermediateCatchEvent>
+ <bpmn2:intermediateThrowEvent id="IntermediateThrowEvent_13xv36r" name="Go To PnfCreateAndActivate">
+ <bpmn2:incoming>SequenceFlow_11gw54u</bpmn2:incoming>
+ <bpmn2:linkEventDefinition name="PnfCreateAndActivate" />
+ </bpmn2:intermediateThrowEvent>
+ <bpmn2:sequenceFlow id="SequenceFlow_0bt420h" sourceRef="ScriptTask_1y241p8" targetRef="CallActivity_1vc4jeh" />
+ <bpmn2:sequenceFlow id="SequenceFlow_0ocy2qp" sourceRef="CallActivity_1vc4jeh" targetRef="ScriptTask_1y5lvl7" />
+ <bpmn2:sequenceFlow id="SequenceFlow_1429lyc" sourceRef="IntermediateCatchEvent_0m5yuay" targetRef="ScriptTask_1y241p8" />
+ <bpmn2:sequenceFlow id="SequenceFlow_11gw54u" sourceRef="ScriptTask_1y5lvl7" targetRef="IntermediateThrowEvent_13xv36r" />
</bpmn2:process>
<bpmn2:error id="Error_2" name="MSOWorkflowException" errorCode="MSOWorkflowException" />
<bpmn2:error id="Error_1" name="java.lang.Exception" errorCode="java.lang.Exception" />
<bpmndi:BPMNDiagram id="BPMNDiagram_1">
<bpmndi:BPMNPlane id="BPMNPlane_1" bpmnElement="CreateVcpeResCustService_simplified">
<bpmndi:BPMNShape id="_BPMNShape_StartEvent_47" bpmnElement="createVCPE_startEvent">
- <dc:Bounds x="67" y="920" width="36" height="36" />
+ <dc:Bounds x="67" y="811" width="36" height="36" />
<bpmndi:BPMNLabel>
- <dc:Bounds x="61" y="961" width="50" height="12" />
+ <dc:Bounds x="61" y="852" width="50" height="12" />
</bpmndi:BPMNLabel>
</bpmndi:BPMNShape>
<bpmndi:BPMNShape id="_BPMNShape_ScriptTask_61" bpmnElement="preProcessRequest_ScriptTask">
- <dc:Bounds x="256" y="898" width="100" height="80" />
+ <dc:Bounds x="256" y="789" width="100" height="80" />
</bpmndi:BPMNShape>
<bpmndi:BPMNEdge id="BPMNEdge_SequenceFlow_1" bpmnElement="SequenceFlow_1" sourceElement="_BPMNShape_StartEvent_47" targetElement="_BPMNShape_ScriptTask_61">
- <di:waypoint xsi:type="dc:Point" x="103" y="938" />
- <di:waypoint xsi:type="dc:Point" x="256" y="938" />
+ <di:waypoint xsi:type="dc:Point" x="103" y="829" />
+ <di:waypoint xsi:type="dc:Point" x="256" y="829" />
<bpmndi:BPMNLabel>
- <dc:Bounds x="100" y="938" width="90" height="0" />
+ <dc:Bounds x="100" y="829" width="90" height="0" />
</bpmndi:BPMNLabel>
</bpmndi:BPMNEdge>
<bpmndi:BPMNShape id="_BPMNShape_CallActivity_4" bpmnElement="callCompleteMsoProcess_CallActivity">
@@ -394,14 +444,14 @@ CreateVcpeResCustService.processDecomposition(execution)]]></bpmn2:script>
<dc:Bounds x="490" y="1432" width="100" height="80" />
</bpmndi:BPMNShape>
<bpmndi:BPMNEdge id="BPMNEdge_SequenceFlow_12" bpmnElement="SequenceFlow_7" sourceElement="_BPMNShape_ScriptTask_61" targetElement="_BPMNShape_ScriptTask_127">
- <di:waypoint xsi:type="dc:Point" x="356" y="938" />
- <di:waypoint xsi:type="dc:Point" x="447" y="938" />
+ <di:waypoint xsi:type="dc:Point" x="356" y="829" />
+ <di:waypoint xsi:type="dc:Point" x="447" y="829" />
<bpmndi:BPMNLabel>
- <dc:Bounds x="200" y="899" width="90" height="0" />
+ <dc:Bounds x="200" y="790" width="90" height="0" />
</bpmndi:BPMNLabel>
</bpmndi:BPMNEdge>
<bpmndi:BPMNShape id="_BPMNShape_ScriptTask_127" bpmnElement="sendSyncAckResponse_ScriptTask">
- <dc:Bounds x="447" y="898" width="100" height="80" />
+ <dc:Bounds x="447" y="789" width="100" height="80" />
</bpmndi:BPMNShape>
<bpmndi:BPMNEdge id="BPMNEdge_SequenceFlow_42" bpmnElement="SequenceFlow_29" sourceElement="_BPMNShape_ScriptTask_80" targetElement="_BPMNShape_CallActivity_4">
<di:waypoint xsi:type="dc:Point" x="590" y="1472" />
@@ -458,10 +508,10 @@ CreateVcpeResCustService.processDecomposition(execution)]]></bpmn2:script>
</bpmndi:BPMNLabel>
</bpmndi:BPMNEdge>
<bpmndi:BPMNEdge id="BPMNEdge_SequenceFlow_2" bpmnElement="SequenceFlow_3" sourceElement="_BPMNShape_ScriptTask_127">
- <di:waypoint xsi:type="dc:Point" x="547" y="938" />
- <di:waypoint xsi:type="dc:Point" x="699" y="938" />
+ <di:waypoint xsi:type="dc:Point" x="547" y="829" />
+ <di:waypoint xsi:type="dc:Point" x="699" y="829" />
<bpmndi:BPMNLabel>
- <dc:Bounds x="578" y="923" width="90" height="0" />
+ <dc:Bounds x="578" y="814" width="90" height="0" />
</bpmndi:BPMNLabel>
</bpmndi:BPMNEdge>
<bpmndi:BPMNShape id="_BPMNShape_ScriptTask_337" bpmnElement="ScriptTask_2">
@@ -475,9 +525,9 @@ CreateVcpeResCustService.processDecomposition(execution)]]></bpmn2:script>
</bpmndi:BPMNLabel>
</bpmndi:BPMNEdge>
<bpmndi:BPMNShape id="_BPMNShape_IntermediateCatchEvent_35" bpmnElement="IntermediateCatchEvent_3">
- <dc:Bounds x="67" y="1075" width="36" height="36" />
+ <dc:Bounds x="67" y="966" width="36" height="36" />
<bpmndi:BPMNLabel>
- <dc:Bounds x="43" y="1111" width="85" height="12" />
+ <dc:Bounds x="43" y="1002" width="85" height="12" />
</bpmndi:BPMNLabel>
</bpmndi:BPMNShape>
<bpmndi:BPMNShape id="_BPMNShape_IntermediateCatchEvent_36" bpmnElement="IntermediateCatchEvent_4">
@@ -487,9 +537,9 @@ CreateVcpeResCustService.processDecomposition(execution)]]></bpmn2:script>
</bpmndi:BPMNLabel>
</bpmndi:BPMNShape>
<bpmndi:BPMNShape id="_BPMNShape_IntermediateThrowEvent_49" bpmnElement="IntermediateThrowEvent_2">
- <dc:Bounds x="699" y="920" width="36" height="36" />
+ <dc:Bounds x="699" y="811" width="36" height="36" />
<bpmndi:BPMNLabel>
- <dc:Bounds x="687" y="961" width="59" height="24" />
+ <dc:Bounds x="687" y="852" width="59" height="24" />
</bpmndi:BPMNLabel>
</bpmndi:BPMNShape>
<bpmndi:BPMNShape id="SubProcess_0s6hpty_di" bpmnElement="SubProcess_0s6hpty" isExpanded="true">
@@ -628,9 +678,9 @@ CreateVcpeResCustService.processDecomposition(execution)]]></bpmn2:script>
</bpmndi:BPMNLabel>
</bpmndi:BPMNEdge>
<bpmndi:BPMNShape id="IntermediateThrowEvent_0prlju0_di" bpmnElement="IntermediateThrowEvent_0prlju0">
- <dc:Bounds x="1036" y="1075" width="36" height="36" />
+ <dc:Bounds x="902" y="966" width="36" height="36" />
<bpmndi:BPMNLabel>
- <dc:Bounds x="1009" y="1116" width="90" height="12" />
+ <dc:Bounds x="875" y="1007" width="90" height="12" />
</bpmndi:BPMNLabel>
</bpmndi:BPMNShape>
<bpmndi:BPMNShape id="ExclusiveGateway_05indeh_di" bpmnElement="ExclusiveGateway_05indeh" isMarkerVisible="true">
@@ -676,23 +726,23 @@ CreateVcpeResCustService.processDecomposition(execution)]]></bpmn2:script>
</bpmndi:BPMNLabel>
</bpmndi:BPMNEdge>
<bpmndi:BPMNShape id="CallActivity_0w2alah_di" bpmnElement="DecomposeService">
- <dc:Bounds x="447" y="1053" width="100" height="80" />
+ <dc:Bounds x="447" y="944" width="100" height="80" />
</bpmndi:BPMNShape>
<bpmndi:BPMNShape id="ScriptTask_0cdtchu_di" bpmnElement="ScriptTask_0cdtchu">
- <dc:Bounds x="256" y="1053" width="100" height="80" />
+ <dc:Bounds x="256" y="944" width="100" height="80" />
</bpmndi:BPMNShape>
<bpmndi:BPMNEdge id="SequenceFlow_1eu60rt_di" bpmnElement="SequenceFlow_1eu60rt">
- <di:waypoint xsi:type="dc:Point" x="103" y="1093" />
- <di:waypoint xsi:type="dc:Point" x="256" y="1093" />
+ <di:waypoint xsi:type="dc:Point" x="103" y="984" />
+ <di:waypoint xsi:type="dc:Point" x="256" y="984" />
<bpmndi:BPMNLabel>
- <dc:Bounds x="135" y="1078" width="90" height="0" />
+ <dc:Bounds x="135" y="969" width="90" height="0" />
</bpmndi:BPMNLabel>
</bpmndi:BPMNEdge>
<bpmndi:BPMNEdge id="SequenceFlow_00h6hmd_di" bpmnElement="SequenceFlow_00h6hmd">
- <di:waypoint xsi:type="dc:Point" x="356" y="1093" />
- <di:waypoint xsi:type="dc:Point" x="447" y="1093" />
+ <di:waypoint xsi:type="dc:Point" x="356" y="984" />
+ <di:waypoint xsi:type="dc:Point" x="447" y="984" />
<bpmndi:BPMNLabel>
- <dc:Bounds x="357" y="1078" width="90" height="0" />
+ <dc:Bounds x="357" y="969" width="90" height="0" />
</bpmndi:BPMNLabel>
</bpmndi:BPMNEdge>
<bpmndi:BPMNShape id="ExclusiveGateway_06gq6em_di" bpmnElement="ExclusiveGateway_06gq6em" isMarkerVisible="true">
@@ -795,10 +845,10 @@ CreateVcpeResCustService.processDecomposition(execution)]]></bpmn2:script>
</bpmndi:BPMNLabel>
</bpmndi:BPMNEdge>
<bpmndi:BPMNEdge id="SequenceFlow_17g05fd_di" bpmnElement="SequenceFlow_17g05fd">
- <di:waypoint xsi:type="dc:Point" x="547" y="1093" />
- <di:waypoint xsi:type="dc:Point" x="638" y="1093" />
+ <di:waypoint xsi:type="dc:Point" x="547" y="984" />
+ <di:waypoint xsi:type="dc:Point" x="638" y="984" />
<bpmndi:BPMNLabel>
- <dc:Bounds x="548" y="1078" width="90" height="0" />
+ <dc:Bounds x="548" y="969" width="90" height="0" />
</bpmndi:BPMNLabel>
</bpmndi:BPMNEdge>
<bpmndi:BPMNShape id="ExclusiveGateway_0y7gtd9_di" bpmnElement="ExclusiveGateway_0y7gtd9" isMarkerVisible="true">
@@ -867,15 +917,15 @@ CreateVcpeResCustService.processDecomposition(execution)]]></bpmn2:script>
</bpmndi:BPMNLabel>
</bpmndi:BPMNEdge>
<bpmndi:BPMNShape id="IntermediateCatchEvent_17pzn7m_di" bpmnElement="IntermediateCatchEvent_17pzn7m">
- <dc:Bounds x="83" y="1259" width="36" height="36" />
+ <dc:Bounds x="67" y="1259" width="36" height="36" />
<bpmndi:BPMNLabel>
- <dc:Bounds x="58" y="1295" width="78" height="24" />
+ <dc:Bounds x="42" y="1295" width="88" height="24" />
</bpmndi:BPMNLabel>
</bpmndi:BPMNShape>
<bpmndi:BPMNShape id="IntermediateThrowEvent_0lt5ltv_di" bpmnElement="IntermediateThrowEvent_0lt5ltv">
- <dc:Bounds x="670" y="1259" width="36" height="36" />
+ <dc:Bounds x="466" y="1259" width="36" height="36" />
<bpmndi:BPMNLabel>
- <dc:Bounds x="645" y="1306" width="85" height="24" />
+ <dc:Bounds x="441" y="1306" width="85" height="24" />
</bpmndi:BPMNLabel>
</bpmndi:BPMNShape>
<bpmndi:BPMNShape id="CallActivity_071yaf8_di" bpmnElement="CallActivity_071yaf8">
@@ -944,32 +994,81 @@ CreateVcpeResCustService.processDecomposition(execution)]]></bpmn2:script>
</bpmndi:BPMNLabel>
</bpmndi:BPMNEdge>
<bpmndi:BPMNShape id="ScriptTask_0lpv2da_di" bpmnElement="ScriptTask_0lpv2da">
- <dc:Bounds x="638" y="1053" width="100" height="80" />
+ <dc:Bounds x="638" y="944" width="100" height="80" />
</bpmndi:BPMNShape>
<bpmndi:BPMNEdge id="SequenceFlow_11efpvh_di" bpmnElement="SequenceFlow_11efpvh">
- <di:waypoint xsi:type="dc:Point" x="738" y="1093" />
- <di:waypoint xsi:type="dc:Point" x="1036" y="1093" />
+ <di:waypoint xsi:type="dc:Point" x="738" y="984" />
+ <di:waypoint xsi:type="dc:Point" x="902" y="984" />
<bpmndi:BPMNLabel>
- <dc:Bounds x="842" y="1072" width="90" height="12" />
+ <dc:Bounds x="775" y="963" width="90" height="12" />
</bpmndi:BPMNLabel>
</bpmndi:BPMNEdge>
<bpmndi:BPMNEdge id="SequenceFlow_0gj4vud_di" bpmnElement="SequenceFlow_0gj4vud">
- <di:waypoint xsi:type="dc:Point" x="119" y="1277" />
- <di:waypoint xsi:type="dc:Point" x="345" y="1277" />
+ <di:waypoint xsi:type="dc:Point" x="103" y="1277" />
+ <di:waypoint xsi:type="dc:Point" x="256" y="1277" />
<bpmndi:BPMNLabel>
- <dc:Bounds x="187" y="1257" width="90" height="10" />
+ <dc:Bounds x="134.5" y="1257" width="90" height="10" />
</bpmndi:BPMNLabel>
</bpmndi:BPMNEdge>
<bpmndi:BPMNEdge id="SequenceFlow_0clhseq_di" bpmnElement="SequenceFlow_0clhseq">
- <di:waypoint xsi:type="dc:Point" x="445" y="1277" />
- <di:waypoint xsi:type="dc:Point" x="670" y="1277" />
+ <di:waypoint xsi:type="dc:Point" x="356" y="1277" />
+ <di:waypoint xsi:type="dc:Point" x="466" y="1277" />
<bpmndi:BPMNLabel>
- <dc:Bounds x="513" y="1257" width="90" height="10" />
+ <dc:Bounds x="366" y="1257" width="90" height="10" />
</bpmndi:BPMNLabel>
</bpmndi:BPMNEdge>
<bpmndi:BPMNShape id="CallActivity_1totpg4_di" bpmnElement="Task_14l19kv">
- <dc:Bounds x="345" y="1237" width="100" height="80" />
+ <dc:Bounds x="256" y="1237" width="100" height="80" />
+ </bpmndi:BPMNShape>
+ <bpmndi:BPMNShape id="CallActivity_1vc4jeh_di" bpmnElement="CallActivity_1vc4jeh">
+ <dc:Bounds x="447" y="1072" width="100" height="80" />
+ </bpmndi:BPMNShape>
+ <bpmndi:BPMNShape id="ScriptTask_1y241p8_di" bpmnElement="ScriptTask_1y241p8">
+ <dc:Bounds x="256" y="1072" width="100" height="80" />
+ </bpmndi:BPMNShape>
+ <bpmndi:BPMNShape id="ScriptTask_1y5lvl7_di" bpmnElement="ScriptTask_1y5lvl7">
+ <dc:Bounds x="638" y="1072" width="100" height="80" />
</bpmndi:BPMNShape>
+ <bpmndi:BPMNShape id="IntermediateCatchEvent_0m5yuay_di" bpmnElement="IntermediateCatchEvent_0m5yuay">
+ <dc:Bounds x="65" y="1094" width="36" height="36" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="53" y="1130" width="60" height="12" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNShape>
+ <bpmndi:BPMNShape id="IntermediateThrowEvent_13xv36r_di" bpmnElement="IntermediateThrowEvent_13xv36r">
+ <dc:Bounds x="902" y="1094" width="36" height="36" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="877" y="1135" width="88" height="36" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNShape>
+ <bpmndi:BPMNEdge id="SequenceFlow_0bt420h_di" bpmnElement="SequenceFlow_0bt420h">
+ <di:waypoint xsi:type="dc:Point" x="356" y="1112" />
+ <di:waypoint xsi:type="dc:Point" x="447" y="1112" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="356.5" y="1091" width="90" height="12" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNEdge>
+ <bpmndi:BPMNEdge id="SequenceFlow_0ocy2qp_di" bpmnElement="SequenceFlow_0ocy2qp">
+ <di:waypoint xsi:type="dc:Point" x="547" y="1112" />
+ <di:waypoint xsi:type="dc:Point" x="638" y="1112" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="547.5" y="1091" width="90" height="12" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNEdge>
+ <bpmndi:BPMNEdge id="SequenceFlow_1429lyc_di" bpmnElement="SequenceFlow_1429lyc">
+ <di:waypoint xsi:type="dc:Point" x="101" y="1112" />
+ <di:waypoint xsi:type="dc:Point" x="256" y="1112" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="133.5" y="1091" width="90" height="12" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNEdge>
+ <bpmndi:BPMNEdge id="SequenceFlow_11gw54u_di" bpmnElement="SequenceFlow_11gw54u">
+ <di:waypoint xsi:type="dc:Point" x="738" y="1112" />
+ <di:waypoint xsi:type="dc:Point" x="902" y="1112" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="775" y="1091" width="90" height="12" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNEdge>
</bpmndi:BPMNPlane>
</bpmndi:BPMNDiagram>
</bpmn2:definitions>
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 ec79b2825a..30f38fc2ed 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,7 @@
package org.onap.so.bpmn.infrastructure.sdnc.tasks;
+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;
@@ -38,6 +39,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;
@@ -79,8 +82,11 @@ public class SDNCAssignTasks {
GenericVnf vnf = extractPojosForBB.extractByKey(execution, ResourceKey.GENERIC_VNF_ID, execution.getLookupMap().get(ResourceKey.GENERIC_VNF_ID));
Customer customer = gBBInput.getCustomer();
CloudRegion cloudRegion = gBBInput.getCloudRegion();
- String response = sdncVnfResources.assignVnf(vnf, serviceInstance, customer, cloudRegion, requestContext, Boolean.TRUE.equals(vnf.isCallHoming()));
- execution.setVariable("SDNCResponse", response);
+ GenericResourceApiVnfOperationInformation req = sdncVnfResources.assignVnf(vnf, serviceInstance, customer, cloudRegion, requestContext, Boolean.TRUE.equals(vnf.isCallHoming()));
+ SDNCRequest sdncRequest = new SDNCRequest();
+ sdncRequest.setSDNCPayload(req);
+ sdncRequest.setTopology(SDNCTopology.VNF);
+ 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/SDNCVnfResources.java b/bpmn/so-bpmn-tasks/src/main/java/org/onap/so/client/orchestration/SDNCVnfResources.java
index f8a9390398..b30fc932c0 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
@@ -48,12 +48,11 @@ public class SDNCVnfResources {
@Autowired
private SDNCClient sdncClient;
- public String assignVnf(GenericVnf vnf, ServiceInstance serviceInstance, Customer customer,
+ public GenericResourceApiVnfOperationInformation assignVnf(GenericVnf vnf, ServiceInstance serviceInstance, Customer customer,
CloudRegion cloudRegion, RequestContext requestContext, boolean homing)
throws MapperException, BadResponseException {
- GenericResourceApiVnfOperationInformation sdncReq = sdncRM.reqMapper(SDNCSvcOperation.VNF_TOPOLOGY_OPERATION,
+ return sdncRM.reqMapper(SDNCSvcOperation.VNF_TOPOLOGY_OPERATION,
SDNCSvcAction.ASSIGN,GenericResourceApiRequestActionEnumeration.CREATEVNFINSTANCE, vnf, serviceInstance, customer, cloudRegion, requestContext, homing);
- return sdncClient.post(sdncReq, SDNCTopology.VNF);
}
public String activateVnf(GenericVnf vnf, ServiceInstance serviceInstance, Customer customer,
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 dcfc20c3ae..24ae88b98c 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
@@ -20,6 +20,7 @@
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;
@@ -34,6 +35,7 @@ import org.junit.Before;
import org.junit.Test;
import org.mockito.ArgumentMatchers;
import org.mockito.InjectMocks;
+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;
@@ -46,6 +48,8 @@ import org.onap.so.bpmn.servicedecomposition.bbobjects.VolumeGroup;
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.client.sdnc.beans.SDNCRequest;
+import org.onap.so.client.sdnc.endpoint.SDNCTopology;
public class SDNCAssignTasksTest extends BaseTaskTest{
@@ -102,13 +106,14 @@ public class SDNCAssignTasksTest extends BaseTaskTest{
@Test
public void assignVnfTest() throws Exception {
- doReturn("response").when(sdncVnfResources).assignVnf(genericVnf, serviceInstance, customer, cloudRegion, requestContext, false);
+ 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);
- assertTrue(execution.getVariable("SDNCResponse").equals("response"));
+ SDNCRequest sdncRequest = execution.getVariable("SDNCRequest");
+ assertEquals(SDNCTopology.VNF,sdncRequest.getTopology());
}
@Test
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 bb8fca4719..3329842924 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
@@ -88,11 +88,10 @@ public class SDNCVnfResourcesTest extends TestDataSetup{
@Test
public void assignVnfTest() 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));
sdncVnfResources.assignVnf(genericVnf, serviceInstance, customer, cloudRegion, requestContext, false);
- 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
diff --git a/common/src/main/java/org/onap/so/client/aai/AAIRestClientI.java b/common/src/main/java/org/onap/so/client/aai/AAIRestClientI.java
index 831e43841a..52f15c45c4 100644
--- a/common/src/main/java/org/onap/so/client/aai/AAIRestClientI.java
+++ b/common/src/main/java/org/onap/so/client/aai/AAIRestClientI.java
@@ -33,7 +33,7 @@ public interface AAIRestClientI {
void updateMaintenceFlagVnfId(String vnfId, boolean inMaint, String transactionLoggingUuid) throws Exception;
- GenericVnf getVnfByName(String vnfId, String transactionLoggingUuid) throws Exception;
+ GenericVnf getVnfByName(String vnfId);
Optional<Pnf> getPnfByName(String pnfId, String transactionLoggingUuid) throws Exception;
diff --git a/common/src/main/java/org/onap/so/client/aai/AAIRestClientImpl.java b/common/src/main/java/org/onap/so/client/aai/AAIRestClientImpl.java
index bcc7d8ba16..813421ff80 100644
--- a/common/src/main/java/org/onap/so/client/aai/AAIRestClientImpl.java
+++ b/common/src/main/java/org/onap/so/client/aai/AAIRestClientImpl.java
@@ -75,7 +75,7 @@ public class AAIRestClientImpl implements AAIRestClientI {
}
@Override
- public GenericVnf getVnfByName(String vnfId, String transactionLoggingUuid) {
+ public GenericVnf getVnfByName(String vnfId) {
return new AAIResourcesClient(ENDPOINT_VERSION)
.get(GenericVnf.class, AAIUriFactory.createResourceUri(AAIObjectType.GENERIC_VNF, vnfId)).orElse(null);
}
diff --git a/common/src/main/java/org/onap/so/client/aai/AAIValidator.java b/common/src/main/java/org/onap/so/client/aai/AAIValidator.java
index bf6485a631..18252d548b 100644
--- a/common/src/main/java/org/onap/so/client/aai/AAIValidator.java
+++ b/common/src/main/java/org/onap/so/client/aai/AAIValidator.java
@@ -24,9 +24,9 @@ import java.io.IOException;
public interface AAIValidator {
- boolean isPhysicalServerLocked(String hostName, String transactionLoggingUuid) throws IOException;
+ boolean isPhysicalServerLocked(String hostName) throws IOException;
- boolean isVNFLocked(String vnfId, String transactionLoggingUuid) throws IOException, Exception;
+ boolean isVNFLocked(String vnfId);
} \ No newline at end of file
diff --git a/common/src/main/java/org/onap/so/client/aai/AAIValidatorImpl.java b/common/src/main/java/org/onap/so/client/aai/AAIValidatorImpl.java
index e416da172c..6ece8a2620 100644
--- a/common/src/main/java/org/onap/so/client/aai/AAIValidatorImpl.java
+++ b/common/src/main/java/org/onap/so/client/aai/AAIValidatorImpl.java
@@ -46,7 +46,7 @@ public class AAIValidatorImpl implements AAIValidator {
}
@Override
- public boolean isPhysicalServerLocked(String vnfId, String transactionLoggingUuid) throws IOException {
+ public boolean isPhysicalServerLocked(String vnfId) throws IOException {
List<Pserver> pservers;
boolean isLocked = false;
pservers = client.getPhysicalServerByVnfId(vnfId);
@@ -58,9 +58,9 @@ public class AAIValidatorImpl implements AAIValidator {
}
@Override
- public boolean isVNFLocked(String vnfId, String transactionLoggingUuid) throws Exception {
+ public boolean isVNFLocked(String vnfId) {
boolean isLocked = false;
- GenericVnf genericVnf = client.getVnfByName(vnfId, transactionLoggingUuid);
+ GenericVnf genericVnf = client.getVnfByName(vnfId);
if (genericVnf.isInMaint())
isLocked = true;
diff --git a/common/src/test/java/org/onap/so/client/aai/AAIValidatorTest.java b/common/src/test/java/org/onap/so/client/aai/AAIValidatorTest.java
index 63c7290065..f32633122d 100644
--- a/common/src/test/java/org/onap/so/client/aai/AAIValidatorTest.java
+++ b/common/src/test/java/org/onap/so/client/aai/AAIValidatorTest.java
@@ -66,28 +66,28 @@ public class AAIValidatorTest {
@Test
public void test_IsPhysicalServerLocked_True() throws IOException{
when(client.getPhysicalServerByVnfId(vnfName)).thenReturn(getPservers(true));
- boolean locked = validator.isPhysicalServerLocked(vnfName, uuid);
+ boolean locked = validator.isPhysicalServerLocked(vnfName);
assertEquals(true, locked);
}
@Test
public void test_IsPhysicalServerLocked_False() throws IOException {
when(client.getPhysicalServerByVnfId(vnfName)).thenReturn(getPservers(false));
- boolean locked = validator.isPhysicalServerLocked(vnfName, uuid);
+ boolean locked = validator.isPhysicalServerLocked(vnfName);
assertEquals(false, locked);
}
@Test
- public void test_IsVNFLocked_False() throws Exception{
- when(client.getVnfByName(vnfName,uuid)).thenReturn(createGenericVnfs(false));
- boolean locked = validator.isVNFLocked(vnfName, uuid);
+ public void test_IsVNFLocked_False() {
+ when(client.getVnfByName(vnfName)).thenReturn(createGenericVnfs(false));
+ boolean locked = validator.isVNFLocked(vnfName);
assertEquals(false, locked);
}
@Test
- public void test_IsVNFLocked_True() throws Exception{
- when(client.getVnfByName(vnfName,uuid)).thenReturn(createGenericVnfs(true));
- boolean locked = validator.isVNFLocked(vnfName, uuid);
+ public void test_IsVNFLocked_True() {
+ when(client.getVnfByName(vnfName)).thenReturn(createGenericVnfs(true));
+ boolean locked = validator.isVNFLocked(vnfName);
assertEquals(true,locked );
}
}