summaryrefslogtreecommitdiffstats
path: root/bpmn
diff options
context:
space:
mode:
authorLukasz Muszkieta <lukasz.muszkieta@nokia.com>2020-06-22 13:20:53 +0000
committerGerrit Code Review <gerrit@onap.org>2020-06-22 13:20:53 +0000
commit49e00e08dbbe4fcb6be9a7c4b9580918cc8f04f9 (patch)
tree045a06620dc2072b10d508cdd2fd0859349fccbc /bpmn
parent0abec191b0645a80c9bc5df4af3423a9377b83db (diff)
parentc4c9f922fa9ae3549f307677d307948bda22602f (diff)
Merge "[WIP] WorkflowAction refactoring"
Diffstat (limited to 'bpmn')
-rw-r--r--bpmn/MSOCommonBPMN/src/main/java/org/onap/so/bpmn/servicedecomposition/entities/BuildingBlockBase.java89
-rw-r--r--bpmn/MSOCommonBPMN/src/main/java/org/onap/so/bpmn/servicedecomposition/entities/ExecuteBuildingBlock.java97
-rw-r--r--bpmn/MSOCommonBPMN/src/test/java/org/onap/so/bpmn/servicedecomposition/tasks/BBInputSetupPopulateMethodsTest.java9
-rw-r--r--bpmn/MSOCommonBPMN/src/test/java/org/onap/so/bpmn/servicedecomposition/tasks/BBInputSetupTest.java54
-rw-r--r--bpmn/MSOCommonBPMN/src/test/java/org/onap/so/bpmn/servicedecomposition/tasks/ExecuteBuildingBlockRainyDayTest.java3
-rw-r--r--bpmn/so-bpmn-tasks/src/main/java/org/onap/so/bpmn/infrastructure/activity/ExecuteActivity.java14
-rw-r--r--bpmn/so-bpmn-tasks/src/main/java/org/onap/so/bpmn/infrastructure/workflow/tasks/ConfigBuildingBlocksDataObject.java106
-rw-r--r--bpmn/so-bpmn-tasks/src/main/java/org/onap/so/bpmn/infrastructure/workflow/tasks/WorkflowAction.java88
-rw-r--r--bpmn/so-bpmn-tasks/src/main/java/org/onap/so/bpmn/infrastructure/workflow/tasks/WorkflowActionBBTasks.java15
-rw-r--r--bpmn/so-bpmn-tasks/src/test/java/org/onap/so/bpmn/infrastructure/workflow/tasks/WorkflowActionBBFailureTest.java3
-rw-r--r--bpmn/so-bpmn-tasks/src/test/java/org/onap/so/bpmn/infrastructure/workflow/tasks/WorkflowActionBBTasksTest.java131
-rw-r--r--bpmn/so-bpmn-tasks/src/test/java/org/onap/so/bpmn/infrastructure/workflow/tasks/WorkflowActionBBTasksUpdateReqDbTest.java6
-rw-r--r--bpmn/so-bpmn-tasks/src/test/java/org/onap/so/bpmn/infrastructure/workflow/tasks/WorkflowActionTest.java53
-rw-r--r--bpmn/so-bpmn-tasks/src/test/java/org/onap/so/bpmn/infrastructure/workflow/tasks/listeners/MultiStageSkipListenerTest.java6
14 files changed, 365 insertions, 309 deletions
diff --git a/bpmn/MSOCommonBPMN/src/main/java/org/onap/so/bpmn/servicedecomposition/entities/BuildingBlockBase.java b/bpmn/MSOCommonBPMN/src/main/java/org/onap/so/bpmn/servicedecomposition/entities/BuildingBlockBase.java
new file mode 100644
index 0000000000..9e320700bd
--- /dev/null
+++ b/bpmn/MSOCommonBPMN/src/main/java/org/onap/so/bpmn/servicedecomposition/entities/BuildingBlockBase.java
@@ -0,0 +1,89 @@
+package org.onap.so.bpmn.servicedecomposition.entities;
+
+import org.onap.so.serviceinstancebeans.RequestDetails;
+
+public class BuildingBlockBase {
+
+ private Boolean aLaCarte;
+ private String apiVersion;
+ private Boolean isResume;
+ private String resourceId;
+ private String requestId;
+ private String requestAction;
+ private RequestDetails requestDetails;
+ private WorkflowResourceIds workflowResourceIds;
+ private String vnfType;
+
+ public void setaLaCarte(Boolean aLaCarte) {
+ this.aLaCarte = aLaCarte;
+ }
+
+ public void setApiVersion(String apiVersion) {
+ this.apiVersion = apiVersion;
+ }
+
+ public void setResume(Boolean resume) {
+ isResume = resume;
+ }
+
+ public void setResourceId(String resourceId) {
+ this.resourceId = resourceId;
+ }
+
+ public void setRequestId(String requestId) {
+ this.requestId = requestId;
+ }
+
+ public void setRequestAction(String requestAction) {
+ this.requestAction = requestAction;
+ }
+
+ public void setRequestDetails(RequestDetails requestDetails) {
+ this.requestDetails = requestDetails;
+ }
+
+ public void setWorkflowResourceIds(WorkflowResourceIds workflowResourceIds) {
+ this.workflowResourceIds = workflowResourceIds;
+ }
+
+ public void setVnfType(String vnfType) {
+ this.vnfType = vnfType;
+ }
+
+ public Boolean isResume() {
+ return isResume;
+ }
+
+ public String getRequestId() {
+ return requestId;
+ }
+
+ public String getApiVersion() {
+ return apiVersion;
+ }
+
+ public String getResourceId() {
+ return resourceId;
+ }
+
+ public String getRequestAction() {
+ return requestAction;
+ }
+
+ public Boolean isaLaCarte() {
+ return aLaCarte;
+ }
+
+ public String getVnfType() {
+ return vnfType;
+ }
+
+ public WorkflowResourceIds getWorkflowResourceIds() {
+ return workflowResourceIds;
+ }
+
+ public RequestDetails getRequestDetails() {
+ return requestDetails;
+ }
+
+}
diff --git a/bpmn/MSOCommonBPMN/src/main/java/org/onap/so/bpmn/servicedecomposition/entities/ExecuteBuildingBlock.java b/bpmn/MSOCommonBPMN/src/main/java/org/onap/so/bpmn/servicedecomposition/entities/ExecuteBuildingBlock.java
index abd301fa4d..9274e0659e 100644
--- a/bpmn/MSOCommonBPMN/src/main/java/org/onap/so/bpmn/servicedecomposition/entities/ExecuteBuildingBlock.java
+++ b/bpmn/MSOCommonBPMN/src/main/java/org/onap/so/bpmn/servicedecomposition/entities/ExecuteBuildingBlock.java
@@ -21,119 +21,36 @@
package org.onap.so.bpmn.servicedecomposition.entities;
import java.io.Serializable;
-import org.onap.so.serviceinstancebeans.RequestDetails;
-public class ExecuteBuildingBlock implements Serializable {
+public class ExecuteBuildingBlock extends BuildingBlockBase implements Serializable {
- private static final long serialVersionUID = 2L;
private BuildingBlock buildingBlock;
- private String requestId;
- private String apiVersion;
- private String resourceId;
- private String requestAction;
- private String vnfType;
- private Boolean aLaCarte;
- private Boolean homing = false;
- private WorkflowResourceIds workflowResourceIds;
- private RequestDetails requestDetails;
private ConfigurationResourceKeys configurationResourceKeys;
+ private Boolean homing = false;
+ private static final long serialVersionUID = 3L;
public BuildingBlock getBuildingBlock() {
return buildingBlock;
}
- public ExecuteBuildingBlock setBuildingBlock(BuildingBlock buildingBlock) {
+ public void setBuildingBlock(BuildingBlock buildingBlock) {
this.buildingBlock = buildingBlock;
- return this;
- }
-
- public String getRequestId() {
- return requestId;
- }
-
- public ExecuteBuildingBlock setRequestId(String requestId) {
- this.requestId = requestId;
- return this;
- }
-
- public String getApiVersion() {
- return apiVersion;
- }
-
- public ExecuteBuildingBlock setApiVersion(String apiVersion) {
- this.apiVersion = apiVersion;
- return this;
- }
-
- public String getResourceId() {
- return resourceId;
- }
-
- public ExecuteBuildingBlock setResourceId(String resourceId) {
- this.resourceId = resourceId;
- return this;
- }
-
- public String getRequestAction() {
- return requestAction;
- }
-
- public ExecuteBuildingBlock setRequestAction(String requestAction) {
- this.requestAction = requestAction;
- return this;
- }
-
- public Boolean isaLaCarte() {
- return aLaCarte;
- }
-
- public ExecuteBuildingBlock setaLaCarte(Boolean aLaCarte) {
- this.aLaCarte = aLaCarte;
- return this;
- }
-
- public String getVnfType() {
- return vnfType;
- }
-
- public ExecuteBuildingBlock setVnfType(String vnfType) {
- this.vnfType = vnfType;
- return this;
}
public Boolean isHoming() {
return homing;
}
- public ExecuteBuildingBlock setHoming(Boolean homing) {
+ public void setHoming(Boolean homing) {
this.homing = homing;
- return this;
- }
-
- public WorkflowResourceIds getWorkflowResourceIds() {
- return workflowResourceIds;
- }
-
- public ExecuteBuildingBlock setWorkflowResourceIds(WorkflowResourceIds workflowResourceIds) {
- this.workflowResourceIds = workflowResourceIds;
- return this;
- }
-
- public RequestDetails getRequestDetails() {
- return requestDetails;
- }
-
- public ExecuteBuildingBlock setRequestDetails(RequestDetails requestDetails) {
- this.requestDetails = requestDetails;
- return this;
}
public ConfigurationResourceKeys getConfigurationResourceKeys() {
return configurationResourceKeys;
}
- public ExecuteBuildingBlock setConfigurationResourceKeys(ConfigurationResourceKeys configurationResourceKeys) {
+ public void setConfigurationResourceKeys(ConfigurationResourceKeys configurationResourceKeys) {
this.configurationResourceKeys = configurationResourceKeys;
- return this;
}
+
}
diff --git a/bpmn/MSOCommonBPMN/src/test/java/org/onap/so/bpmn/servicedecomposition/tasks/BBInputSetupPopulateMethodsTest.java b/bpmn/MSOCommonBPMN/src/test/java/org/onap/so/bpmn/servicedecomposition/tasks/BBInputSetupPopulateMethodsTest.java
index d7cfaf94f7..a74d78e04b 100644
--- a/bpmn/MSOCommonBPMN/src/test/java/org/onap/so/bpmn/servicedecomposition/tasks/BBInputSetupPopulateMethodsTest.java
+++ b/bpmn/MSOCommonBPMN/src/test/java/org/onap/so/bpmn/servicedecomposition/tasks/BBInputSetupPopulateMethodsTest.java
@@ -115,7 +115,8 @@ public class BBInputSetupPopulateMethodsTest {
.readValue(new File(RESOURCE_PATH + "RequestDetailsInput_serviceMacro.json"), RequestDetails.class);
ExecuteBuildingBlock executeBB = mapper.readValue(new File(RESOURCE_PATH + "ExecuteBuildingBlockSimple.json"),
ExecuteBuildingBlock.class);
- executeBB.setConfigurationResourceKeys(configResourceKeys).setRequestDetails(requestDetails);
+ executeBB.setConfigurationResourceKeys(configResourceKeys);
+ executeBB.setRequestDetails(requestDetails);
BuildingBlock buildingBlock = executeBB.getBuildingBlock();
buildingBlock.setBpmnFlowName(AssignFlows.NETWORK_MACRO.toString())
.setKey("ab153b6e-c364-44c0-bef6-1f2982117f04");
@@ -181,7 +182,8 @@ public class BBInputSetupPopulateMethodsTest {
ConfigurationResourceKeys configResourceKeys = prepareConfigurationResourceKeys();
ExecuteBuildingBlock executeBB = mapper.readValue(new File(RESOURCE_PATH + "ExecuteBuildingBlockSimple.json"),
ExecuteBuildingBlock.class);
- executeBB.setConfigurationResourceKeys(configResourceKeys).setRequestDetails(requestDetails);
+ executeBB.setConfigurationResourceKeys(configResourceKeys);
+ executeBB.setRequestDetails(requestDetails);
BuildingBlock buildingBlock = executeBB.getBuildingBlock();
buildingBlock.setBpmnFlowName(AssignFlows.VF_MODULE.toString()).setKey("a25e8e8c-58b8-4eec-810c-97dcc1f5cb7f");
@@ -243,7 +245,8 @@ public class BBInputSetupPopulateMethodsTest {
ConfigurationResourceKeys configResourceKeys = prepareConfigurationResourceKeys();
ExecuteBuildingBlock executeBB = mapper.readValue(new File(RESOURCE_PATH + "ExecuteBuildingBlockSimple.json"),
ExecuteBuildingBlock.class);
- executeBB.setConfigurationResourceKeys(configResourceKeys).setRequestDetails(requestDetails);
+ executeBB.setConfigurationResourceKeys(configResourceKeys);
+ executeBB.setRequestDetails(requestDetails);
BuildingBlock buildingBlock = executeBB.getBuildingBlock();
buildingBlock.setBpmnFlowName("AssignFabricConfigurationBB").setKey("72d9d1cd-f46d-447a-abdb-451d6fb05fa9");
diff --git a/bpmn/MSOCommonBPMN/src/test/java/org/onap/so/bpmn/servicedecomposition/tasks/BBInputSetupTest.java b/bpmn/MSOCommonBPMN/src/test/java/org/onap/so/bpmn/servicedecomposition/tasks/BBInputSetupTest.java
index 458919c48e..ffdc275dee 100644
--- a/bpmn/MSOCommonBPMN/src/test/java/org/onap/so/bpmn/servicedecomposition/tasks/BBInputSetupTest.java
+++ b/bpmn/MSOCommonBPMN/src/test/java/org/onap/so/bpmn/servicedecomposition/tasks/BBInputSetupTest.java
@@ -308,8 +308,9 @@ public class BBInputSetupTest {
@Test
public void testGetExecuteBBFromExecution() throws IOException {
BuildingBlock bb = new BuildingBlock().setBpmnFlowName("AssignServiceInstanceBB");
- ExecuteBuildingBlock expected =
- new ExecuteBuildingBlock().setBuildingBlock(bb).setRequestId("00032ab7-3fb3-42e5-965d-8ea592502017");
+ ExecuteBuildingBlock expected = new ExecuteBuildingBlock();
+ expected.setBuildingBlock(bb);
+ expected.setRequestId("00032ab7-3fb3-42e5-965d-8ea592502017");
DelegateExecution execution = Mockito.mock(DelegateExecution.class);
doReturn(expected).when(execution).getVariable(any(String.class));
ExecuteBuildingBlock actual = SPY_bbInputSetup.getExecuteBBFromExecution(execution);
@@ -321,7 +322,8 @@ public class BBInputSetupTest {
GeneralBuildingBlock expected = mapper.readValue(new File(RESOURCE_PATH + "GeneralBuildingBlockExpected.json"),
GeneralBuildingBlock.class);
- ExecuteBuildingBlock executeBB = new ExecuteBuildingBlock().setRequestId("requestId");
+ ExecuteBuildingBlock executeBB = new ExecuteBuildingBlock();
+ executeBB.setRequestId("requestId");
RequestDetails requestDetails = new RequestDetails();
ModelInfo modelInfo = new ModelInfo();
modelInfo.setModelType(ModelType.service);
@@ -349,7 +351,8 @@ public class BBInputSetupTest {
GeneralBuildingBlock expected = mapper
.readValue(new File(RESOURCE_PATH + "GeneralBuildingBlockCMExpected.json"), GeneralBuildingBlock.class);
- ExecuteBuildingBlock executeBB = new ExecuteBuildingBlock().setRequestId("requestId");
+ ExecuteBuildingBlock executeBB = new ExecuteBuildingBlock();
+ executeBB.setRequestId("requestId");
RequestDetails requestDetails = new RequestDetails();
requestDetails.setModelInfo(null);
RequestParameters requestParams = new RequestParameters();
@@ -1003,7 +1006,9 @@ public class BBInputSetupTest {
Map<ResourceKey, String> lookupKeyMap = new HashMap<>();
BuildingBlock buildingBlock = new BuildingBlock().setBpmnFlowName(AssignFlows.SERVICE_INSTANCE.toString());
- ExecuteBuildingBlock executeBB = new ExecuteBuildingBlock().setaLaCarte(true).setBuildingBlock(buildingBlock);
+ ExecuteBuildingBlock executeBB = new ExecuteBuildingBlock();
+ executeBB.setaLaCarte(true);
+ executeBB.setBuildingBlock(buildingBlock);
RequestDetails requestDetails = new RequestDetails();
RequestInfo reqInfo = new RequestInfo();
reqInfo.setInstanceName("serviceInstanceName");
@@ -2050,7 +2055,8 @@ public class BBInputSetupTest {
Map<ResourceKey, String> lookupKeyMap = prepareLookupKeyMap();
ConfigurationResourceKeys configResourceKeys = prepareConfigurationResourceKeys();
- executeBB.setConfigurationResourceKeys(configResourceKeys).setRequestDetails(requestDetails);
+ executeBB.setConfigurationResourceKeys(configResourceKeys);
+ executeBB.setRequestDetails(requestDetails);
BuildingBlock buildingBlock = executeBB.getBuildingBlock();
buildingBlock.setBpmnFlowName("AssignVrfConfigurationBB");
buildingBlock.setKey("72d9d1cd-f46d-447a-abdb-451d6fb05fa9");
@@ -2230,7 +2236,8 @@ public class BBInputSetupTest {
.readValue(new File(RESOURCE_PATH + "RequestDetailsInput_serviceMacro.json"), RequestDetails.class);
ExecuteBuildingBlock executeBB = mapper.readValue(new File(RESOURCE_PATH + "ExecuteBuildingBlockSimple.json"),
ExecuteBuildingBlock.class);
- executeBB.setConfigurationResourceKeys(configResourceKeys).setRequestDetails(requestDetails);
+ executeBB.setConfigurationResourceKeys(configResourceKeys);
+ executeBB.setRequestDetails(requestDetails);
BuildingBlock buildingBlock = executeBB.getBuildingBlock();
buildingBlock.setBpmnFlowName(AssignFlows.NETWORK_MACRO.toString())
.setKey("ab153b6e-c364-44c0-bef6-1f2982117f04");
@@ -2299,7 +2306,8 @@ public class BBInputSetupTest {
requestDetails.getRequestParameters().setUserParams(null);
ExecuteBuildingBlock executeBB = mapper.readValue(new File(RESOURCE_PATH + "ExecuteBuildingBlockSimple.json"),
ExecuteBuildingBlock.class);
- executeBB.setConfigurationResourceKeys(configResourceKeys).setRequestDetails(requestDetails);
+ executeBB.setConfigurationResourceKeys(configResourceKeys);
+ executeBB.setRequestDetails(requestDetails);
BuildingBlock buildingBlock = executeBB.getBuildingBlock();
buildingBlock.setBpmnFlowName(AssignFlows.NETWORK_MACRO.toString())
.setKey("ab153b6e-c364-44c0-bef6-1f2982117f04").setIsVirtualLink(false);
@@ -2344,7 +2352,8 @@ public class BBInputSetupTest {
requestDetails.getRequestParameters().setUserParams(null);
ExecuteBuildingBlock executeBB = mapper.readValue(new File(RESOURCE_PATH + "ExecuteBuildingBlockSimple.json"),
ExecuteBuildingBlock.class);
- executeBB.setConfigurationResourceKeys(configResourceKeys).setRequestDetails(requestDetails);
+ executeBB.setConfigurationResourceKeys(configResourceKeys);
+ executeBB.setRequestDetails(requestDetails);
BuildingBlock buildingBlock = executeBB.getBuildingBlock();
buildingBlock.setBpmnFlowName(AssignFlows.NETWORK_MACRO.toString())
.setKey("ab153b6e-c364-44c0-bef6-1f2982117f04").setIsVirtualLink(true);
@@ -2390,7 +2399,8 @@ public class BBInputSetupTest {
requestDetails.getRequestParameters().setUserParams(null);
ExecuteBuildingBlock executeBB = mapper.readValue(new File(RESOURCE_PATH + "ExecuteBuildingBlockSimple.json"),
ExecuteBuildingBlock.class);
- executeBB.setConfigurationResourceKeys(configResourceKeys).setRequestDetails(requestDetails);
+ executeBB.setConfigurationResourceKeys(configResourceKeys);
+ executeBB.setRequestDetails(requestDetails);
BuildingBlock buildingBlock = executeBB.getBuildingBlock();
buildingBlock.setBpmnFlowName(otherFlowName).setKey("ab153b6e-c364-44c0-bef6-1f2982117f04")
.setIsVirtualLink(true);
@@ -2462,7 +2472,8 @@ public class BBInputSetupTest {
aaiNetwork.setModelCustomizationId("modelCustId");
ConfigurationResourceKeys configResourceKeys = prepareConfigurationResourceKeys();
- executeBB.setConfigurationResourceKeys(configResourceKeys).setRequestDetails(requestDetails);
+ executeBB.setConfigurationResourceKeys(configResourceKeys);
+ executeBB.setRequestDetails(requestDetails);
BuildingBlock buildingBlock = executeBB.getBuildingBlock();
buildingBlock.setBpmnFlowName("DeleteNetworkBB").setKey("ab153b6e-c364-44c0-bef6-1f2982117f04");
@@ -2513,7 +2524,8 @@ public class BBInputSetupTest {
aaiVnf.setModelCustomizationId("modelCustId");
ConfigurationResourceKeys configResourceKeys = prepareConfigurationResourceKeys();
- executeBB.setConfigurationResourceKeys(configResourceKeys).setRequestDetails(requestDetails);
+ executeBB.setConfigurationResourceKeys(configResourceKeys);
+ executeBB.setRequestDetails(requestDetails);
BuildingBlock buildingBlock = executeBB.getBuildingBlock();
buildingBlock.setBpmnFlowName("ControllerExecutionBB").setKey("ab153b6e-c364-44c0-bef6-1f2982117f04");
buildingBlock.setBpmnScope("VNF");
@@ -2565,7 +2577,8 @@ public class BBInputSetupTest {
aaiVnf.setModelCustomizationId("modelCustId");
ConfigurationResourceKeys configResourceKeys = prepareConfigurationResourceKeys();
- executeBB.setConfigurationResourceKeys(configResourceKeys).setRequestDetails(requestDetails);
+ executeBB.setConfigurationResourceKeys(configResourceKeys);
+ executeBB.setRequestDetails(requestDetails);
BuildingBlock buildingBlock = executeBB.getBuildingBlock();
buildingBlock.setBpmnFlowName("ActivateVnfBB").setKey("ab153b6e-c364-44c0-bef6-1f2982117f04");
@@ -2621,7 +2634,8 @@ public class BBInputSetupTest {
aaiVfModule.setModelCustomizationId("modelCustId");
ConfigurationResourceKeys configResourceKeys = prepareConfigurationResourceKeys();
- executeBB.setConfigurationResourceKeys(configResourceKeys).setRequestDetails(requestDetails);
+ executeBB.setConfigurationResourceKeys(configResourceKeys);
+ executeBB.setRequestDetails(requestDetails);
BuildingBlock buildingBlock = executeBB.getBuildingBlock();
buildingBlock.setBpmnFlowName("ControllerExecutionBB").setKey("a25e8e8c-58b8-4eec-810c-97dcc1f5cb7f");
buildingBlock.setBpmnScope("VfModule");
@@ -2681,7 +2695,8 @@ public class BBInputSetupTest {
aaiVfModule.setModelCustomizationId("modelCustId");
ConfigurationResourceKeys configResourceKeys = prepareConfigurationResourceKeys();
- executeBB.setConfigurationResourceKeys(configResourceKeys).setRequestDetails(requestDetails);
+ executeBB.setConfigurationResourceKeys(configResourceKeys);
+ executeBB.setRequestDetails(requestDetails);
BuildingBlock buildingBlock = executeBB.getBuildingBlock();
buildingBlock.setBpmnFlowName("UnassignVfModuleBB").setKey("a25e8e8c-58b8-4eec-810c-97dcc1f5cb7f");
@@ -2742,7 +2757,8 @@ public class BBInputSetupTest {
aaiVolumeGroup.setModelCustomizationId("modelCustId");
ConfigurationResourceKeys configResourceKeys = prepareConfigurationResourceKeys();
- executeBB.setConfigurationResourceKeys(configResourceKeys).setRequestDetails(requestDetails);
+ executeBB.setConfigurationResourceKeys(configResourceKeys);
+ executeBB.setRequestDetails(requestDetails);
BuildingBlock buildingBlock = executeBB.getBuildingBlock();
buildingBlock.setBpmnFlowName("UnassignVolumeGroupBB").setKey("72d9d1cd-f46d-447a-abdb-451d6fb05fa8");
@@ -2808,7 +2824,8 @@ public class BBInputSetupTest {
aaiConfiguration.setModelCustomizationId("modelCustId");
ConfigurationResourceKeys configResourceKeys = prepareConfigurationResourceKeys();
- executeBB.setConfigurationResourceKeys(configResourceKeys).setRequestDetails(requestDetails);
+ executeBB.setConfigurationResourceKeys(configResourceKeys);
+ executeBB.setRequestDetails(requestDetails);
BuildingBlock buildingBlock = executeBB.getBuildingBlock();
buildingBlock.setBpmnFlowName("ActivateFabricConfigurationBB").setKey("72d9d1cd-f46d-447a-abdb-451d6fb05fa9");
@@ -2876,7 +2893,8 @@ public class BBInputSetupTest {
@Test
public void testGetVnfId() {
String expected = "vnfId";
- ExecuteBuildingBlock executeBB = new ExecuteBuildingBlock().setRequestId("requestId");
+ ExecuteBuildingBlock executeBB = new ExecuteBuildingBlock();
+ executeBB.setRequestId("requestId");
Map<ResourceKey, String> lookupKeyMap = new HashMap<>();
InfraActiveRequests request = new InfraActiveRequests();
request.setVnfId(expected);
diff --git a/bpmn/MSOCommonBPMN/src/test/java/org/onap/so/bpmn/servicedecomposition/tasks/ExecuteBuildingBlockRainyDayTest.java b/bpmn/MSOCommonBPMN/src/test/java/org/onap/so/bpmn/servicedecomposition/tasks/ExecuteBuildingBlockRainyDayTest.java
index ee47b514d1..bac29150c1 100644
--- a/bpmn/MSOCommonBPMN/src/test/java/org/onap/so/bpmn/servicedecomposition/tasks/ExecuteBuildingBlockRainyDayTest.java
+++ b/bpmn/MSOCommonBPMN/src/test/java/org/onap/so/bpmn/servicedecomposition/tasks/ExecuteBuildingBlockRainyDayTest.java
@@ -58,7 +58,8 @@ public class ExecuteBuildingBlockRainyDayTest extends BaseTest {
vnf = setGenericVnf();
BuildingBlock buildingBlock = new BuildingBlock().setBpmnFlowName("AssignServiceInstanceBB");
- ExecuteBuildingBlock executeBuildingBlock = new ExecuteBuildingBlock().setBuildingBlock(buildingBlock);
+ ExecuteBuildingBlock executeBuildingBlock = new ExecuteBuildingBlock();
+ executeBuildingBlock.setBuildingBlock(buildingBlock);
delegateExecution.setVariable("gBBInput", gBBInput);
delegateExecution.setVariable("WorkflowException", new WorkflowException("", 7000, ""));
diff --git a/bpmn/so-bpmn-tasks/src/main/java/org/onap/so/bpmn/infrastructure/activity/ExecuteActivity.java b/bpmn/so-bpmn-tasks/src/main/java/org/onap/so/bpmn/infrastructure/activity/ExecuteActivity.java
index 415d4614da..a4ffb45370 100644
--- a/bpmn/so-bpmn-tasks/src/main/java/org/onap/so/bpmn/infrastructure/activity/ExecuteActivity.java
+++ b/bpmn/so-bpmn-tasks/src/main/java/org/onap/so/bpmn/infrastructure/activity/ExecuteActivity.java
@@ -166,10 +166,16 @@ public class ExecuteActivity implements JavaDelegate {
String bpmnRequest = (String) execution.getVariable(G_BPMN_REQUEST);
ServiceInstancesRequest sIRequest = mapper.readValue(bpmnRequest, ServiceInstancesRequest.class);
RequestDetails requestDetails = sIRequest.getRequestDetails();
- return new ExecuteBuildingBlock().setaLaCarte(true).setRequestAction((String) execution.getVariable(G_ACTION))
- .setResourceId((String) execution.getVariable(VNF_ID))
- .setVnfType((String) execution.getVariable(VNF_TYPE)).setWorkflowResourceIds(workflowResourceIds)
- .setRequestId(requestId).setBuildingBlock(buildingBlock).setRequestDetails(requestDetails);
+ ExecuteBuildingBlock executeBuildingBlock = new ExecuteBuildingBlock();
+ executeBuildingBlock.setaLaCarte(true);
+ executeBuildingBlock.setRequestAction((String) execution.getVariable(G_ACTION));
+ executeBuildingBlock.setResourceId((String) execution.getVariable(VNF_ID));
+ executeBuildingBlock.setVnfType((String) execution.getVariable(VNF_TYPE));
+ executeBuildingBlock.setWorkflowResourceIds(workflowResourceIds);
+ executeBuildingBlock.setRequestId(requestId);
+ executeBuildingBlock.setBuildingBlock(buildingBlock);
+ executeBuildingBlock.setRequestDetails(requestDetails);
+ return executeBuildingBlock;
}
protected void buildAndThrowException(DelegateExecution execution, String msg, Exception ex) {
diff --git a/bpmn/so-bpmn-tasks/src/main/java/org/onap/so/bpmn/infrastructure/workflow/tasks/ConfigBuildingBlocksDataObject.java b/bpmn/so-bpmn-tasks/src/main/java/org/onap/so/bpmn/infrastructure/workflow/tasks/ConfigBuildingBlocksDataObject.java
index 1852485083..d22435c495 100644
--- a/bpmn/so-bpmn-tasks/src/main/java/org/onap/so/bpmn/infrastructure/workflow/tasks/ConfigBuildingBlocksDataObject.java
+++ b/bpmn/so-bpmn-tasks/src/main/java/org/onap/so/bpmn/infrastructure/workflow/tasks/ConfigBuildingBlocksDataObject.java
@@ -20,136 +20,48 @@
package org.onap.so.bpmn.infrastructure.workflow.tasks;
-import java.util.List;
import org.camunda.bpm.engine.delegate.DelegateExecution;
-import org.onap.so.bpmn.servicedecomposition.entities.WorkflowResourceIds;
+import org.onap.so.bpmn.servicedecomposition.entities.BuildingBlockBase;
import org.onap.so.db.catalog.beans.macro.OrchestrationFlow;
-import org.onap.so.serviceinstancebeans.RequestDetails;
import org.onap.so.serviceinstancebeans.ServiceInstancesRequest;
+import java.util.List;
-public class ConfigBuildingBlocksDataObject {
+public class ConfigBuildingBlocksDataObject extends BuildingBlockBase {
- private ServiceInstancesRequest sIRequest;
+ private DelegateExecution execution;
private List<OrchestrationFlow> orchFlows;
- private String requestId;
private Resource resourceKey;
- private String apiVersion;
- private String resourceId;
- private String requestAction;
- private boolean aLaCarte;
- private String vnfType;
- private WorkflowResourceIds workflowResourceIds;
- private RequestDetails requestDetails;
- private DelegateExecution execution;
+ private ServiceInstancesRequest sIRequest;
public ServiceInstancesRequest getsIRequest() {
return sIRequest;
}
- public ConfigBuildingBlocksDataObject setsIRequest(ServiceInstancesRequest sIRequest) {
+ public void setsIRequest(ServiceInstancesRequest sIRequest) {
this.sIRequest = sIRequest;
- return this;
}
public List<OrchestrationFlow> getOrchFlows() {
return orchFlows;
}
- public ConfigBuildingBlocksDataObject setOrchFlows(List<OrchestrationFlow> orchFlows) {
+ public void setOrchFlows(List<OrchestrationFlow> orchFlows) {
this.orchFlows = orchFlows;
- return this;
- }
-
- public String getRequestId() {
- return requestId;
- }
-
- public ConfigBuildingBlocksDataObject setRequestId(String requestId) {
- this.requestId = requestId;
- return this;
}
public Resource getResourceKey() {
return resourceKey;
}
- public ConfigBuildingBlocksDataObject setResourceKey(Resource resourceKey) {
+ public void setResourceKey(Resource resourceKey) {
this.resourceKey = resourceKey;
- return this;
- }
-
- public String getApiVersion() {
- return apiVersion;
- }
-
- public ConfigBuildingBlocksDataObject setApiVersion(String apiVersion) {
- this.apiVersion = apiVersion;
- return this;
- }
-
- public String getResourceId() {
- return resourceId;
- }
-
- public ConfigBuildingBlocksDataObject setResourceId(String resourceId) {
- this.resourceId = resourceId;
- return this;
- }
-
- public String getRequestAction() {
- return requestAction;
- }
-
- public ConfigBuildingBlocksDataObject setRequestAction(String requestAction) {
- this.requestAction = requestAction;
- return this;
- }
-
- public boolean isaLaCarte() {
- return aLaCarte;
- }
-
- public ConfigBuildingBlocksDataObject setaLaCarte(boolean aLaCarte) {
- this.aLaCarte = aLaCarte;
- return this;
- }
-
- public String getVnfType() {
- return vnfType;
- }
-
- public ConfigBuildingBlocksDataObject setVnfType(String vnfType) {
- this.vnfType = vnfType;
- return this;
- }
-
- public WorkflowResourceIds getWorkflowResourceIds() {
- return workflowResourceIds;
- }
-
- public ConfigBuildingBlocksDataObject setWorkflowResourceIds(WorkflowResourceIds workflowResourceIds) {
- this.workflowResourceIds = workflowResourceIds;
- return this;
- }
-
- public RequestDetails getRequestDetails() {
- return requestDetails;
- }
-
- public ConfigBuildingBlocksDataObject setRequestDetails(RequestDetails requestDetails) {
- this.requestDetails = requestDetails;
- return this;
}
public DelegateExecution getExecution() {
return execution;
}
- public ConfigBuildingBlocksDataObject setExecution(DelegateExecution execution) {
+ public void setExecution(DelegateExecution execution) {
this.execution = execution;
- return this;
}
-
-
-
}
diff --git a/bpmn/so-bpmn-tasks/src/main/java/org/onap/so/bpmn/infrastructure/workflow/tasks/WorkflowAction.java b/bpmn/so-bpmn-tasks/src/main/java/org/onap/so/bpmn/infrastructure/workflow/tasks/WorkflowAction.java
index 95f10c35b2..71e1abd564 100644
--- a/bpmn/so-bpmn-tasks/src/main/java/org/onap/so/bpmn/infrastructure/workflow/tasks/WorkflowAction.java
+++ b/bpmn/so-bpmn-tasks/src/main/java/org/onap/so/bpmn/infrastructure/workflow/tasks/WorkflowAction.java
@@ -176,25 +176,32 @@ public class WorkflowAction {
final String bpmnRequest = (String) execution.getVariable(BBConstants.G_BPMN_REQUEST);
ServiceInstancesRequest sIRequest =
new ObjectMapper().readValue(bpmnRequest, ServiceInstancesRequest.class);
- RequestDetails requestDetails = sIRequest.getRequestDetails();
- String uri = (String) execution.getVariable(BBConstants.G_URI);
+
final String requestId = (String) execution.getVariable(BBConstants.G_REQUEST_ID);
- final boolean aLaCarte = (boolean) execution.getVariable(BBConstants.G_ALACARTE);
+
+ String uri = (String) execution.getVariable(BBConstants.G_URI);
boolean isResume = isUriResume(uri);
- String requestAction = (String) execution.getVariable(BBConstants.G_ACTION);
+
+ final boolean isALaCarte = (boolean) execution.getVariable(BBConstants.G_ALACARTE);
+ Resource resource = getResource(bbInputSetupUtils, isResume, isALaCarte, uri, requestId);
+
WorkflowResourceIds workflowResourceIds = populateResourceIdsFromApiHandler(execution);
- Resource resource = getResource(bbInputSetupUtils, isResume, aLaCarte, uri, requestId);
+ RequestDetails requestDetails = sIRequest.getRequestDetails();
+ String requestAction = (String) execution.getVariable(BBConstants.G_ACTION);
String resourceId = getResourceId(resource, requestAction, requestDetails, workflowResourceIds);
WorkflowType resourceType = resource.getResourceType();
+
String serviceInstanceId = getServiceInstanceId(execution, resourceId, resourceType);
+
fillExecution(execution, requestDetails.getRequestInfo().getSuppressRollback(), resourceId, resourceType);
List<ExecuteBuildingBlock> flowsToExecute = new ArrayList<>();
- if (isRequestMacroServiceResume(aLaCarte, resourceType, requestAction, serviceInstanceId)) {
+
+ if (isRequestMacroServiceResume(isALaCarte, resourceType, requestAction, serviceInstanceId)) {
flowsToExecute = bbInputSetupUtils.loadOriginalFlowExecutionPath(requestId);
if (flowsToExecute == null) {
buildAndThrowException(execution, "Could not resume Macro flow. Error loading execution path.");
}
- } else if (aLaCarte && isResume) {
+ } else if (isALaCarte && isResume) {
flowsToExecute = bbInputSetupUtils.loadOriginalFlowExecutionPath(requestId);
if (flowsToExecute == null) {
buildAndThrowException(execution,
@@ -208,20 +215,30 @@ public class WorkflowAction {
final String apiVersion = (String) execution.getVariable(BBConstants.G_APIVERSION);
final String serviceType =
Optional.ofNullable((String) execution.getVariable(BBConstants.G_SERVICE_TYPE)).orElse("");
- if (aLaCarte) {
+ if (isALaCarte) {
if (orchFlows == null || orchFlows.isEmpty()) {
orchFlows = queryNorthBoundRequestCatalogDb(execution, requestAction, resourceType, true,
cloudOwner, serviceType);
}
Resource resourceKey = getResourceKey(sIRequest, resourceType);
- boolean isConfiguration = isConfiguration(orchFlows);
- if (isConfiguration && !requestAction.equalsIgnoreCase(CREATEINSTANCE)) {
- List<ExecuteBuildingBlock> configBuildingBlocks = getConfigBuildingBlocks(
- new ConfigBuildingBlocksDataObject().setsIRequest(sIRequest).setOrchFlows(orchFlows)
- .setRequestId(requestId).setResourceKey(resourceKey).setApiVersion(apiVersion)
- .setResourceId(resourceId).setRequestAction(requestAction).setaLaCarte(true)
- .setVnfType(vnfType).setWorkflowResourceIds(workflowResourceIds)
- .setRequestDetails(requestDetails).setExecution(execution));
+ if (isConfiguration(orchFlows) && !requestAction.equalsIgnoreCase(CREATEINSTANCE)) {
+ ConfigBuildingBlocksDataObject configBuildingBlocksDataObject =
+ new ConfigBuildingBlocksDataObject();
+ configBuildingBlocksDataObject.setsIRequest(sIRequest);
+ configBuildingBlocksDataObject.setOrchFlows(orchFlows);
+ configBuildingBlocksDataObject.setRequestId(requestId);
+ configBuildingBlocksDataObject.setResourceKey(resourceKey);
+ configBuildingBlocksDataObject.setApiVersion(apiVersion);
+ configBuildingBlocksDataObject.setResourceId(resourceId);
+ configBuildingBlocksDataObject.setRequestAction(requestAction);
+ configBuildingBlocksDataObject.setaLaCarte(true);
+ configBuildingBlocksDataObject.setVnfType(vnfType);
+ configBuildingBlocksDataObject.setWorkflowResourceIds(workflowResourceIds);
+ configBuildingBlocksDataObject.setRequestDetails(requestDetails);
+ configBuildingBlocksDataObject.setExecution(execution);
+
+ List<ExecuteBuildingBlock> configBuildingBlocks =
+ getConfigBuildingBlocks(configBuildingBlocksDataObject);
flowsToExecute.addAll(configBuildingBlocks);
}
@@ -232,12 +249,23 @@ public class WorkflowAction {
|| requestAction.equalsIgnoreCase(REPLACEINSTANCERETAINASSIGNMENTS))
&& resourceType.equals(WorkflowType.VFMODULE)) {
logger.debug("Build a BB list for replacing BB modules");
- orchFlows = getVfModuleReplaceBuildingBlocks(
- new ConfigBuildingBlocksDataObject().setsIRequest(sIRequest).setOrchFlows(orchFlows)
- .setRequestId(requestId).setResourceKey(resourceKey).setApiVersion(apiVersion)
- .setResourceId(resourceId).setRequestAction(requestAction).setaLaCarte(true)
- .setVnfType(vnfType).setWorkflowResourceIds(workflowResourceIds)
- .setRequestDetails(requestDetails).setExecution(execution));
+
+ ConfigBuildingBlocksDataObject configBuildingBlocksDataObject =
+ new ConfigBuildingBlocksDataObject();
+ configBuildingBlocksDataObject.setsIRequest(sIRequest);
+ configBuildingBlocksDataObject.setOrchFlows(orchFlows);
+ configBuildingBlocksDataObject.setRequestId(requestId);
+ configBuildingBlocksDataObject.setResourceKey(resourceKey);
+ configBuildingBlocksDataObject.setApiVersion(apiVersion);
+ configBuildingBlocksDataObject.setResourceId(resourceId);
+ configBuildingBlocksDataObject.setRequestAction(requestAction);
+ configBuildingBlocksDataObject.setaLaCarte(true);
+ configBuildingBlocksDataObject.setVnfType(vnfType);
+ configBuildingBlocksDataObject.setWorkflowResourceIds(workflowResourceIds);
+ configBuildingBlocksDataObject.setRequestDetails(requestDetails);
+ configBuildingBlocksDataObject.setExecution(execution);
+
+ orchFlows = getVfModuleReplaceBuildingBlocks(configBuildingBlocksDataObject);
}
for (OrchestrationFlow orchFlow : orchFlows) {
ExecuteBuildingBlock ebb = buildExecuteBuildingBlock(orchFlow, requestId, resourceKey,
@@ -319,7 +347,7 @@ public class WorkflowAction {
logger.info("Found {}", foundObjects);
if (orchFlows == null || orchFlows.isEmpty()) {
- orchFlows = queryNorthBoundRequestCatalogDb(execution, requestAction, resourceType, aLaCarte,
+ orchFlows = queryNorthBoundRequestCatalogDb(execution, requestAction, resourceType, isALaCarte,
cloudOwner, serviceType);
}
boolean vnfReplace = false;
@@ -1436,10 +1464,16 @@ public class WorkflowAction {
resourceId = workflowResourceIds.getVolumeGroupId();
}
- ExecuteBuildingBlock executeBuildingBlock = new ExecuteBuildingBlock().setApiVersion(apiVersion)
- .setaLaCarte(aLaCarte).setRequestAction(requestAction).setResourceId(resourceId).setVnfType(vnfType)
- .setWorkflowResourceIds(workflowResourceIds).setRequestId(requestId).setBuildingBlock(buildingBlock)
- .setRequestDetails(requestDetails);
+ ExecuteBuildingBlock executeBuildingBlock = new ExecuteBuildingBlock();
+ executeBuildingBlock.setApiVersion(apiVersion);
+ executeBuildingBlock.setaLaCarte(aLaCarte);
+ executeBuildingBlock.setRequestAction(requestAction);
+ executeBuildingBlock.setResourceId(resourceId);
+ executeBuildingBlock.setVnfType(vnfType);
+ executeBuildingBlock.setWorkflowResourceIds(workflowResourceIds);
+ executeBuildingBlock.setRequestId(requestId);
+ executeBuildingBlock.setBuildingBlock(buildingBlock);
+ executeBuildingBlock.setRequestDetails(requestDetails);
if (resource != null && (isConfiguration || resource.getResourceType().equals(WorkflowType.CONFIGURATION))) {
ConfigurationResourceKeys configurationResourceKeys = new ConfigurationResourceKeys();
diff --git a/bpmn/so-bpmn-tasks/src/main/java/org/onap/so/bpmn/infrastructure/workflow/tasks/WorkflowActionBBTasks.java b/bpmn/so-bpmn-tasks/src/main/java/org/onap/so/bpmn/infrastructure/workflow/tasks/WorkflowActionBBTasks.java
index 9d68b5a3f0..31df5bbdc3 100644
--- a/bpmn/so-bpmn-tasks/src/main/java/org/onap/so/bpmn/infrastructure/workflow/tasks/WorkflowActionBBTasks.java
+++ b/bpmn/so-bpmn-tasks/src/main/java/org/onap/so/bpmn/infrastructure/workflow/tasks/WorkflowActionBBTasks.java
@@ -493,11 +493,16 @@ public class WorkflowActionBBTasks {
WorkflowResourceIds workflowResourceIds = ebb.getWorkflowResourceIds();
workflowResourceIds.setConfigurationId(configurationId);
- ExecuteBuildingBlock configBB = new ExecuteBuildingBlock().setaLaCarte(ebb.isaLaCarte())
- .setApiVersion(ebb.getApiVersion()).setRequestAction(ebb.getRequestAction())
- .setVnfType(ebb.getVnfType()).setRequestId(ebb.getRequestId())
- .setRequestDetails(ebb.getRequestDetails()).setBuildingBlock(buildingBlock)
- .setWorkflowResourceIds(workflowResourceIds).setConfigurationResourceKeys(configurationResourceKeys);
+ ExecuteBuildingBlock configBB = new ExecuteBuildingBlock();
+ configBB.setaLaCarte(ebb.isaLaCarte());
+ configBB.setApiVersion(ebb.getApiVersion());
+ configBB.setRequestAction(ebb.getRequestAction());
+ configBB.setVnfType(ebb.getVnfType());
+ configBB.setRequestId(ebb.getRequestId());
+ configBB.setRequestDetails(ebb.getRequestDetails());
+ configBB.setBuildingBlock(buildingBlock);
+ configBB.setWorkflowResourceIds(workflowResourceIds);
+ configBB.setConfigurationResourceKeys(configurationResourceKeys);
return configBB;
}
diff --git a/bpmn/so-bpmn-tasks/src/test/java/org/onap/so/bpmn/infrastructure/workflow/tasks/WorkflowActionBBFailureTest.java b/bpmn/so-bpmn-tasks/src/test/java/org/onap/so/bpmn/infrastructure/workflow/tasks/WorkflowActionBBFailureTest.java
index 7f44c97f59..23ffbac645 100644
--- a/bpmn/so-bpmn-tasks/src/test/java/org/onap/so/bpmn/infrastructure/workflow/tasks/WorkflowActionBBFailureTest.java
+++ b/bpmn/so-bpmn-tasks/src/test/java/org/onap/so/bpmn/infrastructure/workflow/tasks/WorkflowActionBBFailureTest.java
@@ -144,7 +144,8 @@ public class WorkflowActionBBFailureTest extends BaseTaskTest {
@Test
public void updateRequestStatusToFailedRollbackFabric() {
BuildingBlock bb = new BuildingBlock().setBpmnFlowName("UnassignFabricConfigurationBB");
- ExecuteBuildingBlock ebb = new ExecuteBuildingBlock().setBuildingBlock(bb);
+ ExecuteBuildingBlock ebb = new ExecuteBuildingBlock();
+ ebb.setBuildingBlock(bb);
execution.setVariable("buildingBlock", ebb);
execution.setVariable("mso-request-id", "123");
execution.setVariable("isRollbackComplete", false);
diff --git a/bpmn/so-bpmn-tasks/src/test/java/org/onap/so/bpmn/infrastructure/workflow/tasks/WorkflowActionBBTasksTest.java b/bpmn/so-bpmn-tasks/src/test/java/org/onap/so/bpmn/infrastructure/workflow/tasks/WorkflowActionBBTasksTest.java
index a736d85197..9b41d0fada 100644
--- a/bpmn/so-bpmn-tasks/src/test/java/org/onap/so/bpmn/infrastructure/workflow/tasks/WorkflowActionBBTasksTest.java
+++ b/bpmn/so-bpmn-tasks/src/test/java/org/onap/so/bpmn/infrastructure/workflow/tasks/WorkflowActionBBTasksTest.java
@@ -115,7 +115,9 @@ public class WorkflowActionBBTasksTest extends BaseTaskTest {
ModelInfo mi = new ModelInfo();
mi.setModelUuid(modelUuid);
rd.setModelInfo(mi);
- ExecuteBuildingBlock ebb = new ExecuteBuildingBlock().setBuildingBlock(buildingBlock).setRequestDetails(rd);
+ ExecuteBuildingBlock ebb = new ExecuteBuildingBlock();
+ ebb.setBuildingBlock(buildingBlock);
+ ebb.setRequestDetails(rd);
flowsToExecute.add(ebb);
List<VnfResourceCustomization> vnfResourceCustomizations = new ArrayList<>();
@@ -150,7 +152,9 @@ public class WorkflowActionBBTasksTest extends BaseTaskTest {
ModelInfo mi = new ModelInfo();
mi.setModelUuid(modelUuid);
rd.setModelInfo(mi);
- ExecuteBuildingBlock ebb = new ExecuteBuildingBlock().setBuildingBlock(buildingBlock).setRequestDetails(rd);
+ ExecuteBuildingBlock ebb = new ExecuteBuildingBlock();
+ ebb.setBuildingBlock(buildingBlock);
+ ebb.setRequestDetails(rd);
ExecuteBuildingBlock ebb2 = new ExecuteBuildingBlock();
flowsToExecute.add(ebb);
@@ -200,15 +204,18 @@ public class WorkflowActionBBTasksTest extends BaseTaskTest {
execution.setVariable("resourceName", EMPTY_STRING);
List<ExecuteBuildingBlock> flowsToExecute = new ArrayList<>();
BuildingBlock buildingBlock1 = new BuildingBlock().setBpmnFlowName("AssignVfModuleBB");
- ExecuteBuildingBlock ebb1 = new ExecuteBuildingBlock().setBuildingBlock(buildingBlock1);
+ ExecuteBuildingBlock ebb1 = new ExecuteBuildingBlock();
+ ebb1.setBuildingBlock(buildingBlock1);
flowsToExecute.add(ebb1);
BuildingBlock buildingBlock2 = new BuildingBlock().setBpmnFlowName("CreateVfModuleBB");
- ExecuteBuildingBlock ebb2 = new ExecuteBuildingBlock().setBuildingBlock(buildingBlock2);
+ ExecuteBuildingBlock ebb2 = new ExecuteBuildingBlock();
+ ebb2.setBuildingBlock(buildingBlock2);
flowsToExecute.add(ebb2);
BuildingBlock buildingBlock3 = new BuildingBlock().setBpmnFlowName("ActivateVfModuleBB");
- ExecuteBuildingBlock ebb3 = new ExecuteBuildingBlock().setBuildingBlock(buildingBlock3);
+ ExecuteBuildingBlock ebb3 = new ExecuteBuildingBlock();
+ ebb3.setBuildingBlock(buildingBlock3);
flowsToExecute.add(ebb3);
execution.setVariable("flowsToExecute", flowsToExecute);
@@ -231,15 +238,18 @@ public class WorkflowActionBBTasksTest extends BaseTaskTest {
execution.setVariable("resourceName", EMPTY_STRING);
List<ExecuteBuildingBlock> flowsToExecute = new ArrayList<>();
BuildingBlock buildingBlock1 = new BuildingBlock().setBpmnFlowName("AssignVfModuleBB");
- ExecuteBuildingBlock ebb1 = new ExecuteBuildingBlock().setBuildingBlock(buildingBlock1);
+ ExecuteBuildingBlock ebb1 = new ExecuteBuildingBlock();
+ ebb1.setBuildingBlock(buildingBlock1);
flowsToExecute.add(ebb1);
BuildingBlock buildingBlock2 = new BuildingBlock().setBpmnFlowName("CreateVfModuleBB");
- ExecuteBuildingBlock ebb2 = new ExecuteBuildingBlock().setBuildingBlock(buildingBlock2);
+ ExecuteBuildingBlock ebb2 = new ExecuteBuildingBlock();
+ ebb2.setBuildingBlock(buildingBlock2);
flowsToExecute.add(ebb2);
BuildingBlock buildingBlock3 = new BuildingBlock().setBpmnFlowName("ActivateVfModuleBB");
- ExecuteBuildingBlock ebb3 = new ExecuteBuildingBlock().setBuildingBlock(buildingBlock3);
+ ExecuteBuildingBlock ebb3 = new ExecuteBuildingBlock();
+ ebb3.setBuildingBlock(buildingBlock3);
flowsToExecute.add(ebb3);
execution.setVariable("flowsToExecute", flowsToExecute);
@@ -262,19 +272,23 @@ public class WorkflowActionBBTasksTest extends BaseTaskTest {
execution.setVariable("resourceName", EMPTY_STRING);
List<ExecuteBuildingBlock> flowsToExecute = new ArrayList<>();
BuildingBlock buildingBlock1 = new BuildingBlock().setBpmnFlowName("AssignServiceInstanceBB");
- ExecuteBuildingBlock ebb1 = new ExecuteBuildingBlock().setBuildingBlock(buildingBlock1);
+ ExecuteBuildingBlock ebb1 = new ExecuteBuildingBlock();
+ ebb1.setBuildingBlock(buildingBlock1);
flowsToExecute.add(ebb1);
BuildingBlock buildingBlock2 = new BuildingBlock().setBpmnFlowName("CreateNetworkCollectionBB");
- ExecuteBuildingBlock ebb2 = new ExecuteBuildingBlock().setBuildingBlock(buildingBlock2);
+ ExecuteBuildingBlock ebb2 = new ExecuteBuildingBlock();
+ ebb2.setBuildingBlock(buildingBlock2);
flowsToExecute.add(ebb2);
BuildingBlock buildingBlock3 = new BuildingBlock().setBpmnFlowName("AssignNetworkBB");
- ExecuteBuildingBlock ebb3 = new ExecuteBuildingBlock().setBuildingBlock(buildingBlock3);
+ ExecuteBuildingBlock ebb3 = new ExecuteBuildingBlock();
+ ebb3.setBuildingBlock(buildingBlock3);
flowsToExecute.add(ebb3);
BuildingBlock buildingBlock4 = new BuildingBlock().setBpmnFlowName("CreateNetworkBB");
- ExecuteBuildingBlock ebb4 = new ExecuteBuildingBlock().setBuildingBlock(buildingBlock4);
+ ExecuteBuildingBlock ebb4 = new ExecuteBuildingBlock();
+ ebb4.setBuildingBlock(buildingBlock4);
flowsToExecute.add(ebb4);
execution.setVariable("flowsToExecute", flowsToExecute);
@@ -298,15 +312,18 @@ public class WorkflowActionBBTasksTest extends BaseTaskTest {
List<ExecuteBuildingBlock> flowsToExecute = new ArrayList<>();
BuildingBlock buildingBlock1 = new BuildingBlock().setBpmnFlowName("AssignVfModuleBB");
- ExecuteBuildingBlock ebb1 = new ExecuteBuildingBlock().setBuildingBlock(buildingBlock1);
+ ExecuteBuildingBlock ebb1 = new ExecuteBuildingBlock();
+ ebb1.setBuildingBlock(buildingBlock1);
flowsToExecute.add(ebb1);
BuildingBlock buildingBlock2 = new BuildingBlock().setBpmnFlowName("CreateVfModuleBB");
- ExecuteBuildingBlock ebb2 = new ExecuteBuildingBlock().setBuildingBlock(buildingBlock2);
+ ExecuteBuildingBlock ebb2 = new ExecuteBuildingBlock();
+ ebb2.setBuildingBlock(buildingBlock2);
flowsToExecute.add(ebb2);
BuildingBlock buildingBlock3 = new BuildingBlock().setBpmnFlowName("ActivateVfModuleBB");
- ExecuteBuildingBlock ebb3 = new ExecuteBuildingBlock().setBuildingBlock(buildingBlock3);
+ ExecuteBuildingBlock ebb3 = new ExecuteBuildingBlock();
+ ebb3.setBuildingBlock(buildingBlock3);
flowsToExecute.add(ebb3);
execution.setVariable("flowsToExecute", flowsToExecute);
@@ -327,24 +344,29 @@ public class WorkflowActionBBTasksTest extends BaseTaskTest {
execution.setVariable("resourceName", "VfModule");
List<ExecuteBuildingBlock> flowsToExecute = new ArrayList<>();
BuildingBlock buildingBlock1 = new BuildingBlock().setBpmnFlowName("AssignVfModuleBB");
- ExecuteBuildingBlock ebb1 = new ExecuteBuildingBlock().setBuildingBlock(buildingBlock1);
+ ExecuteBuildingBlock ebb1 = new ExecuteBuildingBlock();
+ ebb1.setBuildingBlock(buildingBlock1);
flowsToExecute.add(ebb1);
BuildingBlock buildingBlock2 = new BuildingBlock().setBpmnFlowName("CreateVfModuleBB");
- ExecuteBuildingBlock ebb2 = new ExecuteBuildingBlock().setBuildingBlock(buildingBlock2);
+ ExecuteBuildingBlock ebb2 = new ExecuteBuildingBlock();
+ ebb2.setBuildingBlock(buildingBlock2);
flowsToExecute.add(ebb2);
BuildingBlock buildingBlock3 = new BuildingBlock().setBpmnFlowName("ActivateVfModuleBB");
- ExecuteBuildingBlock ebb3 = new ExecuteBuildingBlock().setBuildingBlock(buildingBlock3);
+ ExecuteBuildingBlock ebb3 = new ExecuteBuildingBlock();
+ ebb3.setBuildingBlock(buildingBlock3);
flowsToExecute.add(ebb3);
BuildingBlock buildingBlock4 = new BuildingBlock().setBpmnFlowName("ChangeModelVnfBB");
- ExecuteBuildingBlock ebb4 = new ExecuteBuildingBlock().setBuildingBlock(buildingBlock4);
+ ExecuteBuildingBlock ebb4 = new ExecuteBuildingBlock();
+ ebb4.setBuildingBlock(buildingBlock4);
flowsToExecute.add(ebb4);
BuildingBlock buildingBlock5 = new BuildingBlock().setBpmnFlowName("ChangeModelServiceInstanceBB");
- ExecuteBuildingBlock ebb5 = new ExecuteBuildingBlock().setBuildingBlock(buildingBlock5);
+ ExecuteBuildingBlock ebb5 = new ExecuteBuildingBlock();
+ ebb5.setBuildingBlock(buildingBlock5);
flowsToExecute.add(ebb5);
execution.setVariable("flowsToExecute", flowsToExecute);
@@ -367,19 +389,23 @@ public class WorkflowActionBBTasksTest extends BaseTaskTest {
List<ExecuteBuildingBlock> flowsToExecute = new ArrayList<>();
BuildingBlock buildingBlock1 = new BuildingBlock().setBpmnFlowName("AssignVfModuleBB");
- ExecuteBuildingBlock ebb1 = new ExecuteBuildingBlock().setBuildingBlock(buildingBlock1);
+ ExecuteBuildingBlock ebb1 = new ExecuteBuildingBlock();
+ ebb1.setBuildingBlock(buildingBlock1);
flowsToExecute.add(ebb1);
BuildingBlock buildingBlock2 = new BuildingBlock().setBpmnFlowName("CreateVfModuleBB");
- ExecuteBuildingBlock ebb2 = new ExecuteBuildingBlock().setBuildingBlock(buildingBlock2);
+ ExecuteBuildingBlock ebb2 = new ExecuteBuildingBlock();
+ ebb2.setBuildingBlock(buildingBlock2);
flowsToExecute.add(ebb2);
BuildingBlock buildingBlock3 = new BuildingBlock().setBpmnFlowName("ActivateVfModuleBB");
- ExecuteBuildingBlock ebb3 = new ExecuteBuildingBlock().setBuildingBlock(buildingBlock3);
+ ExecuteBuildingBlock ebb3 = new ExecuteBuildingBlock();
+ ebb3.setBuildingBlock(buildingBlock3);
flowsToExecute.add(ebb3);
BuildingBlock buildingBlock4 = new BuildingBlock().setBpmnFlowName("AddFabricConfigurationBB");
- ExecuteBuildingBlock ebb4 = new ExecuteBuildingBlock().setBuildingBlock(buildingBlock4);
+ ExecuteBuildingBlock ebb4 = new ExecuteBuildingBlock();
+ ebb4.setBuildingBlock(buildingBlock4);
flowsToExecute.add(ebb4);
execution.setVariable("flowsToExecute", flowsToExecute);
@@ -403,15 +429,18 @@ public class WorkflowActionBBTasksTest extends BaseTaskTest {
execution.setVariable("resourceName", EMPTY_STRING);
List<ExecuteBuildingBlock> flowsToExecute = new ArrayList<>();
BuildingBlock buildingBlock1 = new BuildingBlock().setBpmnFlowName("AssignVfModuleBB");
- ExecuteBuildingBlock ebb1 = new ExecuteBuildingBlock().setBuildingBlock(buildingBlock1);
+ ExecuteBuildingBlock ebb1 = new ExecuteBuildingBlock();
+ ebb1.setBuildingBlock(buildingBlock1);
flowsToExecute.add(ebb1);
BuildingBlock buildingBlock2 = new BuildingBlock().setBpmnFlowName("CreateVfModuleBB");
- ExecuteBuildingBlock ebb2 = new ExecuteBuildingBlock().setBuildingBlock(buildingBlock2);
+ ExecuteBuildingBlock ebb2 = new ExecuteBuildingBlock();
+ ebb2.setBuildingBlock(buildingBlock2);
flowsToExecute.add(ebb2);
BuildingBlock buildingBlock3 = new BuildingBlock().setBpmnFlowName("ActivateVfModuleBB");
- ExecuteBuildingBlock ebb3 = new ExecuteBuildingBlock().setBuildingBlock(buildingBlock3);
+ ExecuteBuildingBlock ebb3 = new ExecuteBuildingBlock();
+ ebb3.setBuildingBlock(buildingBlock3);
flowsToExecute.add(ebb3);
execution.setVariable("flowsToExecute", flowsToExecute);
@@ -432,43 +461,53 @@ public class WorkflowActionBBTasksTest extends BaseTaskTest {
execution.setVariable("resourceName", EMPTY_STRING);
List<ExecuteBuildingBlock> flowsToExecute = new ArrayList<>();
BuildingBlock buildingBlock1 = new BuildingBlock().setBpmnFlowName("VNFCheckPserversLockedFlagActivity");
- ExecuteBuildingBlock ebb1 = new ExecuteBuildingBlock().setBuildingBlock(buildingBlock1);
+ ExecuteBuildingBlock ebb1 = new ExecuteBuildingBlock();
+ ebb1.setBuildingBlock(buildingBlock1);
flowsToExecute.add(ebb1);
BuildingBlock buildingBlock2 = new BuildingBlock().setBpmnFlowName("VNFCheckInMaintFlagActivity");
- ExecuteBuildingBlock ebb2 = new ExecuteBuildingBlock().setBuildingBlock(buildingBlock2);
+ ExecuteBuildingBlock ebb2 = new ExecuteBuildingBlock();
+ ebb2.setBuildingBlock(buildingBlock2);
flowsToExecute.add(ebb2);
BuildingBlock buildingBlock3 = new BuildingBlock().setBpmnFlowName("VNFSetInMaintFlagActivity");
- ExecuteBuildingBlock ebb3 = new ExecuteBuildingBlock().setBuildingBlock(buildingBlock3);
+ ExecuteBuildingBlock ebb3 = new ExecuteBuildingBlock();
+ ebb3.setBuildingBlock(buildingBlock3);
flowsToExecute.add(ebb3);
BuildingBlock buildingBlock4 = new BuildingBlock().setBpmnFlowName("VNFCheckClosedLoopDisabledFlagActivity");
- ExecuteBuildingBlock ebb4 = new ExecuteBuildingBlock().setBuildingBlock(buildingBlock4);
+ ExecuteBuildingBlock ebb4 = new ExecuteBuildingBlock();
+ ebb4.setBuildingBlock(buildingBlock4);
flowsToExecute.add(ebb4);
BuildingBlock buildingBlock5 = new BuildingBlock().setBpmnFlowName("VNFSetClosedLoopDisabledFlagActivity");
- ExecuteBuildingBlock ebb5 = new ExecuteBuildingBlock().setBuildingBlock(buildingBlock5);
+ ExecuteBuildingBlock ebb5 = new ExecuteBuildingBlock();
+ ebb5.setBuildingBlock(buildingBlock5);
flowsToExecute.add(ebb5);
BuildingBlock buildingBlock6 = new BuildingBlock().setBpmnFlowName("VNFLockActivity");
- ExecuteBuildingBlock ebb6 = new ExecuteBuildingBlock().setBuildingBlock(buildingBlock6);
+ ExecuteBuildingBlock ebb6 = new ExecuteBuildingBlock();
+ ebb6.setBuildingBlock(buildingBlock6);
flowsToExecute.add(ebb6);
BuildingBlock buildingBlock7 = new BuildingBlock().setBpmnFlowName("VNFUpgradePreCheckActivity");
- ExecuteBuildingBlock ebb7 = new ExecuteBuildingBlock().setBuildingBlock(buildingBlock7);
+ ExecuteBuildingBlock ebb7 = new ExecuteBuildingBlock();
+ ebb7.setBuildingBlock(buildingBlock7);
flowsToExecute.add(ebb7);
BuildingBlock buildingBlock8 = new BuildingBlock().setBpmnFlowName("VNFQuiesceTrafficActivity");
- ExecuteBuildingBlock ebb8 = new ExecuteBuildingBlock().setBuildingBlock(buildingBlock8);
+ ExecuteBuildingBlock ebb8 = new ExecuteBuildingBlock();
+ ebb8.setBuildingBlock(buildingBlock8);
flowsToExecute.add(ebb8);
BuildingBlock buildingBlock9 = new BuildingBlock().setBpmnFlowName("VNFStopActivity");
- ExecuteBuildingBlock ebb9 = new ExecuteBuildingBlock().setBuildingBlock(buildingBlock9);
+ ExecuteBuildingBlock ebb9 = new ExecuteBuildingBlock();
+ ebb9.setBuildingBlock(buildingBlock9);
flowsToExecute.add(ebb9);
BuildingBlock buildingBlock10 = new BuildingBlock().setBpmnFlowName("VNFSnapShotActivity");
- ExecuteBuildingBlock ebb10 = new ExecuteBuildingBlock().setBuildingBlock(buildingBlock10);
+ ExecuteBuildingBlock ebb10 = new ExecuteBuildingBlock();
+ ebb10.setBuildingBlock(buildingBlock10);
flowsToExecute.add(ebb10);
execution.setVariable("flowsToExecute", flowsToExecute);
@@ -493,27 +532,33 @@ public class WorkflowActionBBTasksTest extends BaseTaskTest {
execution.setVariable("resourceName", EMPTY_STRING);
List<ExecuteBuildingBlock> flowsToExecute = new ArrayList<>();
BuildingBlock buildingBlock1 = new BuildingBlock().setBpmnFlowName("VNFCheckPserversLockedFlagActivity");
- ExecuteBuildingBlock ebb1 = new ExecuteBuildingBlock().setBuildingBlock(buildingBlock1);
+ ExecuteBuildingBlock ebb1 = new ExecuteBuildingBlock();
+ ebb1.setBuildingBlock(buildingBlock1);
flowsToExecute.add(ebb1);
BuildingBlock buildingBlock2 = new BuildingBlock().setBpmnFlowName("VNFCheckInMaintFlagActivity");
- ExecuteBuildingBlock ebb2 = new ExecuteBuildingBlock().setBuildingBlock(buildingBlock2);
+ ExecuteBuildingBlock ebb2 = new ExecuteBuildingBlock();
+ ebb2.setBuildingBlock(buildingBlock2);
flowsToExecute.add(ebb2);
BuildingBlock buildingBlock3 = new BuildingBlock().setBpmnFlowName("VNFSetInMaintFlagActivity");
- ExecuteBuildingBlock ebb3 = new ExecuteBuildingBlock().setBuildingBlock(buildingBlock3);
+ ExecuteBuildingBlock ebb3 = new ExecuteBuildingBlock();
+ ebb3.setBuildingBlock(buildingBlock3);
flowsToExecute.add(ebb3);
BuildingBlock buildingBlock4 = new BuildingBlock().setBpmnFlowName("VNFCheckClosedLoopDisabledFlagActivity");
- ExecuteBuildingBlock ebb4 = new ExecuteBuildingBlock().setBuildingBlock(buildingBlock4);
+ ExecuteBuildingBlock ebb4 = new ExecuteBuildingBlock();
+ ebb4.setBuildingBlock(buildingBlock4);
flowsToExecute.add(ebb4);
BuildingBlock buildingBlock5 = new BuildingBlock().setBpmnFlowName("VNFSetClosedLoopDisabledFlagActivity");
- ExecuteBuildingBlock ebb5 = new ExecuteBuildingBlock().setBuildingBlock(buildingBlock5);
+ ExecuteBuildingBlock ebb5 = new ExecuteBuildingBlock();
+ ebb5.setBuildingBlock(buildingBlock5);
flowsToExecute.add(ebb5);
BuildingBlock buildingBlock6 = new BuildingBlock().setBpmnFlowName("VNFHealthCheckActivity");
- ExecuteBuildingBlock ebb6 = new ExecuteBuildingBlock().setBuildingBlock(buildingBlock6);
+ ExecuteBuildingBlock ebb6 = new ExecuteBuildingBlock();
+ ebb6.setBuildingBlock(buildingBlock6);
flowsToExecute.add(ebb6);
execution.setVariable("flowsToExecute", flowsToExecute);
diff --git a/bpmn/so-bpmn-tasks/src/test/java/org/onap/so/bpmn/infrastructure/workflow/tasks/WorkflowActionBBTasksUpdateReqDbTest.java b/bpmn/so-bpmn-tasks/src/test/java/org/onap/so/bpmn/infrastructure/workflow/tasks/WorkflowActionBBTasksUpdateReqDbTest.java
index 73aace7592..e064fb0b64 100644
--- a/bpmn/so-bpmn-tasks/src/test/java/org/onap/so/bpmn/infrastructure/workflow/tasks/WorkflowActionBBTasksUpdateReqDbTest.java
+++ b/bpmn/so-bpmn-tasks/src/test/java/org/onap/so/bpmn/infrastructure/workflow/tasks/WorkflowActionBBTasksUpdateReqDbTest.java
@@ -68,10 +68,12 @@ public class WorkflowActionBBTasksUpdateReqDbTest extends BaseTaskTest {
public void getUpdatedRequestTest() throws Exception {
List<ExecuteBuildingBlock> flowsToExecute = new ArrayList();
BuildingBlock bb1 = new BuildingBlock().setBpmnFlowName("CreateNetworkBB");
- ExecuteBuildingBlock ebb1 = new ExecuteBuildingBlock().setBuildingBlock(bb1);
+ ExecuteBuildingBlock ebb1 = new ExecuteBuildingBlock();
+ ebb1.setBuildingBlock(bb1);
flowsToExecute.add(ebb1);
BuildingBlock bb2 = new BuildingBlock().setBpmnFlowName("ActivateNetworkBB");
- ExecuteBuildingBlock ebb2 = new ExecuteBuildingBlock().setBuildingBlock(bb2);
+ ExecuteBuildingBlock ebb2 = new ExecuteBuildingBlock();
+ ebb2.setBuildingBlock(bb2);
flowsToExecute.add(ebb2);
String requestId = "requestId";
execution.setVariable("mso-request-id", requestId);
diff --git a/bpmn/so-bpmn-tasks/src/test/java/org/onap/so/bpmn/infrastructure/workflow/tasks/WorkflowActionTest.java b/bpmn/so-bpmn-tasks/src/test/java/org/onap/so/bpmn/infrastructure/workflow/tasks/WorkflowActionTest.java
index e24eaf0581..c762c16d92 100644
--- a/bpmn/so-bpmn-tasks/src/test/java/org/onap/so/bpmn/infrastructure/workflow/tasks/WorkflowActionTest.java
+++ b/bpmn/so-bpmn-tasks/src/test/java/org/onap/so/bpmn/infrastructure/workflow/tasks/WorkflowActionTest.java
@@ -1647,10 +1647,19 @@ public class WorkflowActionTest extends BaseTaskTest {
List<OrchestrationFlow> orchFlows = createFlowList("DeactivateVfModuleBB", "DeleteVfModuleBB",
"UnassignVfModuleBB", "DeactivateFabricConfigurationBB", "UnassignFabricConfigurationBB");
- ConfigBuildingBlocksDataObject dataObj = new ConfigBuildingBlocksDataObject().setsIRequest(sIRequest)
- .setOrchFlows(orchFlows).setRequestId(requestId).setResourceKey(resourceKey).setApiVersion(apiVersion)
- .setResourceId(resourceId).setRequestAction(requestAction).setaLaCarte(aLaCarte).setVnfType(vnfType)
- .setWorkflowResourceIds(workflowResourceIds).setRequestDetails(requestDetails).setExecution(execution);
+ ConfigBuildingBlocksDataObject dataObj = new ConfigBuildingBlocksDataObject();
+ dataObj.setsIRequest(sIRequest);
+ dataObj.setOrchFlows(orchFlows);
+ dataObj.setRequestId(requestId);
+ dataObj.setResourceKey(resourceKey);
+ dataObj.setApiVersion(apiVersion);
+ dataObj.setResourceId(resourceId);
+ dataObj.setRequestAction(requestAction);
+ dataObj.setaLaCarte(aLaCarte);
+ dataObj.setVnfType(vnfType);
+ dataObj.setWorkflowResourceIds(workflowResourceIds);
+ dataObj.setRequestDetails(requestDetails);
+ dataObj.setExecution(execution);
org.onap.aai.domain.yang.GenericVnf vnf = new org.onap.aai.domain.yang.GenericVnf();
vnf.setVnfId("vnf0");
@@ -1807,27 +1816,33 @@ public class WorkflowActionTest extends BaseTaskTest {
List<ExecuteBuildingBlock> executeFlows = new ArrayList<>();
BuildingBlock bb = new BuildingBlock().setBpmnFlowName("AssignNetworkBB").setKey("0");
- ExecuteBuildingBlock ebb = new ExecuteBuildingBlock().setBuildingBlock(bb);
+ ExecuteBuildingBlock ebb = new ExecuteBuildingBlock();
+ ebb.setBuildingBlock(bb);
executeFlows.add(ebb);
BuildingBlock bb2 = new BuildingBlock().setBpmnFlowName("AssignNetworkBB").setKey("1");
- ExecuteBuildingBlock ebb2 = new ExecuteBuildingBlock().setBuildingBlock(bb2);
+ ExecuteBuildingBlock ebb2 = new ExecuteBuildingBlock();
+ ebb2.setBuildingBlock(bb2);
executeFlows.add(ebb2);
BuildingBlock bb3 = new BuildingBlock().setBpmnFlowName("CreateNetworkBB").setKey("0");
- ExecuteBuildingBlock ebb3 = new ExecuteBuildingBlock().setBuildingBlock(bb3);
+ ExecuteBuildingBlock ebb3 = new ExecuteBuildingBlock();
+ ebb3.setBuildingBlock(bb3);
executeFlows.add(ebb3);
BuildingBlock bb4 = new BuildingBlock().setBpmnFlowName("CreateNetworkBB").setKey("1");
- ExecuteBuildingBlock ebb4 = new ExecuteBuildingBlock().setBuildingBlock(bb4);
+ ExecuteBuildingBlock ebb4 = new ExecuteBuildingBlock();
+ ebb4.setBuildingBlock(bb4);
executeFlows.add(ebb4);
BuildingBlock bb5 = new BuildingBlock().setBpmnFlowName("ActivateNetworkBB").setKey("0");
- ExecuteBuildingBlock ebb5 = new ExecuteBuildingBlock().setBuildingBlock(bb5);
+ ExecuteBuildingBlock ebb5 = new ExecuteBuildingBlock();
+ ebb5.setBuildingBlock(bb5);
executeFlows.add(ebb5);
BuildingBlock bb6 = new BuildingBlock().setBpmnFlowName("ActivateNetworkBB").setKey("1");
- ExecuteBuildingBlock ebb6 = new ExecuteBuildingBlock().setBuildingBlock(bb6);
+ ExecuteBuildingBlock ebb6 = new ExecuteBuildingBlock();
+ ebb6.setBuildingBlock(bb6);
executeFlows.add(ebb6);
List<ExecuteBuildingBlock> sorted =
@@ -1841,27 +1856,33 @@ public class WorkflowActionTest extends BaseTaskTest {
List<ExecuteBuildingBlock> executeFlows = new ArrayList<>();
BuildingBlock bb = new BuildingBlock().setBpmnFlowName("DeactivateNetworkBB").setKey("0");
- ExecuteBuildingBlock ebb = new ExecuteBuildingBlock().setBuildingBlock(bb);
+ ExecuteBuildingBlock ebb = new ExecuteBuildingBlock();
+ ebb.setBuildingBlock(bb);
executeFlows.add(ebb);
BuildingBlock bb2 = new BuildingBlock().setBpmnFlowName("DeactivateNetworkBB").setKey("1");
- ExecuteBuildingBlock ebb2 = new ExecuteBuildingBlock().setBuildingBlock(bb2);
+ ExecuteBuildingBlock ebb2 = new ExecuteBuildingBlock();
+ ebb2.setBuildingBlock(bb2);
executeFlows.add(ebb2);
BuildingBlock bb3 = new BuildingBlock().setBpmnFlowName("DeleteNetworkBB").setKey("0");
- ExecuteBuildingBlock ebb3 = new ExecuteBuildingBlock().setBuildingBlock(bb3);
+ ExecuteBuildingBlock ebb3 = new ExecuteBuildingBlock();
+ ebb3.setBuildingBlock(bb3);
executeFlows.add(ebb3);
BuildingBlock bb4 = new BuildingBlock().setBpmnFlowName("DeleteNetworkBB").setKey("1");
- ExecuteBuildingBlock ebb4 = new ExecuteBuildingBlock().setBuildingBlock(bb4);
+ ExecuteBuildingBlock ebb4 = new ExecuteBuildingBlock();
+ ebb4.setBuildingBlock(bb4);
executeFlows.add(ebb4);
BuildingBlock bb5 = new BuildingBlock().setBpmnFlowName("UnassignNetworkBB").setKey("0");
- ExecuteBuildingBlock ebb5 = new ExecuteBuildingBlock().setBuildingBlock(bb5);
+ ExecuteBuildingBlock ebb5 = new ExecuteBuildingBlock();
+ ebb5.setBuildingBlock(bb5);
executeFlows.add(ebb5);
BuildingBlock bb6 = new BuildingBlock().setBpmnFlowName("UnassignNetworkBB").setKey("1");
- ExecuteBuildingBlock ebb6 = new ExecuteBuildingBlock().setBuildingBlock(bb6);
+ ExecuteBuildingBlock ebb6 = new ExecuteBuildingBlock();
+ ebb6.setBuildingBlock(bb6);
executeFlows.add(ebb6);
List<ExecuteBuildingBlock> sorted =
diff --git a/bpmn/so-bpmn-tasks/src/test/java/org/onap/so/bpmn/infrastructure/workflow/tasks/listeners/MultiStageSkipListenerTest.java b/bpmn/so-bpmn-tasks/src/test/java/org/onap/so/bpmn/infrastructure/workflow/tasks/listeners/MultiStageSkipListenerTest.java
index 9d208f41e8..1b4ddf71c2 100644
--- a/bpmn/so-bpmn-tasks/src/test/java/org/onap/so/bpmn/infrastructure/workflow/tasks/listeners/MultiStageSkipListenerTest.java
+++ b/bpmn/so-bpmn-tasks/src/test/java/org/onap/so/bpmn/infrastructure/workflow/tasks/listeners/MultiStageSkipListenerTest.java
@@ -91,8 +91,10 @@ public class MultiStageSkipListenerTest {
workflowResourceIds.setServiceInstanceId("serviceInstanceId");
workflowResourceIds.setVnfId(vnfId);
BuildingBlock bb = new BuildingBlock().setBpmnFlowName("AssignVfModuleBB");
- ExecuteBuildingBlock ebb = new ExecuteBuildingBlock().setResourceId(vfModuleId).setBuildingBlock(bb)
- .setWorkflowResourceIds(workflowResourceIds);
+ ExecuteBuildingBlock ebb = new ExecuteBuildingBlock();
+ ebb.setResourceId(vfModuleId);
+ ebb.setBuildingBlock(bb);
+ ebb.setWorkflowResourceIds(workflowResourceIds);
flowsToExecute.add(ebb);
flowsToExecute.add(new ExecuteBuildingBlock());
flowsToExecute.add(new ExecuteBuildingBlock());