-
- - name: 'Chuanyu Chen'
- email: 'chenchuanyu@huawei.com'
- company: 'Huawei'
- id: 'boychuanyu'
- timezone: 'Asia/Shanghai'
+---
+project: 'so'
+project_creation_date: '2017-06-15'
+lifecycle_state: 'Mature'
+project_category: ''
+project_lead: &onap_releng_ptl
+ name: 'Seshu Kumar M'
+ email: 'seshu.kumar.m@huawei.com'
+ id: 'seshukm'
+ company: 'Huawei Technologies India Pvt Ltd'
+ timezone: 'India/Bangalore'
+primary_contact: *onap_releng_ptl
+issue_tracking:
+ type: 'jira'
+ url: 'https://jira.onap.org/projects/SO'
+ key: 'SO'
+mailing_list:
+ type: 'groups.io'
+ url: 'lists.onap.org'
+ tag: '<[sub-project_name]>'
+realtime_discussion: ''
+meetings:
+ - type: 'zoom'
+ agenda: 'https://wiki.onap.org/display/DW/Service+Orchestrator+Project'
+ url: 'https://wiki.onap.org/display/DW/Service+Orchestrator+Project'
+ server: 'n/a'
+ channel: 'n/a'
+ repeats: 'weekly'
+ time: '12:30 UTC'
+repositories:
+ - 'so'
+committers:
+ - <<: *onap_releng_ptl
- name: 'Byung-Woo Jun'
email: 'byung-woo.jun@ericsson.com'
company: 'Ericsson'
id: 'byungwoojun'
timezone: 'America/New_York'
- - name: 'Steve Smokowski'
- email: 'ss835w@att.com'
- company: 'ATT'
- id: 'stevesmokowski'
- timezone: 'America/New_York'
- - name: 'Lukasz Muszkieta'
- email: 'lukasz.muszkieta@nokia.com'
- company: 'Nokia'
- id: 'lukaszM'
- timezone: 'Europe/Warsaw'
- - name: 'Ramesh Parthasarathy'
- email: 'ramesh.parthasarathy@att.com'
- company: 'ATT'
- id: 'parthasram'
- timezone: 'PST'
+ - name: 'Waqas Ikram'
+ email: 'waqas.ikram@est.tech'
+ company: 'Ericsson'
+ id: 'waqas ikram'
+ timezone: 'Ireland/Dublin'
+ - name: 'Lukasz Rajewski'
+ email: 'lukasz.rajewski@orange.com'
+ company: 'Orange'
+ id: 'Lukasz Rajewski'
+ timezone: 'Poland/Warsaw'
+ - name: 'Shashikanth VH'
+ email: 'shashikanth.vh@huawei.com'
+ company: 'Huawei Technologies India Pvt Ltd'
+ id: 'Shashikanth VH'
+ timezone: 'India/Bangalore'
+ - name: 'Jozsef Csongvai'
+ email: 'jozsef.csongvai@bell.ca'
+ company: 'Bell Canada'
+ id: 'Jozsef Csongvai'
+ timezone: 'Canada/Ontario'
+ - name: 'Md Irshad Sheikh'
+ email: 'md.irshad.sheikh@huawei.com'
+ company: 'Huawei Technologies India Pvt Ltd'
+ id: 'Md Irshad Sheikh'
+ timezone: 'India/Bangalore'
tsc:
approval: 'https://lists.onap.org/pipermail/onap-tsc'
changes:
link: 'https://lists.onap.org/g/onap-tsc/message/4320'
- type: 'removal'
name: 'Rob Daugherty'
- link: 'https://lists.onap.org/g/onap-tsc/message/4320'
+ link: 'https://lists.onap.org/g/onap-tsc/message/4320'
- type: 'addition'
name: 'Max Benjamin'
link: 'https://lists.onap.org/g/onap-tsc/message/4320'
- type: 'removal'
name: 'Max Benjamin'
link: 'https://wiki.onap.org/display/DW/2021+TSC+Decisions'
+ - type: 'removal'
+ name: 'Steve'
+ link: 'https://wiki.onap.org/display/Meetings/TSC+2022-03-03'
('VNF-Create', 'createInstance', 'Vnf', true,true, '7', '7', 'DEFAULT', '*'),
('VNF-Delete', 'deleteInstance', 'Vnf', true,true, '7', '7', 'DEFAULT', '*'),
('VNF-Macro-Delete', 'deleteInstance', 'Vnf', false,true, '7', '7', 'DEFAULT', '*'),
-('VNF-Macro-Modify', 'updateInstance', 'Vnf', false,true, '7', '7','k8scloudowner4', '*'),
+('VNF-Macro-Modify', 'updateInstance', 'Vnf', false,true, '7', '7','DEFAULT', '*'),
('VNF-Macro-HealthCheck', 'healthCheck', 'Vnf', false,true, '7', '7','DEFAULT', '*'),
('VolumeGroup-Create', 'createInstance', 'VolumeGroup', true,true, '7','7', 'DEFAULT', '*'),
('VolumeGroup-Delete', 'deleteInstance', 'VolumeGroup', true,true, '7','7', 'DEFAULT', '*'),
('NetworkCollection-Macro-Delete', 'deleteInstance', 'NetworkCollection', false,true, '7','7', 'DEFAULT', '*'),
('VFModule-ScaleOut', 'scaleOut', 'VfModule', true, true, '7','7', 'DEFAULT', '*'),
('VNF-InPlaceUpdate', 'inPlaceSoftwareUpdate', 'Vnf', true, true, '7','7', 'DEFAULT', '*'),
-('VNF-Config-Update', 'applyUpdatedConfig', 'Vnf', true, true, '7','7', 'DEFAULT', '*');
+('VNF-Config-Update', 'applyUpdatedConfig', 'Vnf', true, true, '7','7', 'DEFAULT', '*'),
+('CNF-Macro-Upgrade', 'upgradeCnf', 'Vnf', false,true, '7', '7','DEFAULT', '*');
INSERT INTO orchestration_flow_reference(COMPOSITE_ACTION, SEQ_NO, FLOW_NAME, SCOPE, ACTION, FLOW_VERSION, NB_REQ_REF_LOOKUP_ID) VALUES
('VNF-Config-Update', '7', 'VNFHealthCheckActivity', NULL, NULL, 1.0,(SELECT id from northbound_request_ref_lookup WHERE MACRO_ACTION = 'VNF-Config-Update' and CLOUD_OWNER = 'DEFAULT')),
('VNF-Config-Update', '8', 'VNFUnsetInMaintFlagActivity', NULL, NULL, 1.0,(SELECT id from northbound_request_ref_lookup WHERE MACRO_ACTION = 'VNF-Config-Update' and CLOUD_OWNER = 'DEFAULT')),
('VNF-Config-Update', '9', 'VNFUnsetClosedLoopDisabledFlagActivity', NULL, NULL, 1.0,(SELECT id from northbound_request_ref_lookup WHERE MACRO_ACTION = 'VNF-Config-Update' and CLOUD_OWNER = 'DEFAULT')),
-('VNF-Macro-Modify', '1', 'ControllerExecutionBB', 'vnf', 'config-assign', 1.0,(SELECT id from northbound_request_ref_lookup WHERE MACRO_ACTION = 'VNF-Macro-Modify' and CLOUD_OWNER = 'k8scloudowner4')),
-('VNF-Macro-Modify', '2', 'ControllerExecutionBB', 'vnf', 'config-deploy', 1.0,(SELECT id from northbound_request_ref_lookup WHERE MACRO_ACTION = 'VNF-Macro-Modify' and CLOUD_OWNER = 'k8scloudowner4')),
-('VNF-Macro-HealthCheck', '1', 'HealthCheckBB', 'vnf', 'status-check', 1.0,(SELECT id from northbound_request_ref_lookup WHERE MACRO_ACTION = 'VNF-Macro-HealthCheck' and CLOUD_OWNER = 'DEFAULT'));
+('VNF-Macro-Modify', '1', 'ControllerExecutionBB', 'vnf', 'config-assign', 1.0,(SELECT id from northbound_request_ref_lookup WHERE MACRO_ACTION = 'VNF-Macro-Modify' and CLOUD_OWNER = 'DEFAULT')),
+('VNF-Macro-Modify', '2', 'ControllerExecutionBB', 'vnf', 'config-deploy', 1.0,(SELECT id from northbound_request_ref_lookup WHERE MACRO_ACTION = 'VNF-Macro-Modify' and CLOUD_OWNER = 'DEFAULT')),
+('VNF-Macro-HealthCheck', '1', 'HealthCheckBB', 'vnf', 'status-check', 1.0,(SELECT id from northbound_request_ref_lookup WHERE MACRO_ACTION = 'VNF-Macro-HealthCheck' and CLOUD_OWNER = 'DEFAULT')),
+('VNF-Macro-HealthCheck', '2', 'HealthCheckBB', 'vnf', 'health-check', 1.0,(SELECT id from northbound_request_ref_lookup WHERE MACRO_ACTION = 'VNF-Macro-HealthCheck' and CLOUD_OWNER = 'DEFAULT')),
+('CNF-Macro-Upgrade', '1', 'AAICheckVnfInMaintBB', NULL, NULL, 1.0,(SELECT id from northbound_request_ref_lookup WHERE MACRO_ACTION = 'CNF-Macro-Upgrade' and CLOUD_OWNER = 'DEFAULT')),
+('CNF-Macro-Upgrade', '2', 'AAISetVnfInMaintBB', NULL, NULL, 1.0,(SELECT id from northbound_request_ref_lookup WHERE MACRO_ACTION = 'CNF-Macro-Upgrade' and CLOUD_OWNER = 'DEFAULT')),
+('CNF-Macro-Upgrade', '3', 'DeactivateVfModuleBB', NULL, NULL, 1.0,(SELECT id from northbound_request_ref_lookup WHERE MACRO_ACTION = 'CNF-Macro-Upgrade' and CLOUD_OWNER = 'DEFAULT')),
+('CNF-Macro-Upgrade', '4', 'DeactivateVnfBB', NULL, NULL, 1.0,(SELECT id from northbound_request_ref_lookup WHERE MACRO_ACTION = 'CNF-Macro-Upgrade' and CLOUD_OWNER = 'DEFAULT')),
+('CNF-Macro-Upgrade', '5', 'ChangeModelVfModuleBB', NULL, NULL, 1.0,(SELECT id from northbound_request_ref_lookup WHERE MACRO_ACTION = 'CNF-Macro-Upgrade' and CLOUD_OWNER = 'DEFAULT')),
+('CNF-Macro-Upgrade', '6', 'ControllerExecutionBB', 'vnf', 'config-upgrade-assign', 1.0,(SELECT id from northbound_request_ref_lookup WHERE MACRO_ACTION = 'CNF-Macro-Upgrade' and CLOUD_OWNER = 'DEFAULT')),
+('CNF-Macro-Upgrade', '7', 'UpgradeVfModuleBB', NULL , NULL, 1.0,(SELECT id from northbound_request_ref_lookup WHERE MACRO_ACTION = 'CNF-Macro-Upgrade' and CLOUD_OWNER = 'DEFAULT')),
+('CNF-Macro-Upgrade', '8', 'ControllerExecutionBB', 'vnf', 'config-upgrade-deploy', 1.0,(SELECT id from northbound_request_ref_lookup WHERE MACRO_ACTION = 'CNF-Macro-Upgrade' and CLOUD_OWNER = 'DEFAULT')),
+('CNF-Macro-Upgrade', '9', 'ActivateVfModuleBB', NULL, NULL, 1.0,(SELECT id from northbound_request_ref_lookup WHERE MACRO_ACTION = 'CNF-Macro-Upgrade' and CLOUD_OWNER = 'DEFAULT')),
+('CNF-Macro-Upgrade', '10', 'ChangeModelVnfBB', NULL, NULL, 1.0,(SELECT id from northbound_request_ref_lookup WHERE MACRO_ACTION = 'CNF-Macro-Upgrade' and CLOUD_OWNER = 'DEFAULT')),
+('CNF-Macro-Upgrade', '11', 'ActivateVnfBB', NULL, NULL, 1.0,(SELECT id from northbound_request_ref_lookup WHERE MACRO_ACTION = 'CNF-Macro-Upgrade' and CLOUD_OWNER = 'DEFAULT')),
+('CNF-Macro-Upgrade', '12', 'AAIUnsetVnfInMaintBB', NULL, NULL, 1.0,(SELECT id from northbound_request_ref_lookup WHERE MACRO_ACTION = 'CNF-Macro-Upgrade' and CLOUD_OWNER = 'DEFAULT'));
INSERT INTO rainy_day_handler_macro (FLOW_NAME, SERVICE_TYPE, VNF_TYPE, ERROR_CODE, WORK_STEP, POLICY, SECONDARY_POLICY, REG_EX_ERROR_MESSAGE, SERVICE_ROLE)
VALUES
('VNFConfigModifyActivity', 'NO_VALIDATE', 'CUSTOM'),
('ConfigAssignVnfBB', 'NO_VALIDATE', 'CUSTOM'),
('ConfigDeployVnfBB', 'NO_VALIDATE', 'CUSTOM'),
-('ControllerExecutionBB', 'NO_VALIDATE', 'CUSTOM');
+('ControllerExecutionBB', 'NO_VALIDATE', 'CUSTOM'),
+('StatusCheckBB', 'NO_VALIDATE', 'CUSTOM'),
+('HealthCheckBB', 'NO_VALIDATE', 'CUSTOM'),
+('UpgradeVfModuleBB', 'NO_VALIDATE', 'CUSTOM');
+
INSERT INTO orchestration_status_state_transition_directive (resource_type, orchestration_status, target_action, flow_directive)
VALUES
INSERT INTO `service_recipe` (`id`, `ACTION`, `VERSION_STR`, `DESCRIPTION`, `ORCHESTRATION_URI`, `SERVICE_PARAM_XSD`, `RECIPE_TIMEOUT`, `SERVICE_TIMEOUT_INTERIM`, `CREATION_TIMESTAMP`, `SERVICE_MODEL_UUID`) VALUES (4,'deleteInstance','1','DEFAULT recipe to delete service-instance if no custom BPMN flow is found','/mso/async/services/DeleteGenericALaCarteServiceInstance',NULL,180,NULL,'2017-10-05 18:52:03','48cc3acd-a9fe-11e7-8b4b-0242ac120002');
insert into `service_recipe` (`id`, `ACTION`, `VERSION_STR`, `DESCRIPTION`, `ORCHESTRATION_URI`, `SERVICE_PARAM_XSD`, `RECIPE_TIMEOUT`, `SERVICE_TIMEOUT_INTERIM`, `CREATION_TIMESTAMP`, `SERVICE_MODEL_UUID`) values (500,'updateInstance','1.0','Gr api recipe to update service-instance', '/mso/async/services/WorkflowActionBB', NULL, 180, NULL, '2017-10-05 18:52:03', 'd88da85c-d9e8-4f73-b837-3a72a431622b');
insert into `service_recipe` (`id`, `ACTION`, `VERSION_STR`, `DESCRIPTION`, `ORCHESTRATION_URI`, `SERVICE_PARAM_XSD`, `RECIPE_TIMEOUT`, `SERVICE_TIMEOUT_INTERIM`, `CREATION_TIMESTAMP`, `SERVICE_MODEL_UUID`) values (501,'healthCheck','1.0','Gr api recipe to do CNF health check', '/mso/async/services/WorkflowActionBB', NULL, 180, NULL, '2021-08-20 18:52:03', 'd88da85c-d9e8-4f73-b837-3a72a431622b');
+insert into `service_recipe` (`id`, `ACTION`, `VERSION_STR`, `DESCRIPTION`, `ORCHESTRATION_URI`, `SERVICE_PARAM_XSD`, `RECIPE_TIMEOUT`, `SERVICE_TIMEOUT_INTERIM`, `CREATION_TIMESTAMP`, `SERVICE_MODEL_UUID`) values (525,'upgradeCnf','1.0','Gr api recipe to do CNF upgrade', '/mso/async/services/WorkflowActionBB', NULL, 180, NULL, '2022-01-20 18:52:03', 'd88da85c-d9e8-4f73-b837-3a72a431622b');
--
-- Custom Reciepe for the VoLTE service added temporarily
INSERT INTO `vnf_recipe` (`id`, `VF_MODULE_ID`, `ACTION`, `SERVICE_TYPE`, `VERSION_STR`, `VNF_TYPE`, `DESCRIPTION`, `ORCHESTRATION_URI`, `VNF_PARAM_XSD`, `RECIPE_TIMEOUT`, `CREATION_TIMESTAMP`) VALUES (12,NULL,'deleteInstance',NULL,'1','NS_DEFAULT','default custom E2E recipe to delete NS if no custom BPMN flow is found','/mso/async/services/DeleteVFCNSResource',NULL,180,'2018-04-18 18:52:03');
INSERT INTO `vnf_recipe` (`id`, `VF_MODULE_ID`, `ACTION`, `SERVICE_TYPE`, `VERSION_STR`, `VNF_TYPE`, `DESCRIPTION`, `ORCHESTRATION_URI`, `VNF_PARAM_XSD`, `RECIPE_TIMEOUT`, `CREATION_TIMESTAMP`) VALUES (13,NULL,'inPlaceSoftwareUpdate',NULL,'1','VID_DEFAULT','VID_DEFAULT recipe to update VNF software if no custom BPMN flow is found','/mso/async/services/VnfInPlaceUpdate',NULL,180,'2018-05-23 11:00:00');
INSERT INTO `vnf_recipe` (`id`, `VF_MODULE_ID`, `ACTION`, `SERVICE_TYPE`, `VERSION_STR`, `VNF_TYPE`, `DESCRIPTION`, `ORCHESTRATION_URI`, `VNF_PARAM_XSD`, `RECIPE_TIMEOUT`, `CREATION_TIMESTAMP`) VALUES (14,NULL,'applyUpdatedConfig',NULL,'1','VID_DEFAULT','VID_DEFAULT recipe to apply updated VNF config if no custom BPMN flow is found','/mso/async/services/VnfConfigUpdate',NULL,180,'2018-05-23 11:00:00');
-SET FOREIGN_KEY_CHECKS=1;
+INSERT INTO `vnf_recipe` (`id`, `VF_MODULE_ID`, `ACTION`, `SERVICE_TYPE`, `VERSION_STR`, `VNF_TYPE`, `DESCRIPTION`, `ORCHESTRATION_URI`, `VNF_PARAM_XSD`, `RECIPE_TIMEOUT`, `CREATION_TIMESTAMP`) VALUES (10030,NULL,'upgradeCnf',NULL,'1','GR-API-DEFAULT','Gr api recipe to do CNF-Upgrade','/mso/async/services/WorkflowActionBB',NULL,180,'2022-01-23 10:00:00');
+SET FOREIGN_KEY_CHECKS=1;
\ No newline at end of file
|| requestAction.equalsIgnoreCase("activateFabricConfiguration")
|| requestAction.equalsIgnoreCase("recreateInstance")
|| requestAction.equalsIgnoreCase("replaceInstance")
- || requestAction.equalsIgnoreCase("upgradeInstance")) {
+ || requestAction.equalsIgnoreCase("upgradeInstance") || requestAction.equalsIgnoreCase("healthCheck")) {
return getGBBMacroExistingService(executeBB, lookupKeyMap, bbName, requestAction,
requestDetails.getCloudConfiguration());
}
break;
}
}
+ } else if (bbName.equals("HealthCheckBB")
+ && (VNF).equalsIgnoreCase(executeBB.getBuildingBlock().getBpmnScope())) {
+ this.setisHelmforHealthCheckBB(service, serviceInstance, gBB);
}
if (executeBB.getWorkflowResourceIds() != null) {
parameter.setResourceId(executeBB.getWorkflowResourceIds().getNetworkCollectionId());
return collection;
}
+ private void setisHelmforHealthCheckBB(Service service, ServiceInstance serviceInstance, GeneralBuildingBlock gBB) {
+ for (GenericVnf vnf : serviceInstance.getVnfs()) {
+ for (VfModule vfModule : vnf.getVfModules()) {
+ String vnfModelCustomizationUUID =
+ this.bbInputSetupUtils.getAAIGenericVnf(vnf.getVnfId()).getModelCustomizationId();
+ ModelInfo vnfModelInfo = new ModelInfo();
+ vnfModelInfo.setModelCustomizationUuid(vnfModelCustomizationUUID);
+ this.mapCatalogVnf(vnf, vnfModelInfo, service);
+ String vfModuleCustomizationUUID = this.bbInputSetupUtils
+ .getAAIVfModule(vnf.getVnfId(), vfModule.getVfModuleId()).getModelCustomizationId();
+ ModelInfo vfModuleModelInfo = new ModelInfo();
+ vfModuleModelInfo.setModelCustomizationId(vfModuleCustomizationUUID);
+ this.mapCatalogVfModule(vfModule, vfModuleModelInfo, service, vnfModelCustomizationUUID);
+ if (vfModule.getModelInfoVfModule() != null && vfModule.getModelInfoVfModule().getModelName() != null
+ && vfModule.getModelInfoVfModule().getModelName().contains("helm")) {
+ gBB.getRequestContext().setIsHelm(true);
+ break;
+ }
+ }
+ }
+ }
+
protected void mapL3Networks(List<AAIResourceUri> list, List<L3Network> l3Networks) {
for (AAIResourceUri aaiResourceUri : list) {
l3Networks.add(this.mapL3Network(aaiResourceUri));
<?xml version="1.0" encoding="UTF-8"?>
-<bpmn:definitions xmlns:bpmn="http://www.omg.org/spec/BPMN/20100524/MODEL" xmlns:bpmndi="http://www.omg.org/spec/BPMN/20100524/DI" xmlns:dc="http://www.omg.org/spec/DD/20100524/DC" xmlns:camunda="http://camunda.org/schema/1.0/bpmn" xmlns:di="http://www.omg.org/spec/DD/20100524/DI" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" id="Definitions_1bvx7yi" targetNamespace="http://bpmn.io/schema/bpmn" exporter="Camunda Modeler" exporterVersion="4.0.0">
+<bpmn:definitions xmlns:bpmn="http://www.omg.org/spec/BPMN/20100524/MODEL" xmlns:bpmndi="http://www.omg.org/spec/BPMN/20100524/DI" xmlns:dc="http://www.omg.org/spec/DD/20100524/DC" xmlns:camunda="http://camunda.org/schema/1.0/bpmn" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:di="http://www.omg.org/spec/DD/20100524/DI" xmlns:modeler="http://camunda.org/schema/modeler/1.0" id="Definitions_0gwymqy" targetNamespace="http://bpmn.io/schema/bpmn" exporter="Camunda Modeler" exporterVersion="4.7.0" modeler:executionPlatform="Camunda Platform" modeler:executionPlatformVersion="7.14.0">
<bpmn:process id="HealthCheckBB" name="HealthCheckBB" isExecutable="true">
- <bpmn:startEvent id="StartEvent_1" name="HealthCheckBB_start">
- <bpmn:outgoing>Flow_0gd6hy6</bpmn:outgoing>
+ <bpmn:startEvent id="Event_0rgusxn" name="HealthCheckBB_start">
+ <bpmn:outgoing>Flow_0udh4cd</bpmn:outgoing>
</bpmn:startEvent>
- <bpmn:endEvent id="Event_1dklvvk" name="HealthCheckBB_end">
- <bpmn:incoming>Flow_0xiyno7</bpmn:incoming>
+ <bpmn:endEvent id="Event_0o1nl3y" name="HealthCheckBB_end">
+ <bpmn:incoming>Flow_0n17e0q</bpmn:incoming>
+ <bpmn:incoming>Flow_131rwms</bpmn:incoming>
</bpmn:endEvent>
- <bpmn:sequenceFlow id="Flow_0gd6hy6" sourceRef="StartEvent_1" targetRef="Activity_11hkwkn" />
- <bpmn:subProcess id="Activity_1pto2qh" name="Error Handling " triggeredByEvent="true">
- <bpmn:startEvent id="Event_0929aqj">
- <bpmn:outgoing>Flow_05rbrsm</bpmn:outgoing>
- <bpmn:errorEventDefinition id="ErrorEventDefinition_0k0ly65" />
+ <bpmn:subProcess id="Activity_0tw4ak3" name="Error Handling " triggeredByEvent="true">
+ <bpmn:startEvent id="Event_1v6jbfd">
+ <bpmn:outgoing>Flow_03ogqmx</bpmn:outgoing>
+ <bpmn:errorEventDefinition id="ErrorEventDefinition_1xw7dq4" />
</bpmn:startEvent>
- <bpmn:endEvent id="Event_1s698ql">
- <bpmn:incoming>Flow_05rbrsm</bpmn:incoming>
- <bpmn:terminateEventDefinition id="TerminateEventDefinition_0mn6xgi" />
+ <bpmn:endEvent id="Event_0wwzune">
+ <bpmn:incoming>Flow_03ogqmx</bpmn:incoming>
+ <bpmn:terminateEventDefinition id="TerminateEventDefinition_0c07ott" />
</bpmn:endEvent>
- <bpmn:sequenceFlow id="Flow_05rbrsm" sourceRef="Event_0929aqj" targetRef="Event_1s698ql" />
+ <bpmn:sequenceFlow id="Flow_03ogqmx" sourceRef="Event_1v6jbfd" targetRef="Event_0wwzune" />
</bpmn:subProcess>
- <bpmn:serviceTask id="Activity_11hkwkn" name="Prepare Cnf Adapter request" camunda:expression="${CnfHealthCheckTasks.prepareCnfAdaperRequest(InjectExecution.execute(execution, execution.getVariable("gBuildingBlockExecution")))}">
- <bpmn:incoming>Flow_0gd6hy6</bpmn:incoming>
- <bpmn:outgoing>Flow_1aqdd5k</bpmn:outgoing>
+ <bpmn:serviceTask id="Activity_0pnb21p" name="Prepare Cnf Adapter request" camunda:expression="${CnfHealthCheckTasks.prepareCnfAdaperRequest(InjectExecution.execute(execution, execution.getVariable("gBuildingBlockExecution")))}">
+ <bpmn:incoming>Flow_0jxw1lb</bpmn:incoming>
+ <bpmn:outgoing>Flow_0uoe9ga</bpmn:outgoing>
</bpmn:serviceTask>
- <bpmn:sequenceFlow id="Flow_1aqdd5k" sourceRef="Activity_11hkwkn" targetRef="Activity_08mgs1k" />
- <bpmn:callActivity id="Activity_08mgs1k" name="Call CNFAdapterAsyncCall" calledElement="CNFAdapterAsyncCall">
+ <bpmn:callActivity id="Activity_07txikn" name="Call CNFAdapterAsyncCall" calledElement="CNFAdapterAsyncCall">
<bpmn:extensionElements>
<camunda:in source="apiPath" target="apiPath" />
<camunda:in source="cnfRequestPayload" target="cnfRequestPayload" />
<camunda:in source="messageType" target="messageType" />
<camunda:in source="true" target="isDebugLogEnabled" />
</bpmn:extensionElements>
- <bpmn:incoming>Flow_1aqdd5k</bpmn:incoming>
- <bpmn:outgoing>Flow_1jeui7e</bpmn:outgoing>
+ <bpmn:incoming>Flow_0uoe9ga</bpmn:incoming>
+ <bpmn:outgoing>Flow_0t6f6l8</bpmn:outgoing>
</bpmn:callActivity>
- <bpmn:serviceTask id="Activity_0w4hy3d" name="Process Response" camunda:expression="${CnfHealthCheckTasks.processAsyncResponse(InjectExecution.execute(execution, execution.getVariable("gBuildingBlockExecution")))}">
- <bpmn:incoming>Flow_1jeui7e</bpmn:incoming>
- <bpmn:outgoing>Flow_0xiyno7</bpmn:outgoing>
+ <bpmn:serviceTask id="Activity_1qd7k3z" name="Process Response" camunda:expression="${CnfHealthCheckTasks.processAsyncResponse(InjectExecution.execute(execution, execution.getVariable("gBuildingBlockExecution")))}">
+ <bpmn:incoming>Flow_0t6f6l8</bpmn:incoming>
+ <bpmn:outgoing>Flow_0n17e0q</bpmn:outgoing>
</bpmn:serviceTask>
- <bpmn:sequenceFlow id="Flow_0xiyno7" sourceRef="Activity_0w4hy3d" targetRef="Event_1dklvvk" />
- <bpmn:sequenceFlow id="Flow_1jeui7e" sourceRef="Activity_08mgs1k" targetRef="Activity_0w4hy3d" />
+ <bpmn:exclusiveGateway id="Gateway_07e5xls" name="Check If Is Helm" default="Flow_131rwms">
+ <bpmn:incoming>Flow_0udh4cd</bpmn:incoming>
+ <bpmn:outgoing>Flow_131rwms</bpmn:outgoing>
+ <bpmn:outgoing>Flow_0jxw1lb</bpmn:outgoing>
+ </bpmn:exclusiveGateway>
+ <bpmn:sequenceFlow id="Flow_0udh4cd" sourceRef="Event_0rgusxn" targetRef="Gateway_07e5xls" />
+ <bpmn:sequenceFlow id="Flow_0n17e0q" sourceRef="Activity_1qd7k3z" targetRef="Event_0o1nl3y" />
+ <bpmn:sequenceFlow id="Flow_131rwms" name="No Helm" sourceRef="Gateway_07e5xls" targetRef="Event_0o1nl3y" />
+ <bpmn:sequenceFlow id="Flow_0jxw1lb" name="Yes Helm" sourceRef="Gateway_07e5xls" targetRef="Activity_0pnb21p">
+ <bpmn:conditionExpression xsi:type="bpmn:tFormalExpression">${execution.getVariable("isHelm")}</bpmn:conditionExpression>
+ </bpmn:sequenceFlow>
+ <bpmn:sequenceFlow id="Flow_0uoe9ga" sourceRef="Activity_0pnb21p" targetRef="Activity_07txikn" />
+ <bpmn:sequenceFlow id="Flow_0t6f6l8" sourceRef="Activity_07txikn" targetRef="Activity_1qd7k3z" />
</bpmn:process>
<bpmndi:BPMNDiagram id="BPMNDiagram_1">
<bpmndi:BPMNPlane id="BPMNPlane_1" bpmnElement="HealthCheckBB">
- <bpmndi:BPMNEdge id="Flow_1jeui7e_di" bpmnElement="Flow_1jeui7e">
- <di:waypoint x="600" y="120" />
- <di:waypoint x="680" y="120" />
+ <bpmndi:BPMNEdge id="Flow_0udh4cd_di" bpmnElement="Flow_0udh4cd">
+ <di:waypoint x="218" y="150" />
+ <di:waypoint x="245" y="150" />
</bpmndi:BPMNEdge>
- <bpmndi:BPMNEdge id="Flow_0xiyno7_di" bpmnElement="Flow_0xiyno7">
- <di:waypoint x="780" y="120" />
- <di:waypoint x="842" y="120" />
+ <bpmndi:BPMNEdge id="Flow_0n17e0q_di" bpmnElement="Flow_0n17e0q">
+ <di:waypoint x="780" y="150" />
+ <di:waypoint x="870" y="150" />
+ <di:waypoint x="870" y="202" />
</bpmndi:BPMNEdge>
- <bpmndi:BPMNEdge id="Flow_1aqdd5k_di" bpmnElement="Flow_1aqdd5k">
- <di:waypoint x="400" y="120" />
- <di:waypoint x="500" y="120" />
+ <bpmndi:BPMNEdge id="Flow_131rwms_di" bpmnElement="Flow_131rwms">
+ <di:waypoint x="270" y="175" />
+ <di:waypoint x="270" y="220" />
+ <di:waypoint x="852" y="220" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="264" y="195" width="43" height="14" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNEdge>
+ <bpmndi:BPMNEdge id="Flow_0jxw1lb_di" bpmnElement="Flow_0jxw1lb">
+ <di:waypoint x="295" y="150" />
+ <di:waypoint x="350" y="150" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="299" y="132" width="47" height="14" />
+ </bpmndi:BPMNLabel>
</bpmndi:BPMNEdge>
- <bpmndi:BPMNEdge id="Flow_0gd6hy6_di" bpmnElement="Flow_0gd6hy6">
- <di:waypoint x="218" y="120" />
- <di:waypoint x="300" y="120" />
+ <bpmndi:BPMNEdge id="Flow_0uoe9ga_di" bpmnElement="Flow_0uoe9ga">
+ <di:waypoint x="450" y="150" />
+ <di:waypoint x="500" y="150" />
</bpmndi:BPMNEdge>
- <bpmndi:BPMNShape id="Event_1dklvvk_di" bpmnElement="Event_1dklvvk">
- <dc:Bounds x="842" y="102" width="36" height="36" />
+ <bpmndi:BPMNEdge id="Flow_0t6f6l8_di" bpmnElement="Flow_0t6f6l8">
+ <di:waypoint x="600" y="150" />
+ <di:waypoint x="680" y="150" />
+ </bpmndi:BPMNEdge>
+ <bpmndi:BPMNShape id="Event_0rgusxn_di" bpmnElement="Event_0rgusxn">
+ <dc:Bounds x="182" y="132" width="36" height="36" />
<bpmndi:BPMNLabel>
- <dc:Bounds x="820" y="145" width="85" height="27" />
+ <dc:Bounds x="156" y="175" width="90" height="27" />
</bpmndi:BPMNLabel>
</bpmndi:BPMNShape>
- <bpmndi:BPMNShape id="_BPMNShape_StartEvent_2" bpmnElement="StartEvent_1">
- <dc:Bounds x="182" y="102" width="36" height="36" />
+ <bpmndi:BPMNShape id="Event_0o1nl3y_di" bpmnElement="Event_0o1nl3y">
+ <dc:Bounds x="852" y="202" width="36" height="36" />
<bpmndi:BPMNLabel>
- <dc:Bounds x="156" y="145" width="90" height="27" />
+ <dc:Bounds x="831" y="245" width="84" height="27" />
</bpmndi:BPMNLabel>
</bpmndi:BPMNShape>
- <bpmndi:BPMNShape id="Activity_11hkwkn_di" bpmnElement="Activity_11hkwkn">
- <dc:Bounds x="300" y="80" width="100" height="80" />
+ <bpmndi:BPMNShape id="Activity_0pnb21p_di" bpmnElement="Activity_0pnb21p">
+ <dc:Bounds x="350" y="110" width="100" height="80" />
+ </bpmndi:BPMNShape>
+ <bpmndi:BPMNShape id="Activity_07txikn_di" bpmnElement="Activity_07txikn">
+ <dc:Bounds x="500" y="110" width="100" height="80" />
</bpmndi:BPMNShape>
- <bpmndi:BPMNShape id="Activity_0f7poou_di" bpmnElement="Activity_08mgs1k">
- <dc:Bounds x="500" y="80" width="100" height="80" />
+ <bpmndi:BPMNShape id="Activity_1qd7k3z_di" bpmnElement="Activity_1qd7k3z">
+ <dc:Bounds x="680" y="110" width="100" height="80" />
</bpmndi:BPMNShape>
- <bpmndi:BPMNShape id="Activity_0w4hy3d_di" bpmnElement="Activity_0w4hy3d">
- <dc:Bounds x="680" y="80" width="100" height="80" />
+ <bpmndi:BPMNShape id="Gateway_07e5xls_di" bpmnElement="Gateway_07e5xls" isMarkerVisible="true">
+ <dc:Bounds x="245" y="125" width="50" height="50" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="230" y="95" width="81" height="14" />
+ </bpmndi:BPMNLabel>
</bpmndi:BPMNShape>
- <bpmndi:BPMNShape id="Activity_1pto2qh_di" bpmnElement="Activity_1pto2qh" isExpanded="true">
- <dc:Bounds x="280" y="250" width="460" height="135" />
+ <bpmndi:BPMNShape id="Activity_0tw4ak3_di" bpmnElement="Activity_0tw4ak3" isExpanded="true">
+ <dc:Bounds x="280" y="280" width="460" height="135" />
</bpmndi:BPMNShape>
- <bpmndi:BPMNEdge id="Flow_05rbrsm_di" bpmnElement="Flow_05rbrsm">
- <di:waypoint x="398" y="324" />
- <di:waypoint x="632" y="324" />
+ <bpmndi:BPMNEdge id="Flow_03ogqmx_di" bpmnElement="Flow_03ogqmx">
+ <di:waypoint x="398" y="354" />
+ <di:waypoint x="632" y="354" />
</bpmndi:BPMNEdge>
- <bpmndi:BPMNShape id="Event_0929aqj_di" bpmnElement="Event_0929aqj">
- <dc:Bounds x="362" y="306" width="36" height="36" />
+ <bpmndi:BPMNShape id="Event_1v6jbfd_di" bpmnElement="Event_1v6jbfd">
+ <dc:Bounds x="362" y="336" width="36" height="36" />
</bpmndi:BPMNShape>
- <bpmndi:BPMNShape id="Event_1s698ql_di" bpmnElement="Event_1s698ql">
- <dc:Bounds x="632" y="306" width="36" height="36" />
+ <bpmndi:BPMNShape id="Event_0wwzune_di" bpmnElement="Event_0wwzune">
+ <dc:Bounds x="632" y="336" width="36" height="36" />
</bpmndi:BPMNShape>
</bpmndi:BPMNPlane>
</bpmndi:BPMNDiagram>
--- /dev/null
+<?xml version="1.0" encoding="UTF-8"?>
+<bpmn:definitions xmlns:bpmn="http://www.omg.org/spec/BPMN/20100524/MODEL" xmlns:bpmndi="http://www.omg.org/spec/BPMN/20100524/DI" xmlns:dc="http://www.omg.org/spec/DD/20100524/DC" xmlns:camunda="http://camunda.org/schema/1.0/bpmn" xmlns:di="http://www.omg.org/spec/DD/20100524/DI" xmlns:modeler="http://camunda.org/schema/modeler/1.0" id="Definitions_1jxlg2g" targetNamespace="http://bpmn.io/schema/bpmn" exporter="Camunda Modeler" exporterVersion="3.7.0" modeler:executionPlatform="Camunda Platform" modeler:executionPlatformVersion="7.15.0">
+ <bpmn:process id="UpgradeVfModuleBB" name="UpgradeVfModuleBB" isExecutable="true">
+ <bpmn:startEvent id="UpgradeVfModuleBB_Start">
+ <bpmn:outgoing>SequenceFlow_1xr6chl</bpmn:outgoing>
+ </bpmn:startEvent>
+ <bpmn:serviceTask id="QueryVfModule" name=" SDNC Get (vf module) " camunda:expression="${SDNCQueryTasks.queryVfModule(InjectExecution.execute(execution, execution.getVariable("gBuildingBlockExecution")))}">
+ <bpmn:incoming>SequenceFlow_1s4rpyp</bpmn:incoming>
+ <bpmn:outgoing>Flow_0gbxjjk</bpmn:outgoing>
+ </bpmn:serviceTask>
+ <bpmn:endEvent id="UpgradeVfModuleBB_End">
+ <bpmn:incoming>SequenceFlow_1vbwdaw</bpmn:incoming>
+ </bpmn:endEvent>
+ <bpmn:serviceTask id="QueryVnf" name=" SDNC Get (vnf) " camunda:expression="${SDNCQueryTasks.queryVnf(InjectExecution.execute(execution, execution.getVariable("gBuildingBlockExecution")))}">
+ <bpmn:incoming>SequenceFlow_1xr6chl</bpmn:incoming>
+ <bpmn:outgoing>SequenceFlow_1s4rpyp</bpmn:outgoing>
+ </bpmn:serviceTask>
+ <bpmn:serviceTask id="UpdateVfModuleStatus" name=" AAI Update (vf module) " camunda:expression="${AAIUpdateTasks.updateOrchestrationStatusCreatedVfModule(InjectExecution.execute(execution, execution.getVariable("gBuildingBlockExecution")))}">
+ <bpmn:incoming>SequenceFlow_0rds4rj</bpmn:incoming>
+ <bpmn:outgoing>SequenceFlow_1vbwdaw</bpmn:outgoing>
+ </bpmn:serviceTask>
+ <bpmn:serviceTask id="UpdateVfModuleHeatStackId" name=" AAI Update (vf module) " camunda:expression="${AAIUpdateTasks.updateHeatStackIdVfModule(InjectExecution.execute(execution, execution.getVariable("gBuildingBlockExecution")))}">
+ <bpmn:incoming>SequenceFlow_15do1tu</bpmn:incoming>
+ <bpmn:outgoing>SequenceFlow_0rds4rj</bpmn:outgoing>
+ </bpmn:serviceTask>
+ <bpmn:serviceTask id="CreateNetworkPolicies" name="AAI Create (network policies)" camunda:expression="${AAICreateTasks.createNetworkPolicies(InjectExecution.execute(execution, execution.getVariable("gBuildingBlockExecution")))}">
+ <bpmn:incoming>Flow_1c9ox62</bpmn:incoming>
+ <bpmn:outgoing>SequenceFlow_0xqhep5</bpmn:outgoing>
+ </bpmn:serviceTask>
+ <bpmn:serviceTask id="UpdateVnfIpv4OamAddress" name="AAI Update (VNF) " camunda:expression="${AAIUpdateTasks.updateIpv4OamAddressVnf(InjectExecution.execute(execution, execution.getVariable("gBuildingBlockExecution")))}">
+ <bpmn:incoming>SequenceFlow_0xqhep5</bpmn:incoming>
+ <bpmn:outgoing>SequenceFlow_1yo6mvv</bpmn:outgoing>
+ </bpmn:serviceTask>
+ <bpmn:serviceTask id="UpdateVnfManagementV6Address" name="AAI Update (VNF)" camunda:expression="${AAIUpdateTasks.updateManagementV6AddressVnf(InjectExecution.execute(execution, execution.getVariable("gBuildingBlockExecution")))}">
+ <bpmn:incoming>SequenceFlow_1yo6mvv</bpmn:incoming>
+ <bpmn:outgoing>SequenceFlow_1i03uy2</bpmn:outgoing>
+ </bpmn:serviceTask>
+ <bpmn:serviceTask id="UpdateVfModuleContrailServiceInstanceFqdn" name="AAI Update (vf module) " camunda:expression="${AAIUpdateTasks.updateContrailServiceInstanceFqdnVfModule(InjectExecution.execute(execution, execution.getVariable("gBuildingBlockExecution")))}">
+ <bpmn:incoming>SequenceFlow_1i03uy2</bpmn:incoming>
+ <bpmn:outgoing>SequenceFlow_15do1tu</bpmn:outgoing>
+ </bpmn:serviceTask>
+ <bpmn:serviceTask id="CnfAdapter" name="Cnf Adapter" camunda:expression="${CnfAdapterUpgradeTasks.upgradeInstance(InjectExecution.execute(execution, execution.getVariable("gBuildingBlockExecution")))}">
+ <bpmn:incoming>Flow_0gbxjjk</bpmn:incoming>
+ <bpmn:outgoing>Flow_1il4743</bpmn:outgoing>
+ </bpmn:serviceTask>
+ <bpmn:subProcess id="Activity_10eqhmz" name="Inventory Error Handling" triggeredByEvent="true">
+ <bpmn:endEvent id="Event_108oetk">
+ <bpmn:incoming>Flow_03q6ty9</bpmn:incoming>
+ </bpmn:endEvent>
+ <bpmn:serviceTask id="Activity_1p8hxyt" name="Process Error" camunda:expression="${ExceptionBuilder.processInventoryException(execution)}">
+ <bpmn:incoming>Flow_1sqy91r</bpmn:incoming>
+ <bpmn:outgoing>Flow_03q6ty9</bpmn:outgoing>
+ </bpmn:serviceTask>
+ <bpmn:sequenceFlow id="Flow_03q6ty9" sourceRef="Activity_1p8hxyt" targetRef="Event_108oetk" />
+ <bpmn:sequenceFlow id="Flow_1sqy91r" sourceRef="Event_1pengt4" targetRef="Activity_1p8hxyt" />
+ <bpmn:startEvent id="Event_1pengt4">
+ <bpmn:outgoing>Flow_1sqy91r</bpmn:outgoing>
+ <bpmn:errorEventDefinition id="ErrorEventDefinition_0sq3chy" errorRef="Error_0t7oivz" />
+ </bpmn:startEvent>
+ </bpmn:subProcess>
+ <bpmn:callActivity id="UpdateCnfAai" name="Update Cnf Data in AAI" calledElement="UpdateCnfAai">
+ <bpmn:extensionElements>
+ <camunda:in source="gBuildingBlockExecution" target="gBuildingBlockExecution" />
+ <camunda:out source="WorkflowException" target="WorkflowException" />
+ <camunda:in source="heatStackId" target="heatStackId" />
+ <camunda:out source="heatStackId" target="heatStackId" />
+ </bpmn:extensionElements>
+ <bpmn:incoming>Flow_1il4743</bpmn:incoming>
+ <bpmn:outgoing>Flow_0piytnn</bpmn:outgoing>
+ </bpmn:callActivity>
+ <bpmn:sequenceFlow id="SequenceFlow_1xr6chl" sourceRef="UpgradeVfModuleBB_Start" targetRef="QueryVnf" />
+ <bpmn:sequenceFlow id="SequenceFlow_1s4rpyp" sourceRef="QueryVnf" targetRef="QueryVfModule" />
+ <bpmn:sequenceFlow id="SequenceFlow_1vbwdaw" sourceRef="UpdateVfModuleStatus" targetRef="UpgradeVfModuleBB_End" />
+ <bpmn:sequenceFlow id="SequenceFlow_0rds4rj" sourceRef="UpdateVfModuleHeatStackId" targetRef="UpdateVfModuleStatus" />
+ <bpmn:sequenceFlow id="SequenceFlow_15do1tu" sourceRef="UpdateVfModuleContrailServiceInstanceFqdn" targetRef="UpdateVfModuleHeatStackId" />
+ <bpmn:sequenceFlow id="SequenceFlow_0xqhep5" sourceRef="CreateNetworkPolicies" targetRef="UpdateVnfIpv4OamAddress" />
+ <bpmn:sequenceFlow id="SequenceFlow_1yo6mvv" sourceRef="UpdateVnfIpv4OamAddress" targetRef="UpdateVnfManagementV6Address" />
+ <bpmn:sequenceFlow id="SequenceFlow_1i03uy2" sourceRef="UpdateVnfManagementV6Address" targetRef="UpdateVfModuleContrailServiceInstanceFqdn" />
+ <bpmn:sequenceFlow id="Flow_1il4743" sourceRef="CnfAdapter" targetRef="UpdateCnfAai" />
+ <bpmn:intermediateThrowEvent id="aaiThrow" name="Update AAI">
+ <bpmn:incoming>Flow_0piytnn</bpmn:incoming>
+ <bpmn:linkEventDefinition id="LinkEventDefinition_1c2sbij" name="AAI" />
+ </bpmn:intermediateThrowEvent>
+ <bpmn:sequenceFlow id="Flow_0gbxjjk" sourceRef="QueryVfModule" targetRef="CnfAdapter" />
+ <bpmn:sequenceFlow id="Flow_0piytnn" sourceRef="UpdateCnfAai" targetRef="aaiThrow" />
+ <bpmn:intermediateCatchEvent id="aaiCatch" name="Update AAI">
+ <bpmn:outgoing>Flow_1c9ox62</bpmn:outgoing>
+ <bpmn:linkEventDefinition id="LinkEventDefinition_0dycelb" name="AAI" />
+ </bpmn:intermediateCatchEvent>
+ <bpmn:sequenceFlow id="Flow_1c9ox62" sourceRef="aaiCatch" targetRef="CreateNetworkPolicies" />
+ </bpmn:process>
+ <bpmn:error id="Error_0t7oivz" name="AAIInventoryFailure" errorCode="AAIInventoryFailure" />
+ <bpmndi:BPMNDiagram id="BPMNDiagram_1">
+ <bpmndi:BPMNPlane id="BPMNPlane_1" bpmnElement="UpgradeVfModuleBB">
+ <bpmndi:BPMNEdge id="Flow_1c9ox62_di" bpmnElement="Flow_1c9ox62">
+ <di:waypoint x="208" y="372" />
+ <di:waypoint x="300" y="372" />
+ </bpmndi:BPMNEdge>
+ <bpmndi:BPMNEdge id="Flow_0piytnn_di" bpmnElement="Flow_0piytnn">
+ <di:waypoint x="970" y="120" />
+ <di:waypoint x="1062" y="120" />
+ </bpmndi:BPMNEdge>
+ <bpmndi:BPMNEdge id="Flow_0gbxjjk_di" bpmnElement="Flow_0gbxjjk">
+ <di:waypoint x="570" y="120" />
+ <di:waypoint x="680" y="120" />
+ </bpmndi:BPMNEdge>
+ <bpmndi:BPMNEdge id="Flow_1il4743_di" bpmnElement="Flow_1il4743">
+ <di:waypoint x="780" y="120" />
+ <di:waypoint x="870" y="120" />
+ </bpmndi:BPMNEdge>
+ <bpmndi:BPMNEdge id="SequenceFlow_1i03uy2_di" bpmnElement="SequenceFlow_1i03uy2">
+ <di:waypoint x="722" y="372" />
+ <di:waypoint x="770" y="372" />
+ </bpmndi:BPMNEdge>
+ <bpmndi:BPMNEdge id="SequenceFlow_1yo6mvv_di" bpmnElement="SequenceFlow_1yo6mvv">
+ <di:waypoint x="553" y="372" />
+ <di:waypoint x="622" y="372" />
+ </bpmndi:BPMNEdge>
+ <bpmndi:BPMNEdge id="SequenceFlow_0xqhep5_di" bpmnElement="SequenceFlow_0xqhep5">
+ <di:waypoint x="400" y="372" />
+ <di:waypoint x="453" y="372" />
+ </bpmndi:BPMNEdge>
+ <bpmndi:BPMNEdge id="SequenceFlow_15do1tu_di" bpmnElement="SequenceFlow_15do1tu">
+ <di:waypoint x="870" y="372" />
+ <di:waypoint x="935" y="372" />
+ </bpmndi:BPMNEdge>
+ <bpmndi:BPMNEdge id="SequenceFlow_0rds4rj_di" bpmnElement="SequenceFlow_0rds4rj">
+ <di:waypoint x="1035" y="372" />
+ <di:waypoint x="1100" y="372" />
+ </bpmndi:BPMNEdge>
+ <bpmndi:BPMNEdge id="SequenceFlow_1vbwdaw_di" bpmnElement="SequenceFlow_1vbwdaw">
+ <di:waypoint x="1200" y="372" />
+ <di:waypoint x="1241" y="372" />
+ <di:waypoint x="1241" y="372" />
+ <di:waypoint x="1276" y="372" />
+ </bpmndi:BPMNEdge>
+ <bpmndi:BPMNEdge id="SequenceFlow_1s4rpyp_di" bpmnElement="SequenceFlow_1s4rpyp">
+ <di:waypoint x="389" y="120" />
+ <di:waypoint x="470" y="120" />
+ </bpmndi:BPMNEdge>
+ <bpmndi:BPMNEdge id="SequenceFlow_1xr6chl_di" bpmnElement="SequenceFlow_1xr6chl">
+ <di:waypoint x="188" y="120" />
+ <di:waypoint x="289" y="120" />
+ </bpmndi:BPMNEdge>
+ <bpmndi:BPMNShape id="CreateVfModuleBB_Start_di" bpmnElement="UpgradeVfModuleBB_Start">
+ <dc:Bounds x="152" y="102" width="36" height="36" />
+ </bpmndi:BPMNShape>
+ <bpmndi:BPMNShape id="QueryVfModule_di" bpmnElement="QueryVfModule">
+ <dc:Bounds x="470" y="80" width="100" height="80" />
+ </bpmndi:BPMNShape>
+ <bpmndi:BPMNShape id="CreateVfModuleBB_End_di" bpmnElement="UpgradeVfModuleBB_End">
+ <dc:Bounds x="1276" y="354" width="36" height="36" />
+ </bpmndi:BPMNShape>
+ <bpmndi:BPMNShape id="QueryVnf_di" bpmnElement="QueryVnf">
+ <dc:Bounds x="289" y="80" width="100" height="80" />
+ </bpmndi:BPMNShape>
+ <bpmndi:BPMNShape id="UpdateVfModuleStatus_di" bpmnElement="UpdateVfModuleStatus">
+ <dc:Bounds x="1100" y="332" width="100" height="80" />
+ </bpmndi:BPMNShape>
+ <bpmndi:BPMNShape id="UpdateVfModuleHeatStackId_di" bpmnElement="UpdateVfModuleHeatStackId">
+ <dc:Bounds x="935" y="332" width="100" height="80" />
+ </bpmndi:BPMNShape>
+ <bpmndi:BPMNShape id="CreateNetworkPolicies_di" bpmnElement="CreateNetworkPolicies">
+ <dc:Bounds x="300" y="332" width="100" height="80" />
+ </bpmndi:BPMNShape>
+ <bpmndi:BPMNShape id="UpdateVnfIpv4OamAddress_di" bpmnElement="UpdateVnfIpv4OamAddress">
+ <dc:Bounds x="453" y="332" width="100" height="80" />
+ </bpmndi:BPMNShape>
+ <bpmndi:BPMNShape id="UpdateVnfManagementV6Address_di" bpmnElement="UpdateVnfManagementV6Address">
+ <dc:Bounds x="622" y="332" width="100" height="80" />
+ </bpmndi:BPMNShape>
+ <bpmndi:BPMNShape id="UpdateVfModuleContrailServiceInstanceFqdn_di" bpmnElement="UpdateVfModuleContrailServiceInstanceFqdn">
+ <dc:Bounds x="770" y="332" width="100" height="80" />
+ </bpmndi:BPMNShape>
+ <bpmndi:BPMNShape id="CnfAdapter_di" bpmnElement="CnfAdapter">
+ <dc:Bounds x="680" y="80" width="100" height="80" />
+ </bpmndi:BPMNShape>
+ <bpmndi:BPMNShape id="Activity_10eqhmz_di" bpmnElement="Activity_10eqhmz" isExpanded="true">
+ <dc:Bounds x="216" y="494" width="340" height="180" />
+ </bpmndi:BPMNShape>
+ <bpmndi:BPMNEdge id="Flow_1sqy91r_di" bpmnElement="Flow_1sqy91r">
+ <di:waypoint x="292" y="584" />
+ <di:waypoint x="336" y="584" />
+ </bpmndi:BPMNEdge>
+ <bpmndi:BPMNEdge id="Flow_03q6ty9_di" bpmnElement="Flow_03q6ty9">
+ <di:waypoint x="436" y="584" />
+ <di:waypoint x="488" y="584" />
+ </bpmndi:BPMNEdge>
+ <bpmndi:BPMNShape id="Event_108oetk_di" bpmnElement="Event_108oetk">
+ <dc:Bounds x="488" y="566" width="36" height="36" />
+ </bpmndi:BPMNShape>
+ <bpmndi:BPMNShape id="Activity_1p8hxyt_di" bpmnElement="Activity_1p8hxyt">
+ <dc:Bounds x="336" y="544" width="100" height="80" />
+ </bpmndi:BPMNShape>
+ <bpmndi:BPMNShape id="UpdateCnfAai_di" bpmnElement="UpdateCnfAai">
+ <dc:Bounds x="870" y="80" width="100" height="80" />
+ </bpmndi:BPMNShape>
+ <bpmndi:BPMNShape id="aaiThrow_di" bpmnElement="aaiThrow">
+ <dc:Bounds x="1062" y="102" width="36" height="36" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="1051" y="148" width="57" height="14" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNShape>
+ <bpmndi:BPMNShape id="aaiCatch_di" bpmnElement="aaiCatch">
+ <dc:Bounds x="172" y="354" width="36" height="36" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="162" y="394" width="57" height="14" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNShape>
+ <bpmndi:BPMNShape id="Event_13ssqoq_di" bpmnElement="Event_1pengt4">
+ <dc:Bounds x="256" y="566" width="36" height="36" />
+ </bpmndi:BPMNShape>
+ </bpmndi:BPMNPlane>
+ </bpmndi:BPMNDiagram>
+</bpmn:definitions>
package org.onap.so.bpmn.infrastructure.scripts
+import static org.apache.commons.lang3.StringUtils.isBlank
import com.fasterxml.jackson.databind.ObjectMapper
import com.google.gson.Gson
import com.google.gson.reflect.TypeToken
import org.camunda.bpm.engine.delegate.BpmnError
import org.camunda.bpm.engine.delegate.DelegateExecution
import org.onap.logging.filter.base.ErrorCode
+import javax.ws.rs.NotFoundException
+import org.onap.aai.domain.yang.Relationship
+import org.onap.aai.domain.yang.ServiceInstance
+import org.onap.aaiclient.client.aai.AAIResourcesClient
+import org.onap.aaiclient.client.aai.entities.AAIResultWrapper
+import org.onap.aaiclient.client.aai.entities.uri.AAIResourceUri
+import org.onap.aaiclient.client.aai.entities.uri.AAIUriFactory
+import org.onap.aaiclient.client.generated.fluentbuilders.AAIFluentTypeBuilder
+import org.onap.aaiclient.client.generated.fluentbuilders.AAIFluentTypeBuilder.Types
import org.onap.so.beans.nsmf.*
import org.onap.so.beans.nsmf.oof.SubnetType
import org.onap.so.bpmn.common.scripts.*
actDeActNssi.setNssiId(nssInstance.nssiId)
actDeActNssi.setSnssaiList(Arrays.asList(customerInfo.snssai))
+ String sliceProfileId = getRelatedSliceProfileId(execution, customerInfo.globalSubscriberId, customerInfo.subscriptionServiceType, nssInstance.nssiId, customerInfo.snssai, "slice-profile")
+ actDeActNssi.setSliceProfileId(sliceProfileId)
- nbiRequest.setEsrInfo(esrInfo)
+ nbiRequest.setEsrInfo(esrInfo)
nbiRequest.setServiceInfo(serviceInfo)
nbiRequest.setActDeActNssi(actDeActNssi)
execution.setVariable("nbiRequest", nbiRequest)
logger.debug("***** Exit processDecomposition *****")
}
+ private String getRelatedSliceProfileId(DelegateExecution execution, String globalSubscriberId, String subscriptionServiceType, String instanceId, String snssai, String role) {
+ logger.debug("${Prefix} - Get Related Slice Profile")
+ if( isBlank(role) || isBlank(instanceId)) {
+ exceptionUtil.buildAndThrowWorkflowException(execution, 2500, "Role and instanceId are mandatory")
+ }
+
+ String nssiId;
+ AAIResourcesClient client = getAAIClient()
+ AAIResourceUri uri = AAIUriFactory.createResourceUri(AAIFluentTypeBuilder.business().customer(globalSubscriberId).serviceSubscription(subscriptionServiceType).serviceInstance(instanceId))
+ if (!client.exists(uri)) {
+ exceptionUtil.buildAndThrowWorkflowException(execution, 2500, "Service Instance was not found in aai : ${instanceId}")
+ }
+ AAIResultWrapper wrapper = client.get(uri, NotFoundException.class)
+ Optional<ServiceInstance> si = wrapper.asBean(ServiceInstance.class)
+ if(si.isPresent()) {
+ List<Relationship> relationshipList = si.get().getRelationshipList().getRelationship()
+ for (Relationship relationship : relationshipList) {
+ String relatedTo = relationship.getRelatedTo()
+ if (relatedTo.toLowerCase() == "service-instance") {
+ String relatioshipurl = relationship.getRelatedLink()
+ String serviceInstanceId =
+ relatioshipurl.substring(relatioshipurl.lastIndexOf("/") + 1, relatioshipurl.length())
+ uri = AAIUriFactory.createResourceUri(AAIFluentTypeBuilder.business().customer(globalSubscriberId).serviceSubscription(subscriptionServiceType).serviceInstance(serviceInstanceId))
+ if (!client.exists(uri)) {
+ exceptionUtil.buildAndThrowWorkflowException(execution, 2500,
+ "Service Instance was not found in aai: ${serviceInstanceId} related to ${instanceId}")
+ }
+ AAIResultWrapper wrapper01 = client.get(uri, NotFoundException.class)
+ Optional<ServiceInstance> serviceInstance = wrapper01.asBean(ServiceInstance.class)
+ if (serviceInstance.isPresent()) {
+ ServiceInstance instance = serviceInstance.get()
+ if (role.equalsIgnoreCase(instance.getServiceRole()) && snssai.equalsIgnoreCase(instance.getEnvironmentContext())) {
+ nssiId = instance.getServiceInstanceId()
+ }
+ }
+ }
+ }
+ }
+ return nssiId
+ logger.debug("${Prefix} - Exit Get Related Slice Profile instances")
+ }
+
/**
* send Create Request NSSMF
* @param execution
modifySliceParams.addProperty("snssaiList", snssaiList)
modifySliceParams.addProperty("sliceProfileId", sliceProfileId)
modifySliceParams.addProperty("nsiInfo", nsiInfo)
- modifySliceParams.addProperty("scriptName", scriptName)
execution.setVariable("modifySliceParams", modifySliceParams.toString())
//create operation status in request db
ANServiceInstance.setServiceType(execution.getVariable("sst") as String)
ANServiceInstance.setOrchestrationStatus(serviceStatus)
String serviceInstanceLocationid = jsonUtil.getJsonValue(execution.getVariable("sliceProfile"), "pLMNIdList") as String
- ANServiceInstance.setServiceInstanceLocationId(serviceInstanceLocationid)
+ ANServiceInstance.setServiceInstanceLocationId(jsonUtil.StringArrayToList(serviceInstanceLocationid).get(0))
ANServiceInstance.setServiceRole(serviceRole)
List<String> snssaiList = jsonUtil.StringArrayToList(execution.getVariable("snssaiList") as String)
String snssai = snssaiList.get(0)
- ANServiceInstance.setEnvironmentContext(snssai)
String modelInvariantUuid = execution.getVariable("modelInvariantUuid")
String modelUuid = execution.getVariable("modelUuid") as String
ANServiceInstance.setModelInvariantId(modelInvariantUuid)
ANServiceInstance.setModelVersionId(modelUuid)
+ ANServiceInstance.setEnvironmentContext(execution.getVariable("networkType")) //Network Type
ANServiceInstance.setWorkloadContext("AN")
String serviceFunctionAn = jsonUtil.getJsonValue(execution.getVariable("sliceProfile") as String, "resourceSharingLevel")
ANServiceInstance.setServiceFunction(serviceFunctionAn)
String modelUuid = modelInfo.getModelUuid()
ss.setModelInvariantId(modelInvariantUuid)
ss.setModelVersionId(modelUuid)
- String serviceInstanceLocationid = serviceProfile.get("plmnIdList")
+ String serviceInstanceLocationid = serviceProfile.get("pLMNIdList")
ss.setServiceInstanceLocationId(serviceInstanceLocationid)
String snssai = serviceProfile.get("sNSSAI")
ss.setEnvironmentContext(snssai)
import org.onap.so.bpmn.common.scripts.ExceptionUtil
import org.onap.so.bpmn.common.scripts.RequestDBUtil
import org.onap.so.bpmn.core.json.JsonUtils
+import org.onap.so.bpmn.core.UrnPropertiesReader
+import org.onap.so.bpmn.common.scripts.OofUtils
+import org.onap.so.client.HttpClient
+import org.onap.so.client.HttpClientFactory
+import org.onap.so.client.oof.adapter.beans.payload.OofRequest
+import javax.ws.rs.core.Response
+import org.onap.logging.filter.base.ONAPComponents
import org.onap.so.db.request.beans.ResourceOperationStatus
import org.slf4j.Logger
import org.slf4j.LoggerFactory
JsonUtils jsonUtil = new JsonUtils()
RequestDBUtil requestDBUtil = new RequestDBUtil()
TnNssmfUtils tnNssmfUtils = new TnNssmfUtils()
+ OofUtils oofUtils = new OofUtils()
JsonSlurper jsonSlurper = new JsonSlurper()
ObjectMapper objectMapper = new ObjectMapper()
private static final Logger logger = LoggerFactory.getLogger(DoDeallocateTnNssi.class)
"enableSdnc", "enableSdnc"))) {
tnNssmfUtils.setEnableSdncConfig(execution)
}
+ if (isBlank(additionalPropJsonStr) ||
+ isBlank(tnNssmfUtils.setExecVarFromJsonIfExists(execution,
+ additionalPropJsonStr,
+ "enableOof", "enableOof"))) {
+ tnNssmfUtils.setEnableOofConfig(execution)
+ }
+ String nsiId = jsonUtil.getJsonValue(additionalPropJsonStr, "nsiId")
+ execution.setVariable("nsiId", nsiId)
logger.debug("Finish preProcessRequest")
}
+ void prepareOOFNssiTerminationRequest(DelegateExecution execution) {
+ logger.debug("Start prepareOOFTnNssiTerminationRequest")
+ String requestId = execution.getVariable("msoRequestId")
+ String messageType = "TN_NSSITermination"
+ String timeout = UrnPropertiesReader.getVariable("mso.adapters.oof.timeout", execution);
+ String serviceInstanceId = execution.getVariable("sliceServiceInstanceId")
+
+ String relatedNsiId = execution.getVariable("nsiId")
+
+ String oofRequest = oofUtils.buildTerminateNxiRequest(requestId,serviceInstanceId, "NSSI",messageType,relatedNsiId)
+ execution.setVariable("oofTnNssiPayload", oofRequest)
+ logger.debug("Finish prepareOOFTnNssiTerminationRequest")
+ }
+
+ void performOofNSSITerminationCall(DelegateExecution execution) {
+ boolean terminateTnNSSI = callOofAdapter(execution,execution.getVariable("oofTnNssiPayload"))
+ execution.setVariable("terminateTnNSSI", terminateTnNSSI)
+ }
+
+ /**
+ * @param execution
+ * @param oofRequest - Request payload to be sent to adapter
+ * @return
+ */
+ boolean callOofAdapter(DelegateExecution execution, Object oofRequest) {
+ logger.debug("Start callOofAdapter")
+ String requestId = execution.getVariable("msoRequestId")
+ String oofAdapterEndpoint = UrnPropertiesReader.getVariable("mso.adapters.oof.endpoint", execution)
+ URL requestUrl = new URL(oofAdapterEndpoint)
+ OofRequest oofPayload = new OofRequest()
+ oofPayload.setApiPath("/api/oof/terminate/nxi/v1")
+ oofPayload.setRequestDetails(oofRequest)
+ String requestJson = objectMapper.writeValueAsString(oofPayload)
+ logger.debug("Calling OOF adapter : ${requestUrl} with payload : ${requestJson}")
+ HttpClient httpClient = new HttpClientFactory().newJsonClient(requestUrl, ONAPComponents.EXTERNAL)
+ Response httpResponse = httpClient.post(requestJson)
+ int responseCode = httpResponse.getStatus()
+ logger.debug("OOF sync response code is: " + responseCode)
+ if(responseCode < 200 || responseCode >= 300){
+ logger.debug("OOF request failed with reason : " + httpResponse)
+ exceptionUtil.buildAndThrowWorkflowException(execution, responseCode, "Received a Bad Sync Response from OOF.")
+ }else {
+ Map<String,Object> response = objectMapper.readValue(httpResponse.getEntity(),Map.class)
+ boolean terminateResponse = response.get("terminateResponse")
+ if(!terminateResponse) {
+ logger.debug("Terminate response is false because " + response.get("reason"))
+ }
+ return terminateResponse
+ }
+ }
+
void preprocessSdncDeallocateTnNssiRequest(DelegateExecution execution) {
def method = getClass().getSimpleName() + '.preprocessSdncDeallocateTnNssiRequest(' +
'execution=' + execution.getId() + ')'
requestDBUtil.prepareUpdateResourceOperationStatus(execution, roStatus)
}
}
-
execution.setVariable("enableSdnc", enableSdnc)
}
+ void setEnableOofConfig(DelegateExecution execution) {
+ String enableOof = UrnPropertiesReader.getVariable(
+ "mso.workflow.TnNssmf.enableOOFNetworkConfig")
+ if (isBlank(enableOof)) {
+ logger.debug("mso.workflow.TnNssmf.enableOOFNetworkConfig is undefined, so use default value (true)")
+ enableOof = "true"
+ }
+ logger.debug("setEnableOofConfig: enableOof=" + enableOof)
+
+ execution.setVariable("enableOof", enableOof)
+ }
+
String setExecVarFromJsonIfExists(DelegateExecution execution,
String jsonStr, String jsonKey, String varName) {
return setExecVarFromJsonStr(execution, jsonStr, jsonKey, varName, false)
import org.onap.aaiclient.client.generated.fluentbuilders.AAIFluentTypeBuilder
import org.onap.aaiclient.client.generated.fluentbuilders.AAIFluentTypeBuilder.Types
import org.onap.so.bpmn.common.scripts.MsoGroovyTest
+import org.onap.so.bpmn.common.scripts.OofUtils
import static org.junit.Assert.assertNotNull
+import static org.junit.Assert.assertTrue
import static org.mockito.ArgumentMatchers.eq
import static org.mockito.Mockito.*
obj.deleteServiceInstance(mockExecution)
Mockito.verify(client, times(1)).delete(serviceInstanceUri)
}
+
+ @Test
+ void testPrepareOOFNssiTerminationRequest() {
+ when(mockExecution.getVariable("msoRequestId")).thenReturn("4c614769-f58a-4556-8ad9-dcd903077c82")
+ when(mockExecution.getVariable("sliceServiceInstanceId")).thenReturn("5ad89cf9-0569-4a93-9306-d8324321e2be")
+ when(mockExecution.getVariable("nsiId")).thenReturn("88f65519-9a38-4c4b-8445-9eb4a5a5af56")
+ when(mockExecution.getVariable("mso.adapters.oof.timeout")).thenReturn("")
+ DoDeallocateTnNssi obj = spy(DoDeallocateTnNssi.class)
+ OofUtils oofUtils = spy(OofUtils.class)
+ when(oofUtils.buildTerminateNxiRequest()).thenReturn("""
+ {
+ "apiPath": "/api/oof/terminate/nxi/v1",
+ "requestDetails": "{\"type\":\"NSSI\",\"NxIId\":\"f78c1531-55a7-4dfa-8a12-1e2544c9b248\",\"requestInfo\":{\"transactionId\":\"863fb189-33d8-455f-9d3f-bf3f6a2e4509\",\"requestId\":\"863fb189-33d8-455f-9d3f-bf3f6a2e4509\",\"callbackUrl\":\"http://so-oof-adapter.onap:8090/so/adapters/oof/callback/v1/TN_NSSITermination/863fb189-33d8-455f-9d3f-bf3f6a2e4509\",\"sourceId\":\"SO\",\"timeout\":600,\"addtnlArgs\":{\"serviceInstanceId\":\"fe6f0901-292d-4493-bcad-485793605781\"}}}"
+ }""".replaceAll("\\\\s+", ""))
+ obj.prepareOOFNssiTerminationRequest(mockExecution)
+ Mockito.verify(mockExecution, times(1)).setVariable(eq("oofTnNssiPayload"), captor.capture())
+ String oofTnNssiPayload = captor.getValue()
+ assertNotNull(oofTnNssiPayload)
+ }
+
+ @Test
+ void testPerformOofNSSITerminationCall() {
+ when(mockExecution.getVariable("oofTnNssiPayload")).thenReturn("""
+ {
+ "reason": "",
+ "requestId": "e0a026a9-dd6d-4800-ab27-0fdd8f5f64f5",
+ "requestStatus": "success",
+ "terminateResponse": true,
+ "transactionId": "e0a026a9-dd6d-4800-ab27-0fdd8f5f64f5"
+ }""".replaceAll("\\\\s+", ""))
+ DoDeallocateTnNssi obj = spy(DoDeallocateTnNssi.class)
+ when(obj.callOofAdapter()).thenReturn(true)
+ obj.performOofNSSITerminationCall(mockExecution)
+ Mockito.verify(mockExecution, times(1)).setVariable(eq("terminateTnNSSI"), captor.capture())
+ String terminateTnNSSI = captor.getValue()
+ assertTrue(terminateTnNSSI)
+ }
}
<?xml version="1.0" encoding="UTF-8"?>
-<bpmn:definitions xmlns:bpmn="http://www.omg.org/spec/BPMN/20100524/MODEL" xmlns:bpmndi="http://www.omg.org/spec/BPMN/20100524/DI" xmlns:dc="http://www.omg.org/spec/DD/20100524/DC" xmlns:di="http://www.omg.org/spec/DD/20100524/DI" xmlns:camunda="http://camunda.org/schema/1.0/bpmn" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" id="Definitions_05od9yd" targetNamespace="http://bpmn.io/schema/bpmn" exporter="Camunda Modeler" exporterVersion="4.10.0">
+<bpmn:definitions xmlns:bpmn="http://www.omg.org/spec/BPMN/20100524/MODEL" xmlns:bpmndi="http://www.omg.org/spec/BPMN/20100524/DI" xmlns:dc="http://www.omg.org/spec/DD/20100524/DC" xmlns:di="http://www.omg.org/spec/DD/20100524/DI" xmlns:camunda="http://camunda.org/schema/1.0/bpmn" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" id="Definitions_05od9yd" targetNamespace="http://bpmn.io/schema/bpmn" exporter="Camunda Modeler" exporterVersion="4.9.0">
<bpmn:process id="DoAllocateAccessNSSI" name="DoAllocateAccessNSSI" isExecutable="true">
<bpmn:startEvent id="StartEvent_1" name="Start">
<bpmn:outgoing>Flow_163f3sq</bpmn:outgoing>
nss.getSubnetCapabilities(execution)</bpmn:script>
</bpmn:scriptTask>
<bpmn:scriptTask id="Activity_11vdo22" name="Prepare Resource Operation Status Update" scriptFormat="groovy">
- <bpmn:incoming>Flow_1gxbsoi</bpmn:incoming>
+ <bpmn:incoming>Flow_0833cha</bpmn:incoming>
<bpmn:outgoing>Flow_1xw4abx</bpmn:outgoing>
<bpmn:script>import org.onap.so.bpmn.infrastructure.scripts.*
def nss = new DoAllocateAccessNSSI()
<bpmn:endEvent id="Event_0vh1hs2">
<bpmn:incoming>Flow_0ll5x3u</bpmn:incoming>
</bpmn:endEvent>
- <bpmn:sequenceFlow id="Flow_0833cha" sourceRef="Event_05jtdqp" targetRef="Activity_0vf28ld" />
+ <bpmn:sequenceFlow id="Flow_0833cha" sourceRef="Event_05jtdqp" targetRef="Activity_11vdo22" />
<bpmn:sequenceFlow id="Flow_1xw4abx" sourceRef="Activity_11vdo22" targetRef="Activity_1nfx154" />
<bpmn:sequenceFlow id="Flow_0ll5x3u" sourceRef="Activity_1nfx154" targetRef="Event_0vh1hs2" />
<bpmn:sequenceFlow id="Flow_1x3y2tg" sourceRef="Event_18r5xkz" targetRef="Activity_03dgcg5" />
<bpmn:linkEventDefinition id="LinkEventDefinition_05sogjc" name="OperationStatusUpdate" />
</bpmn:intermediateCatchEvent>
<bpmn:intermediateThrowEvent id="Event_0u9308h" name="Go to start  operation status update">
- <bpmn:incoming>Flow_0bd6dhi</bpmn:incoming>
+ <bpmn:incoming>Flow_06qv0en</bpmn:incoming>
<bpmn:linkEventDefinition id="LinkEventDefinition_1o9trjv" name="OperationStatusUpdate" />
</bpmn:intermediateThrowEvent>
<bpmn:intermediateCatchEvent id="Event_18r5xkz" name="start TN allocate">
</bpmn:scriptTask>
<bpmn:sequenceFlow id="Flow_0ikdlkf" sourceRef="Activity_118je0o" targetRef="Activity_0pa8al6" />
<bpmn:sequenceFlow id="Flow_1exjm0h" sourceRef="Activity_0pa8al6" targetRef="Gateway_1832fz7" />
- <bpmn:sequenceFlow id="Flow_0bd6dhi" sourceRef="Activity_0zn4e4n" targetRef="Event_0u9308h" />
- <bpmn:scriptTask id="Activity_0vf28ld" name="update AAI relationships" scriptFormat="groovy">
- <bpmn:incoming>Flow_0833cha</bpmn:incoming>
- <bpmn:outgoing>Flow_1gxbsoi</bpmn:outgoing>
- <bpmn:script>import org.onap.so.bpmn.infrastructure.scripts.*
-def nss = new DoAllocateAccessNSSI()
-nss.updateAairelationships(execution)</bpmn:script>
- </bpmn:scriptTask>
+ <bpmn:sequenceFlow id="Flow_0bd6dhi" sourceRef="Activity_0zn4e4n" targetRef="Activity_1pjf5mm" />
<bpmn:subProcess id="Activity_0bcs8g1" name="Sub-process for FalloutHandler and Rollback" triggeredByEvent="true">
<bpmn:startEvent id="Event_077lf7i">
<bpmn:outgoing>Flow_18rrdsq</bpmn:outgoing>
</bpmn:callActivity>
<bpmn:sequenceFlow id="Flow_1k3vqxg" sourceRef="Activity_08i0hzk" targetRef="Activity_1aweui4" />
<bpmn:sequenceFlow id="Flow_083bb3k" sourceRef="Gateway_1cmraqs" targetRef="Activity_0fdm3in" />
- <bpmn:sequenceFlow id="Flow_1gxbsoi" sourceRef="Activity_0vf28ld" targetRef="Activity_11vdo22" />
<bpmn:intermediateThrowEvent id="Event_0lx9qhs" name="Goto start RANNF Allocate">
<bpmn:incoming>Flow_0rb4j9r</bpmn:incoming>
<bpmn:linkEventDefinition id="LinkEventDefinition_0s0j5kx" name="startRANNFAllocate" />
<bpmn:sequenceFlow id="Flow_1ryf352" name="No" sourceRef="Gateway_0rm6svp" targetRef="Event_0f7ueve">
<bpmn:conditionExpression xsi:type="bpmn:tFormalExpression">#{(execution.getVariable("IsRANNfAlonePresent" ) == true)}</bpmn:conditionExpression>
</bpmn:sequenceFlow>
+ <bpmn:scriptTask id="Activity_1pjf5mm" name="update AAI relationships" scriptFormat="groovy">
+ <bpmn:incoming>Flow_0bd6dhi</bpmn:incoming>
+ <bpmn:outgoing>Flow_06qv0en</bpmn:outgoing>
+ <bpmn:script>import org.onap.so.bpmn.infrastructure.scripts.*
+def nss = new DoAllocateAccessNSSI()
+nss.updateAairelationships(execution)</bpmn:script>
+ </bpmn:scriptTask>
+ <bpmn:sequenceFlow id="Flow_06qv0en" sourceRef="Activity_1pjf5mm" targetRef="Event_0u9308h" />
</bpmn:process>
<bpmn:message id="Message_1r7nv8u" name="WorkflowMessage" />
<bpmn:error id="Error_047rteq" name="MSO Workflow Exception" errorCode="MSOWorkflowException" />
<bpmndi:BPMNDiagram id="BPMNDiagram_1">
<bpmndi:BPMNPlane id="BPMNPlane_1" bpmnElement="DoAllocateAccessNSSI">
+ <bpmndi:BPMNEdge id="Flow_1ryf352_di" bpmnElement="Flow_1ryf352">
+ <di:waypoint x="1270" y="843" />
+ <di:waypoint x="1270" y="865" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="1278" y="851" width="15" height="14" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNEdge>
+ <bpmndi:BPMNEdge id="Flow_15uux8j_di" bpmnElement="Flow_15uux8j">
+ <di:waypoint x="1295" y="818" />
+ <di:waypoint x="1392" y="818" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="1335" y="800" width="18" height="14" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNEdge>
+ <bpmndi:BPMNEdge id="Flow_1tx240t_di" bpmnElement="Flow_1tx240t">
+ <di:waypoint x="1140" y="818" />
+ <di:waypoint x="1245" y="818" />
+ </bpmndi:BPMNEdge>
<bpmndi:BPMNEdge id="Flow_1f0furp_di" bpmnElement="Flow_1f0furp">
<di:waypoint x="790" y="120" />
<di:waypoint x="875" y="120" />
<dc:Bounds x="970" y="102" width="17" height="14" />
</bpmndi:BPMNLabel>
</bpmndi:BPMNEdge>
+ <bpmndi:BPMNEdge id="Flow_024x74t_di" bpmnElement="Flow_024x74t">
+ <di:waypoint x="1350" y="1042" />
+ <di:waypoint x="1350" y="1100" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="1358" y="1068" width="15" height="14" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNEdge>
+ <bpmndi:BPMNEdge id="Flow_0d40k12_di" bpmnElement="Flow_0d40k12">
+ <di:waypoint x="1375" y="1017" />
+ <di:waypoint x="1452" y="1017" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="1406" y="999" width="18" height="14" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNEdge>
<bpmndi:BPMNEdge id="Flow_1eo3bed_di" bpmnElement="Flow_1eo3bed">
<di:waypoint x="228" y="819" />
<di:waypoint x="300" y="819" />
</bpmndi:BPMNEdge>
- <bpmndi:BPMNEdge id="Flow_1gxbsoi_di" bpmnElement="Flow_1gxbsoi">
- <di:waypoint x="430" y="1440" />
- <di:waypoint x="490" y="1440" />
- </bpmndi:BPMNEdge>
<bpmndi:BPMNEdge id="Flow_083bb3k_di" bpmnElement="Flow_083bb3k">
<di:waypoint x="790" y="554" />
<di:waypoint x="790" y="660" />
</bpmndi:BPMNEdge>
<bpmndi:BPMNEdge id="Flow_0bd6dhi_di" bpmnElement="Flow_0bd6dhi">
<di:waypoint x="1620" y="1260" />
- <di:waypoint x="1722" y="1260" />
+ <di:waypoint x="1690" y="1260" />
+ </bpmndi:BPMNEdge>
+ <bpmndi:BPMNEdge id="Flow_1exjm0h_di" bpmnElement="Flow_1exjm0h">
+ <di:waypoint x="1300" y="1017" />
+ <di:waypoint x="1325" y="1017" />
+ </bpmndi:BPMNEdge>
+ <bpmndi:BPMNEdge id="Flow_0ikdlkf_di" bpmnElement="Flow_0ikdlkf">
+ <di:waypoint x="1170" y="1017" />
+ <di:waypoint x="1200" y="1017" />
</bpmndi:BPMNEdge>
<bpmndi:BPMNEdge id="Flow_0fdetmo_di" bpmnElement="Flow_0fdetmo">
<di:waypoint x="1260" y="1260" />
<di:waypoint x="410" y="1260" />
<di:waypoint x="480" y="1260" />
</bpmndi:BPMNEdge>
+ <bpmndi:BPMNEdge id="Flow_05yqmnj_di" bpmnElement="Flow_05yqmnj">
+ <di:waypoint x="1030" y="1017" />
+ <di:waypoint x="1070" y="1017" />
+ </bpmndi:BPMNEdge>
+ <bpmndi:BPMNEdge id="Flow_1pbiznt_di" bpmnElement="Flow_1pbiznt">
+ <di:waypoint x="880" y="1017" />
+ <di:waypoint x="930" y="1017" />
+ </bpmndi:BPMNEdge>
<bpmndi:BPMNEdge id="Flow_0kn30g3_di" bpmnElement="Flow_0kn30g3">
<di:waypoint x="853" y="818" />
<di:waypoint x="910" y="818" />
<di:waypoint x="310" y="1260" />
</bpmndi:BPMNEdge>
<bpmndi:BPMNEdge id="Flow_0ll5x3u_di" bpmnElement="Flow_0ll5x3u">
- <di:waypoint x="760" y="1440" />
- <di:waypoint x="862" y="1440" />
+ <di:waypoint x="580" y="1440" />
+ <di:waypoint x="672" y="1440" />
</bpmndi:BPMNEdge>
<bpmndi:BPMNEdge id="Flow_1xw4abx_di" bpmnElement="Flow_1xw4abx">
- <di:waypoint x="590" y="1440" />
- <di:waypoint x="660" y="1440" />
+ <di:waypoint x="400" y="1440" />
+ <di:waypoint x="480" y="1440" />
</bpmndi:BPMNEdge>
<bpmndi:BPMNEdge id="Flow_0833cha_di" bpmnElement="Flow_0833cha">
<di:waypoint x="228" y="1440" />
- <di:waypoint x="330" y="1440" />
- </bpmndi:BPMNEdge>
- <bpmndi:BPMNEdge id="Flow_1tx240t_di" bpmnElement="Flow_1tx240t">
- <di:waypoint x="1140" y="818" />
- <di:waypoint x="1245" y="818" />
- </bpmndi:BPMNEdge>
- <bpmndi:BPMNEdge id="Flow_15uux8j_di" bpmnElement="Flow_15uux8j">
- <di:waypoint x="1295" y="818" />
- <di:waypoint x="1392" y="818" />
- <bpmndi:BPMNLabel>
- <dc:Bounds x="1335" y="800" width="18" height="14" />
- </bpmndi:BPMNLabel>
- </bpmndi:BPMNEdge>
- <bpmndi:BPMNEdge id="Flow_0d40k12_di" bpmnElement="Flow_0d40k12">
- <di:waypoint x="1375" y="1017" />
- <di:waypoint x="1452" y="1017" />
- <bpmndi:BPMNLabel>
- <dc:Bounds x="1406" y="999" width="18" height="14" />
- </bpmndi:BPMNLabel>
- </bpmndi:BPMNEdge>
- <bpmndi:BPMNEdge id="Flow_1pbiznt_di" bpmnElement="Flow_1pbiznt">
- <di:waypoint x="880" y="1017" />
- <di:waypoint x="930" y="1017" />
- </bpmndi:BPMNEdge>
- <bpmndi:BPMNEdge id="Flow_05yqmnj_di" bpmnElement="Flow_05yqmnj">
- <di:waypoint x="1030" y="1017" />
- <di:waypoint x="1070" y="1017" />
- </bpmndi:BPMNEdge>
- <bpmndi:BPMNEdge id="Flow_0ikdlkf_di" bpmnElement="Flow_0ikdlkf">
- <di:waypoint x="1170" y="1017" />
- <di:waypoint x="1200" y="1017" />
- </bpmndi:BPMNEdge>
- <bpmndi:BPMNEdge id="Flow_1exjm0h_di" bpmnElement="Flow_1exjm0h">
- <di:waypoint x="1300" y="1017" />
- <di:waypoint x="1325" y="1017" />
+ <di:waypoint x="300" y="1440" />
</bpmndi:BPMNEdge>
- <bpmndi:BPMNEdge id="Flow_024x74t_di" bpmnElement="Flow_024x74t">
- <di:waypoint x="1350" y="1042" />
- <di:waypoint x="1350" y="1100" />
- <bpmndi:BPMNLabel>
- <dc:Bounds x="1358" y="1068" width="15" height="14" />
- </bpmndi:BPMNLabel>
- </bpmndi:BPMNEdge>
- <bpmndi:BPMNEdge id="Flow_1ryf352_di" bpmnElement="Flow_1ryf352">
- <di:waypoint x="1270" y="843" />
- <di:waypoint x="1270" y="865" />
- <bpmndi:BPMNLabel>
- <dc:Bounds x="1278" y="851" width="15" height="14" />
- </bpmndi:BPMNLabel>
+ <bpmndi:BPMNEdge id="Flow_06qv0en_di" bpmnElement="Flow_06qv0en">
+ <di:waypoint x="1790" y="1260" />
+ <di:waypoint x="1852" y="1260" />
</bpmndi:BPMNEdge>
<bpmndi:BPMNShape id="_BPMNShape_StartEvent_2" bpmnElement="StartEvent_1">
<dc:Bounds x="162" y="102" width="36" height="36" />
<bpmndi:BPMNShape id="Activity_1gdi5bo_di" bpmnElement="Activity_0vhvubq">
<dc:Bounds x="1030" y="80" width="100" height="80" />
</bpmndi:BPMNShape>
- <bpmndi:BPMNShape id="Activity_11vdo22_di" bpmnElement="Activity_11vdo22">
- <dc:Bounds x="490" y="1400" width="100" height="80" />
- </bpmndi:BPMNShape>
- <bpmndi:BPMNShape id="Activity_1nfx154_di" bpmnElement="Activity_1nfx154">
- <dc:Bounds x="660" y="1400" width="100" height="80" />
- </bpmndi:BPMNShape>
- <bpmndi:BPMNShape id="Event_0vh1hs2_di" bpmnElement="Event_0vh1hs2">
- <dc:Bounds x="862" y="1422" width="36" height="36" />
- </bpmndi:BPMNShape>
<bpmndi:BPMNShape id="Activity_0icw8wt_di" bpmnElement="Activity_19laorl">
<dc:Bounds x="300" y="779" width="100" height="80" />
</bpmndi:BPMNShape>
<dc:Bounds x="174" y="1465" width="73" height="27" />
</bpmndi:BPMNLabel>
</bpmndi:BPMNShape>
- <bpmndi:BPMNShape id="Event_1ea1h0i_di" bpmnElement="Event_0u9308h">
- <dc:Bounds x="1722" y="1242" width="36" height="36" />
- <bpmndi:BPMNLabel>
- <dc:Bounds x="1700" y="1290" width="79" height="40" />
- </bpmndi:BPMNLabel>
- </bpmndi:BPMNShape>
<bpmndi:BPMNShape id="Event_1fj3anx_di" bpmnElement="Event_18r5xkz">
<dc:Bounds x="192" y="1242" width="36" height="36" />
<bpmndi:BPMNLabel>
<dc:Bounds x="1220" y="397" width="79" height="40" />
</bpmndi:BPMNLabel>
</bpmndi:BPMNShape>
+ <bpmndi:BPMNShape id="Event_15zn4zi_di" bpmnElement="Event_15zn4zi">
+ <dc:Bounds x="1452" y="999" width="36" height="36" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="1438" y="1042" width="67" height="27" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNShape>
<bpmndi:BPMNShape id="Activity_1pxd5wf_di" bpmnElement="Activity_1pxd5wf">
<dc:Bounds x="560" y="780" width="100" height="80" />
</bpmndi:BPMNShape>
<dc:Bounds x="799" y="765" width="62" height="27" />
</bpmndi:BPMNLabel>
</bpmndi:BPMNShape>
+ <bpmndi:BPMNShape id="Activity_0a95zgv_di" bpmnElement="Activity_0a95zgv">
+ <dc:Bounds x="780" y="977" width="100" height="80" />
+ </bpmndi:BPMNShape>
+ <bpmndi:BPMNShape id="Activity_118je0o_di" bpmnElement="Activity_118je0o">
+ <dc:Bounds x="1070" y="977" width="100" height="80" />
+ </bpmndi:BPMNShape>
<bpmndi:BPMNShape id="Event_0qwruv5_di" bpmnElement="Event_0s8t1ji">
<dc:Bounds x="1572" y="102" width="36" height="36" />
<bpmndi:BPMNLabel>
<bpmndi:BPMNShape id="Activity_0y9xgkl_di" bpmnElement="Activity_0y9xgkl">
<dc:Bounds x="430" y="780" width="100" height="80" />
</bpmndi:BPMNShape>
+ <bpmndi:BPMNShape id="Activity_0vbzhej_di" bpmnElement="Activity_0vbzhej">
+ <dc:Bounds x="930" y="977" width="100" height="80" />
+ </bpmndi:BPMNShape>
<bpmndi:BPMNShape id="Activity_0zn4e4n_di" bpmnElement="Activity_0zn4e4n">
<dc:Bounds x="1520" y="1220" width="100" height="80" />
</bpmndi:BPMNShape>
<bpmndi:BPMNShape id="Activity_06hcbu6_di" bpmnElement="Activity_06hcbu6">
<dc:Bounds x="530" y="80" width="100" height="80" />
</bpmndi:BPMNShape>
+ <bpmndi:BPMNShape id="Activity_1xke4xc_di" bpmnElement="Activity_1aweui4">
+ <dc:Bounds x="1040" y="778" width="100" height="80" />
+ </bpmndi:BPMNShape>
<bpmndi:BPMNShape id="Activity_1bjike9_di" bpmnElement="Activity_1bjike9">
<dc:Bounds x="530" y="340" width="100" height="80" />
</bpmndi:BPMNShape>
<bpmndi:BPMNShape id="Activity_0qpy2sg_di" bpmnElement="Activity_0qpy2sg">
<dc:Bounds x="1160" y="1220" width="100" height="80" />
</bpmndi:BPMNShape>
- <bpmndi:BPMNShape id="Activity_1riw9uv_di" bpmnElement="Activity_0vf28ld">
- <dc:Bounds x="330" y="1400" width="100" height="80" />
- </bpmndi:BPMNShape>
- <bpmndi:BPMNShape id="Event_1cqde7p_di" bpmnElement="Event_1cqde7p">
- <dc:Bounds x="1392" y="800" width="36" height="36" />
- <bpmndi:BPMNLabel>
- <dc:Bounds x="1378" y="843" width="67" height="27" />
- </bpmndi:BPMNLabel>
- </bpmndi:BPMNShape>
- <bpmndi:BPMNShape id="Activity_1xke4xc_di" bpmnElement="Activity_1aweui4">
- <dc:Bounds x="1040" y="778" width="100" height="80" />
- </bpmndi:BPMNShape>
- <bpmndi:BPMNShape id="Gateway_0rm6svp_di" bpmnElement="Gateway_0rm6svp" isMarkerVisible="true">
- <dc:Bounds x="1245" y="793" width="50" height="50" />
- <bpmndi:BPMNLabel>
- <dc:Bounds x="1235" y="763" width="73" height="14" />
- </bpmndi:BPMNLabel>
- </bpmndi:BPMNShape>
- <bpmndi:BPMNShape id="Event_15zn4zi_di" bpmnElement="Event_15zn4zi">
- <dc:Bounds x="1452" y="999" width="36" height="36" />
- <bpmndi:BPMNLabel>
- <dc:Bounds x="1438" y="1042" width="67" height="27" />
- </bpmndi:BPMNLabel>
- </bpmndi:BPMNShape>
- <bpmndi:BPMNShape id="Activity_0a95zgv_di" bpmnElement="Activity_0a95zgv">
- <dc:Bounds x="780" y="977" width="100" height="80" />
- </bpmndi:BPMNShape>
- <bpmndi:BPMNShape id="Activity_118je0o_di" bpmnElement="Activity_118je0o">
- <dc:Bounds x="1070" y="977" width="100" height="80" />
- </bpmndi:BPMNShape>
- <bpmndi:BPMNShape id="Activity_0vbzhej_di" bpmnElement="Activity_0vbzhej">
- <dc:Bounds x="930" y="977" width="100" height="80" />
- </bpmndi:BPMNShape>
<bpmndi:BPMNShape id="Activity_0pa8al6_di" bpmnElement="Activity_0pa8al6">
<dc:Bounds x="1200" y="977" width="100" height="80" />
</bpmndi:BPMNShape>
- <bpmndi:BPMNShape id="Gateway_1832fz7_di" bpmnElement="Gateway_1832fz7" isMarkerVisible="true">
- <dc:Bounds x="1325" y="992" width="50" height="50" />
- <bpmndi:BPMNLabel>
- <dc:Bounds x="1313" y="971" width="74" height="14" />
- </bpmndi:BPMNLabel>
+ <bpmndi:BPMNShape id="Activity_1pjf5mm_di" bpmnElement="Activity_1pjf5mm">
+ <dc:Bounds x="1690" y="1220" width="100" height="80" />
</bpmndi:BPMNShape>
- <bpmndi:BPMNShape id="Event_11t655f_di" bpmnElement="Event_11t655f">
- <dc:Bounds x="1332" y="1100" width="36" height="36" />
+ <bpmndi:BPMNShape id="Event_1ea1h0i_di" bpmnElement="Event_0u9308h">
+ <dc:Bounds x="1852" y="1242" width="36" height="36" />
<bpmndi:BPMNLabel>
- <dc:Bounds x="1310" y="1148" width="79" height="40" />
+ <dc:Bounds x="1830" y="1290" width="79" height="40" />
</bpmndi:BPMNLabel>
</bpmndi:BPMNShape>
- <bpmndi:BPMNShape id="Event_0f7ueve_di" bpmnElement="Event_0f7ueve">
- <dc:Bounds x="1252" y="865" width="36" height="36" />
- <bpmndi:BPMNLabel>
- <dc:Bounds x="1230" y="913" width="79" height="40" />
- </bpmndi:BPMNLabel>
+ <bpmndi:BPMNShape id="Activity_11vdo22_di" bpmnElement="Activity_11vdo22">
+ <dc:Bounds x="300" y="1400" width="100" height="80" />
+ </bpmndi:BPMNShape>
+ <bpmndi:BPMNShape id="Activity_1nfx154_di" bpmnElement="Activity_1nfx154">
+ <dc:Bounds x="480" y="1400" width="100" height="80" />
+ </bpmndi:BPMNShape>
+ <bpmndi:BPMNShape id="Event_0vh1hs2_di" bpmnElement="Event_0vh1hs2">
+ <dc:Bounds x="672" y="1422" width="36" height="36" />
</bpmndi:BPMNShape>
<bpmndi:BPMNShape id="Activity_0bcs8g1_di" bpmnElement="Activity_0bcs8g1" isExpanded="true">
<dc:Bounds x="390" y="1530" width="781" height="196" />
<bpmndi:BPMNShape id="Activity_0p0mwue_di" bpmnElement="Activity_0p0mwue">
<dc:Bounds x="680" y="1594" width="100" height="80" />
</bpmndi:BPMNShape>
+ <bpmndi:BPMNShape id="Event_1cqde7p_di" bpmnElement="Event_1cqde7p">
+ <dc:Bounds x="1392" y="800" width="36" height="36" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="1378" y="843" width="67" height="27" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNShape>
<bpmndi:BPMNShape id="Activity_08i0hzk_di" bpmnElement="Activity_08i0hzk">
<dc:Bounds x="910" y="778" width="100" height="80" />
</bpmndi:BPMNShape>
<dc:Bounds x="180" y="844" width="63" height="27" />
</bpmndi:BPMNLabel>
</bpmndi:BPMNShape>
+ <bpmndi:BPMNShape id="Gateway_1832fz7_di" bpmnElement="Gateway_1832fz7" isMarkerVisible="true">
+ <dc:Bounds x="1325" y="992" width="50" height="50" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="1313" y="971" width="74" height="14" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNShape>
+ <bpmndi:BPMNShape id="Event_11t655f_di" bpmnElement="Event_11t655f">
+ <dc:Bounds x="1332" y="1100" width="36" height="36" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="1310" y="1148" width="79" height="40" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNShape>
<bpmndi:BPMNShape id="Gateway_0qnxawk_di" bpmnElement="Gateway_0qnxawk" isMarkerVisible="true">
<dc:Bounds x="875" y="95" width="50" height="50" />
<bpmndi:BPMNLabel>
<dc:Bounds x="860" y="227" width="81" height="27" />
</bpmndi:BPMNLabel>
</bpmndi:BPMNShape>
+ <bpmndi:BPMNShape id="Gateway_0rm6svp_di" bpmnElement="Gateway_0rm6svp" isMarkerVisible="true">
+ <dc:Bounds x="1245" y="793" width="50" height="50" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="1235" y="763" width="73" height="14" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNShape>
+ <bpmndi:BPMNShape id="Event_0f7ueve_di" bpmnElement="Event_0f7ueve">
+ <dc:Bounds x="1252" y="865" width="36" height="36" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="1230" y="913" width="79" height="40" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNShape>
</bpmndi:BPMNPlane>
</bpmndi:BPMNDiagram>
</bpmn:definitions>
<?xml version="1.0" encoding="UTF-8"?>
-<bpmn:definitions xmlns:bpmn="http://www.omg.org/spec/BPMN/20100524/MODEL" xmlns:bpmndi="http://www.omg.org/spec/BPMN/20100524/DI" xmlns:dc="http://www.omg.org/spec/DD/20100524/DC" xmlns:di="http://www.omg.org/spec/DD/20100524/DI" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:camunda="http://camunda.org/schema/1.0/bpmn" id="Definitions_17amn3o" targetNamespace="http://bpmn.io/schema/bpmn" exporter="Camunda Modeler" exporterVersion="4.10.0">
+<bpmn:definitions xmlns:bpmn="http://www.omg.org/spec/BPMN/20100524/MODEL" xmlns:bpmndi="http://www.omg.org/spec/BPMN/20100524/DI" xmlns:dc="http://www.omg.org/spec/DD/20100524/DC" xmlns:di="http://www.omg.org/spec/DD/20100524/DI" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:camunda="http://camunda.org/schema/1.0/bpmn" id="Definitions_17amn3o" targetNamespace="http://bpmn.io/schema/bpmn" exporter="Camunda Modeler" exporterVersion="4.9.0">
<bpmn:process id="DoDeallocateAccessNSSI" name="DoDeallocateAccessNSSI" isExecutable="true">
<bpmn:startEvent id="Event_0seox25" name="Start">
<bpmn:outgoing>Flow_14g5p2j</bpmn:outgoing>
</bpmn:scriptTask>
<bpmn:scriptTask id="Activity_03zg1pp" name="Delete TN Slice profiles" scriptFormat="groovy">
<bpmn:incoming>Flow_12wqmdr</bpmn:incoming>
- <bpmn:outgoing>Flow_15ok12u</bpmn:outgoing>
+ <bpmn:outgoing>Flow_0kuminm</bpmn:outgoing>
<bpmn:script>import org.onap.so.bpmn.infrastructure.scripts.*
def deallocator = new DoDeAllocateAccessNSSI()
deallocator.deleteTNSliceProfileInAAI(execution)</bpmn:script>
</bpmn:scriptTask>
<bpmn:scriptTask id="Activity_1ri9jrn" name="Delete RAN NSSI" scriptFormat="groovy">
- <bpmn:incoming>Flow_183aijy</bpmn:incoming>
+ <bpmn:incoming>Flow_0kuminm</bpmn:incoming>
+ <bpmn:incoming>Flow_0e6ug2u</bpmn:incoming>
<bpmn:outgoing>Flow_1nh3x4j</bpmn:outgoing>
<bpmn:script>import org.onap.so.bpmn.infrastructure.scripts.*
def deallocator = new DoDeAllocateAccessNSSI()
<bpmn:exclusiveGateway id="Gateway_11aiy0x" name="Is TN present?" default="Flow_12wqmdr">
<bpmn:incoming>Flow_0412ven</bpmn:incoming>
<bpmn:outgoing>Flow_12wqmdr</bpmn:outgoing>
- <bpmn:outgoing>Flow_0r8ldai</bpmn:outgoing>
+ <bpmn:outgoing>Flow_0e6ug2u</bpmn:outgoing>
</bpmn:exclusiveGateway>
<bpmn:sequenceFlow id="Flow_12wqmdr" name="Yes" sourceRef="Gateway_11aiy0x" targetRef="Activity_03zg1pp" />
- <bpmn:sequenceFlow id="Flow_0r8ldai" name="No" sourceRef="Gateway_11aiy0x" targetRef="Gateway_187nc60">
+ <bpmn:sequenceFlow id="Flow_0kuminm" sourceRef="Activity_03zg1pp" targetRef="Activity_1ri9jrn" />
+ <bpmn:sequenceFlow id="Flow_0e6ug2u" sourceRef="Gateway_11aiy0x" targetRef="Activity_1ri9jrn">
<bpmn:conditionExpression xsi:type="bpmn:tFormalExpression">#{(execution.getVariable("IsRANNfAlonePresent" ) == true)}</bpmn:conditionExpression>
</bpmn:sequenceFlow>
- <bpmn:sequenceFlow id="Flow_183aijy" sourceRef="Gateway_187nc60" targetRef="Activity_1ri9jrn" />
- <bpmn:parallelGateway id="Gateway_187nc60">
- <bpmn:incoming>Flow_0r8ldai</bpmn:incoming>
- <bpmn:incoming>Flow_15ok12u</bpmn:incoming>
- <bpmn:outgoing>Flow_183aijy</bpmn:outgoing>
- </bpmn:parallelGateway>
- <bpmn:sequenceFlow id="Flow_15ok12u" sourceRef="Activity_03zg1pp" targetRef="Gateway_187nc60" />
</bpmn:process>
<bpmn:error id="Error_0i5gql0" name="DeallocateWorkflowError" errorCode="2500" />
<bpmndi:BPMNDiagram id="BPMNDiagram_1">
<bpmndi:BPMNPlane id="BPMNPlane_1" bpmnElement="DoDeallocateAccessNSSI">
+ <bpmndi:BPMNEdge id="Flow_12wqmdr_di" bpmnElement="Flow_12wqmdr">
+ <di:waypoint x="460" y="1135" />
+ <di:waypoint x="460" y="1260" />
+ <di:waypoint x="570" y="1260" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="466" y="1199" width="18" height="14" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNEdge>
+ <bpmndi:BPMNEdge id="Flow_1scubfn_di" bpmnElement="Flow_1scubfn">
+ <di:waypoint x="2460" y="435" />
+ <di:waypoint x="2460" y="482" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="2468" y="456" width="15" height="14" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNEdge>
+ <bpmndi:BPMNEdge id="Flow_01ssl7f_di" bpmnElement="Flow_01ssl7f">
+ <di:waypoint x="2485" y="410" />
+ <di:waypoint x="2552" y="410" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="2510" y="392" width="18" height="14" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNEdge>
+ <bpmndi:BPMNEdge id="Flow_1yewqtt_di" bpmnElement="Flow_1yewqtt">
+ <di:waypoint x="2260" y="265" />
+ <di:waypoint x="2260" y="282" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="2268" y="271" width="15" height="14" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNEdge>
+ <bpmndi:BPMNEdge id="Flow_0b3qqvw_di" bpmnElement="Flow_0b3qqvw">
+ <di:waypoint x="2285" y="240" />
+ <di:waypoint x="2362" y="240" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="2315" y="222" width="18" height="14" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNEdge>
<bpmndi:BPMNEdge id="Flow_0x71rer_di" bpmnElement="Flow_0x71rer">
<di:waypoint x="1275" y="650" />
<di:waypoint x="1320" y="650" />
<di:waypoint x="238" y="410" />
<di:waypoint x="290" y="410" />
</bpmndi:BPMNEdge>
- <bpmndi:BPMNEdge id="Flow_0b3qqvw_di" bpmnElement="Flow_0b3qqvw">
- <di:waypoint x="2285" y="240" />
- <di:waypoint x="2362" y="240" />
- <bpmndi:BPMNLabel>
- <dc:Bounds x="2315" y="222" width="18" height="14" />
- </bpmndi:BPMNLabel>
- </bpmndi:BPMNEdge>
- <bpmndi:BPMNEdge id="Flow_1yewqtt_di" bpmnElement="Flow_1yewqtt">
- <di:waypoint x="2260" y="265" />
- <di:waypoint x="2260" y="282" />
- <bpmndi:BPMNLabel>
- <dc:Bounds x="2268" y="271" width="15" height="14" />
- </bpmndi:BPMNLabel>
- </bpmndi:BPMNEdge>
- <bpmndi:BPMNEdge id="Flow_01ssl7f_di" bpmnElement="Flow_01ssl7f">
- <di:waypoint x="2485" y="410" />
- <di:waypoint x="2552" y="410" />
- <bpmndi:BPMNLabel>
- <dc:Bounds x="2510" y="392" width="18" height="14" />
- </bpmndi:BPMNLabel>
- </bpmndi:BPMNEdge>
- <bpmndi:BPMNEdge id="Flow_1scubfn_di" bpmnElement="Flow_1scubfn">
- <di:waypoint x="2460" y="435" />
- <di:waypoint x="2460" y="482" />
- <bpmndi:BPMNLabel>
- <dc:Bounds x="2468" y="456" width="15" height="14" />
- </bpmndi:BPMNLabel>
- </bpmndi:BPMNEdge>
- <bpmndi:BPMNEdge id="Flow_12wqmdr_di" bpmnElement="Flow_12wqmdr">
- <di:waypoint x="460" y="1135" />
- <di:waypoint x="460" y="1260" />
- <di:waypoint x="520" y="1260" />
- <bpmndi:BPMNLabel>
- <dc:Bounds x="466" y="1199" width="18" height="14" />
- </bpmndi:BPMNLabel>
+ <bpmndi:BPMNEdge id="Flow_0kuminm_di" bpmnElement="Flow_0kuminm">
+ <di:waypoint x="670" y="1260" />
+ <di:waypoint x="790" y="1260" />
+ <di:waypoint x="790" y="1150" />
</bpmndi:BPMNEdge>
- <bpmndi:BPMNEdge id="Flow_0r8ldai_di" bpmnElement="Flow_0r8ldai">
+ <bpmndi:BPMNEdge id="Flow_0e6ug2u_di" bpmnElement="Flow_0e6ug2u">
<di:waypoint x="485" y="1110" />
- <di:waypoint x="655" y="1110" />
- <bpmndi:BPMNLabel>
- <dc:Bounds x="589" y="1092" width="15" height="14" />
- </bpmndi:BPMNLabel>
- </bpmndi:BPMNEdge>
- <bpmndi:BPMNEdge id="Flow_183aijy_di" bpmnElement="Flow_183aijy">
- <di:waypoint x="705" y="1110" />
<di:waypoint x="740" y="1110" />
</bpmndi:BPMNEdge>
- <bpmndi:BPMNEdge id="Flow_15ok12u_di" bpmnElement="Flow_15ok12u">
- <di:waypoint x="620" y="1260" />
- <di:waypoint x="680" y="1260" />
- <di:waypoint x="680" y="1135" />
- </bpmndi:BPMNEdge>
<bpmndi:BPMNShape id="Event_0seox25_di" bpmnElement="Event_0seox25">
<dc:Bounds x="202" y="392" width="36" height="36" />
<bpmndi:BPMNLabel>
<bpmndi:BPMNShape id="Gateway_1ypyzn3_di" bpmnElement="Gateway_1ypyzn3" isMarkerVisible="true">
<dc:Bounds x="1265" y="385" width="50" height="50" />
</bpmndi:BPMNShape>
+ <bpmndi:BPMNShape id="Event_1dvx4n9_di" bpmnElement="Event_0vthuwp">
+ <dc:Bounds x="2552" y="392" width="36" height="36" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="2530" y="438" width="81" height="27" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNShape>
<bpmndi:BPMNShape id="Event_1ekryu8_di" bpmnElement="Event_0opsm2p">
<dc:Bounds x="202" y="862" width="36" height="36" />
<bpmndi:BPMNLabel>
<bpmndi:BPMNShape id="Activity_1h4jup8_di" bpmnElement="Activity_0gzrekf">
<dc:Bounds x="1100" y="370" width="100" height="80" />
</bpmndi:BPMNShape>
+ <bpmndi:BPMNShape id="Event_18fpd51_di" bpmnElement="Event_18fpd51">
+ <dc:Bounds x="2362" y="222" width="36" height="36" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="2340" y="268" width="81" height="27" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNShape>
<bpmndi:BPMNShape id="Activity_0m43umg_di" bpmnElement="Activity_1v1ra2k">
<dc:Bounds x="2280" y="370" width="100" height="80" />
</bpmndi:BPMNShape>
<bpmndi:BPMNShape id="Activity_1i9b3oi_di" bpmnElement="Activity_114fx71">
<dc:Bounds x="1330" y="840" width="100" height="80" />
</bpmndi:BPMNShape>
- <bpmndi:BPMNShape id="Event_18fpd51_di" bpmnElement="Event_18fpd51">
- <dc:Bounds x="2362" y="222" width="36" height="36" />
- <bpmndi:BPMNLabel>
- <dc:Bounds x="2340" y="268" width="81" height="27" />
- </bpmndi:BPMNLabel>
- </bpmndi:BPMNShape>
- <bpmndi:BPMNShape id="Event_1dvx4n9_di" bpmnElement="Event_0vthuwp">
- <dc:Bounds x="2552" y="392" width="36" height="36" />
- <bpmndi:BPMNLabel>
- <dc:Bounds x="2530" y="438" width="81" height="27" />
- </bpmndi:BPMNLabel>
- </bpmndi:BPMNShape>
- <bpmndi:BPMNShape id="Gateway_0jjou51_di" bpmnElement="Gateway_0jjou51" isMarkerVisible="true">
- <dc:Bounds x="2235" y="215" width="50" height="50" />
- <bpmndi:BPMNLabel>
- <dc:Bounds x="2224" y="185" width="73" height="14" />
- </bpmndi:BPMNLabel>
- </bpmndi:BPMNShape>
- <bpmndi:BPMNShape id="Event_05q1nj2_di" bpmnElement="Event_05q1nj2">
- <dc:Bounds x="2242" y="282" width="36" height="36" />
- <bpmndi:BPMNLabel>
- <dc:Bounds x="2218" y="328" width="90" height="14" />
- </bpmndi:BPMNLabel>
- </bpmndi:BPMNShape>
- <bpmndi:BPMNShape id="Gateway_0qsknv5_di" bpmnElement="Gateway_0qsknv5" isMarkerVisible="true">
- <dc:Bounds x="2435" y="385" width="50" height="50" />
- <bpmndi:BPMNLabel>
- <dc:Bounds x="2423" y="361" width="73" height="14" />
- </bpmndi:BPMNLabel>
- </bpmndi:BPMNShape>
- <bpmndi:BPMNShape id="Event_0y39bzp_di" bpmnElement="Event_0y39bzp">
- <dc:Bounds x="2442" y="482" width="36" height="36" />
- <bpmndi:BPMNLabel>
- <dc:Bounds x="2418" y="528" width="90" height="14" />
- </bpmndi:BPMNLabel>
- </bpmndi:BPMNShape>
- <bpmndi:BPMNShape id="Activity_0r4899a_di" bpmnElement="Activity_0qho4pw">
- <dc:Bounds x="290" y="1070" width="100" height="80" />
- </bpmndi:BPMNShape>
- <bpmndi:BPMNShape id="Gateway_11aiy0x_di" bpmnElement="Gateway_11aiy0x" isMarkerVisible="true">
- <dc:Bounds x="435" y="1085" width="50" height="50" />
- <bpmndi:BPMNLabel>
- <dc:Bounds x="424" y="1055" width="73" height="14" />
- </bpmndi:BPMNLabel>
- </bpmndi:BPMNShape>
<bpmndi:BPMNShape id="Activity_0b0pl0x_di" bpmnElement="Activity_03zg1pp">
- <dc:Bounds x="520" y="1220" width="100" height="80" />
- </bpmndi:BPMNShape>
- <bpmndi:BPMNShape id="Activity_0dreslj_di" bpmnElement="Activity_1ri9jrn">
- <dc:Bounds x="740" y="1070" width="100" height="80" />
- </bpmndi:BPMNShape>
- <bpmndi:BPMNShape id="Gateway_10923hr_di" bpmnElement="Gateway_187nc60">
- <dc:Bounds x="655" y="1085" width="50" height="50" />
+ <dc:Bounds x="570" y="1220" width="100" height="80" />
</bpmndi:BPMNShape>
<bpmndi:BPMNShape id="Activity_0qbd3cz_di" bpmnElement="Activity_0qbd3cz" isExpanded="true">
<dc:Bounds x="820" y="1310" width="770" height="170" />
<dc:Bounds x="189" y="1135" width="62" height="14" />
</bpmndi:BPMNLabel>
</bpmndi:BPMNShape>
+ <bpmndi:BPMNShape id="Activity_0r4899a_di" bpmnElement="Activity_0qho4pw">
+ <dc:Bounds x="290" y="1070" width="100" height="80" />
+ </bpmndi:BPMNShape>
+ <bpmndi:BPMNShape id="Activity_0dreslj_di" bpmnElement="Activity_1ri9jrn">
+ <dc:Bounds x="740" y="1070" width="100" height="80" />
+ </bpmndi:BPMNShape>
<bpmndi:BPMNShape id="Activity_01s2lve_di" bpmnElement="Activity_0umktii">
<dc:Bounds x="1400" y="200" width="100" height="80" />
</bpmndi:BPMNShape>
<bpmndi:BPMNShape id="Event_1m6hsxq_di" bpmnElement="Event_161u9s2">
<dc:Bounds x="1822" y="82" width="36" height="36" />
</bpmndi:BPMNShape>
+ <bpmndi:BPMNShape id="Gateway_0jjou51_di" bpmnElement="Gateway_0jjou51" isMarkerVisible="true">
+ <dc:Bounds x="2235" y="215" width="50" height="50" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="2224" y="185" width="73" height="14" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNShape>
+ <bpmndi:BPMNShape id="Event_05q1nj2_di" bpmnElement="Event_05q1nj2">
+ <dc:Bounds x="2242" y="282" width="36" height="36" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="2218" y="328" width="90" height="14" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNShape>
+ <bpmndi:BPMNShape id="Gateway_0qsknv5_di" bpmnElement="Gateway_0qsknv5" isMarkerVisible="true">
+ <dc:Bounds x="2435" y="385" width="50" height="50" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="2423" y="361" width="73" height="14" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNShape>
+ <bpmndi:BPMNShape id="Event_0y39bzp_di" bpmnElement="Event_0y39bzp">
+ <dc:Bounds x="2442" y="482" width="36" height="36" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="2418" y="528" width="90" height="14" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNShape>
+ <bpmndi:BPMNShape id="Gateway_11aiy0x_di" bpmnElement="Gateway_11aiy0x" isMarkerVisible="true">
+ <dc:Bounds x="435" y="1085" width="50" height="50" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="423.5" y="1061" width="73" height="14" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNShape>
</bpmndi:BPMNPlane>
</bpmndi:BPMNDiagram>
</bpmn:definitions>
<?xml version="1.0" encoding="UTF-8"?>
-<bpmn:definitions xmlns:bpmn="http://www.omg.org/spec/BPMN/20100524/MODEL" xmlns:bpmndi="http://www.omg.org/spec/BPMN/20100524/DI" xmlns:dc="http://www.omg.org/spec/DD/20100524/DC" xmlns:camunda="http://camunda.org/schema/1.0/bpmn" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:di="http://www.omg.org/spec/DD/20100524/DI" id="Definitions_1wio50w" targetNamespace="http://bpmn.io/schema/bpmn" exporter="Camunda Modeler" exporterVersion="4.1.1">
+<bpmn:definitions xmlns:bpmn="http://www.omg.org/spec/BPMN/20100524/MODEL" xmlns:bpmndi="http://www.omg.org/spec/BPMN/20100524/DI" xmlns:dc="http://www.omg.org/spec/DD/20100524/DC" xmlns:camunda="http://camunda.org/schema/1.0/bpmn" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:di="http://www.omg.org/spec/DD/20100524/DI" id="Definitions_1wio50w" targetNamespace="http://bpmn.io/schema/bpmn" exporter="Camunda Modeler" exporterVersion="4.9.0">
<bpmn:process id="DoDeallocateTransportNSSI" name="DoDeallocateTransportNSSI" isExecutable="true">
<bpmn:startEvent id="StartEvent_1nbljfd" name="Create Deallocate TN NSSMF Work Flow">
<bpmn:outgoing>SequenceFlow_03s744c</bpmn:outgoing>
<bpmn:incoming>Flow_0ca4l8d</bpmn:incoming>
</bpmn:endEvent>
<bpmn:scriptTask id="ScriptTask_1ssh2l9" name="Prepare Update Resource Oper Status((finish)" scriptFormat="groovy">
- <bpmn:incoming>SequenceFlow_1jygjln</bpmn:incoming>
+ <bpmn:incoming>Flow_14tkuoh</bpmn:incoming>
<bpmn:outgoing>SequenceFlow_1qv8qw1</bpmn:outgoing>
<bpmn:script>import org.onap.so.bpmn.infrastructure.scripts.*
def runScript = new DoDeallocateTnNssi()
<bpmn:scriptTask id="Activity_013rjwc" name="Delete Service Instance (TN NSSI) in AAI" scriptFormat="groovy">
<bpmn:incoming>SequenceFlow_1jdb2oq</bpmn:incoming>
<bpmn:incoming>Flow_0dirb5b</bpmn:incoming>
- <bpmn:outgoing>SequenceFlow_1jygjln</bpmn:outgoing>
+ <bpmn:outgoing>Flow_14pzrs9</bpmn:outgoing>
<bpmn:script>import org.onap.so.bpmn.infrastructure.scripts.*
def runScript = new DoDeallocateTnNssi()
runScript.deleteServiceInstance(execution)</bpmn:script>
<bpmn:sequenceFlow id="SequenceFlow_1jdb2oq" sourceRef="Activity_0phv8e5" targetRef="Activity_013rjwc" />
<bpmn:scriptTask id="ScriptTask_1tc44ge" name="PreProcess Incoming Request" scriptFormat="groovy">
<bpmn:incoming>SequenceFlow_03s744c</bpmn:incoming>
- <bpmn:outgoing>SequenceFlow_07e12rt</bpmn:outgoing>
+ <bpmn:outgoing>Flow_1xxj5g6</bpmn:outgoing>
<bpmn:script>import org.onap.so.bpmn.infrastructure.scripts.*
def runScript = new DoDeallocateTnNssi()
runScript.preProcessRequest(execution)</bpmn:script>
</bpmn:scriptTask>
- <bpmn:sequenceFlow id="SequenceFlow_07e12rt" sourceRef="ScriptTask_1tc44ge" targetRef="Gateway_1spi9lo" />
- <bpmn:sequenceFlow id="SequenceFlow_1jygjln" sourceRef="Activity_013rjwc" targetRef="ScriptTask_1ssh2l9" />
<bpmn:serviceTask id="Activity_0rgeefb" name="Update Resource Operation Status">
<bpmn:extensionElements>
<camunda:connector>
</bpmn:serviceTask>
<bpmn:sequenceFlow id="Flow_0ca4l8d" sourceRef="Activity_0rgeefb" targetRef="EndEvent_05h01gx" />
<bpmn:exclusiveGateway id="Gateway_1spi9lo" name="Enable SDNC?">
- <bpmn:incoming>SequenceFlow_07e12rt</bpmn:incoming>
+ <bpmn:incoming>Flow_08so17j</bpmn:incoming>
<bpmn:outgoing>Flow_0sj0mtu</bpmn:outgoing>
<bpmn:outgoing>Flow_0dirb5b</bpmn:outgoing>
</bpmn:exclusiveGateway>
<bpmn:conditionExpression xsi:type="bpmn:tFormalExpression">#{(execution.getVariable("enableSdnc" ) == true)}</bpmn:conditionExpression>
</bpmn:sequenceFlow>
<bpmn:sequenceFlow id="Flow_0dirb5b" name="No" sourceRef="Gateway_1spi9lo" targetRef="Activity_013rjwc" />
+ <bpmn:exclusiveGateway id="Gateway_0evcwr8" name="Enable OOF?" default="Flow_0buil9w">
+ <bpmn:incoming>Flow_1xxj5g6</bpmn:incoming>
+ <bpmn:outgoing>Flow_0elnhnt</bpmn:outgoing>
+ <bpmn:outgoing>Flow_0buil9w</bpmn:outgoing>
+ </bpmn:exclusiveGateway>
+ <bpmn:exclusiveGateway id="Gateway_0m3yrzp" name="Terminate Tn NSSI?" default="Flow_1oxjcb2">
+ <bpmn:incoming>Flow_18xmkvl</bpmn:incoming>
+ <bpmn:outgoing>Flow_1oxjcb2</bpmn:outgoing>
+ <bpmn:outgoing>Flow_083usqs</bpmn:outgoing>
+ </bpmn:exclusiveGateway>
+ <bpmn:sequenceFlow id="Flow_1xxj5g6" sourceRef="ScriptTask_1tc44ge" targetRef="Gateway_0evcwr8" />
+ <bpmn:scriptTask id="Activity_0tw406b" name="Prepare OOF Terminate TN NSSI" scriptFormat="groovy">
+ <bpmn:incoming>Flow_0elnhnt</bpmn:incoming>
+ <bpmn:outgoing>Flow_1yadxwl</bpmn:outgoing>
+ <bpmn:script>import org.onap.so.bpmn.infrastructure.scripts.*
+def deallocator = new DoDeallocateTnNssi()
+deallocator.prepareOOFNssiTerminationRequest(execution)</bpmn:script>
+ </bpmn:scriptTask>
+ <bpmn:scriptTask id="Activity_0ztykbe" name="Call OOF flow for TN termination" scriptFormat="groovy">
+ <bpmn:incoming>Flow_1yadxwl</bpmn:incoming>
+ <bpmn:outgoing>Flow_18xmkvl</bpmn:outgoing>
+ <bpmn:script>import org.onap.so.bpmn.infrastructure.scripts.*
+def deallocator = new DoDeallocateTnNssi()
+deallocator.performOofNSSITerminationCall(execution)</bpmn:script>
+ </bpmn:scriptTask>
+ <bpmn:sequenceFlow id="Flow_0elnhnt" name="Yes" sourceRef="Gateway_0evcwr8" targetRef="Activity_0tw406b">
+ <bpmn:conditionExpression xsi:type="bpmn:tFormalExpression">#{execution.getVariable("enableOof") == true}</bpmn:conditionExpression>
+ </bpmn:sequenceFlow>
+ <bpmn:sequenceFlow id="Flow_1yadxwl" sourceRef="Activity_0tw406b" targetRef="Activity_0ztykbe" />
+ <bpmn:intermediateCatchEvent id="Event_0ypmuow" name="Start operation status update">
+ <bpmn:outgoing>Flow_14tkuoh</bpmn:outgoing>
+ <bpmn:linkEventDefinition id="LinkEventDefinition_0sxzf9o" name="OperationStatusUpdate" />
+ </bpmn:intermediateCatchEvent>
+ <bpmn:sequenceFlow id="Flow_14tkuoh" sourceRef="Event_0ypmuow" targetRef="ScriptTask_1ssh2l9" />
+ <bpmn:intermediateThrowEvent id="Event_0c3sko9" name="Go to start  operation status update">
+ <bpmn:incoming>Flow_14pzrs9</bpmn:incoming>
+ <bpmn:linkEventDefinition id="LinkEventDefinition_1qixrye" name="OperationStatusUpdate" />
+ </bpmn:intermediateThrowEvent>
+ <bpmn:sequenceFlow id="Flow_14pzrs9" sourceRef="Activity_013rjwc" targetRef="Event_0c3sko9" />
+ <bpmn:intermediateThrowEvent id="Event_0l28lqi" name="Go to start  operation status update">
+ <bpmn:incoming>Flow_1oxjcb2</bpmn:incoming>
+ <bpmn:linkEventDefinition id="LinkEventDefinition_0rexbo3" name="OperationStatusUpdate" />
+ </bpmn:intermediateThrowEvent>
+ <bpmn:sequenceFlow id="Flow_18xmkvl" sourceRef="Activity_0ztykbe" targetRef="Gateway_0m3yrzp" />
+ <bpmn:sequenceFlow id="Flow_1oxjcb2" name="No" sourceRef="Gateway_0m3yrzp" targetRef="Event_0l28lqi" />
+ <bpmn:intermediateThrowEvent id="Event_01bin3l" name="Go to deallocate TN nssi">
+ <bpmn:incoming>Flow_083usqs</bpmn:incoming>
+ <bpmn:linkEventDefinition id="LinkEventDefinition_1tnxmki" name="DeAllocateTnNSSI" />
+ </bpmn:intermediateThrowEvent>
+ <bpmn:sequenceFlow id="Flow_083usqs" name="Yes" sourceRef="Gateway_0m3yrzp" targetRef="Event_01bin3l">
+ <bpmn:conditionExpression xsi:type="bpmn:tFormalExpression">#{execution.getVariable("terminateTnNSSI") == true}</bpmn:conditionExpression>
+ </bpmn:sequenceFlow>
+ <bpmn:intermediateCatchEvent id="Event_0a5fzwt" name="Start deallocate TN nssi">
+ <bpmn:outgoing>Flow_08so17j</bpmn:outgoing>
+ <bpmn:linkEventDefinition id="LinkEventDefinition_11dpw4b" name="DeAllocateTnNSSI" />
+ </bpmn:intermediateCatchEvent>
+ <bpmn:sequenceFlow id="Flow_08so17j" sourceRef="Event_0a5fzwt" targetRef="Gateway_1spi9lo" />
+ <bpmn:intermediateThrowEvent id="Event_06m6kud" name="Go to deallocate TN nssi">
+ <bpmn:incoming>Flow_0buil9w</bpmn:incoming>
+ <bpmn:linkEventDefinition id="LinkEventDefinition_02jveqm" name="DeAllocateTnNSSI" />
+ </bpmn:intermediateThrowEvent>
+ <bpmn:sequenceFlow id="Flow_0buil9w" name="No" sourceRef="Gateway_0evcwr8" targetRef="Event_06m6kud" />
</bpmn:process>
<bpmn:message id="Message_0c4b2r5" name="SliceServiceTask" />
<bpmn:error id="Error_03akl5v" name="MSOWorkflowException" errorCode="MSOWorkflowException" />
<bpmn:error id="Error_0p2naox" name="MSOWorkflowException" errorCode="MSOWorkflowException" />
<bpmndi:BPMNDiagram id="BPMNDiagram_1">
<bpmndi:BPMNPlane id="BPMNPlane_1" bpmnElement="DoDeallocateTransportNSSI">
- <bpmndi:BPMNEdge id="Flow_0ca4l8d_di" bpmnElement="Flow_0ca4l8d">
- <di:waypoint x="1030" y="410" />
- <di:waypoint x="1152" y="410" />
+ <bpmndi:BPMNEdge id="Flow_0dirb5b_di" bpmnElement="Flow_0dirb5b">
+ <di:waypoint x="350" y="496" />
+ <di:waypoint x="350" y="680" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="353" y="511" width="15" height="14" />
+ </bpmndi:BPMNLabel>
</bpmndi:BPMNEdge>
- <bpmndi:BPMNEdge id="Flow_1jygjln_di" bpmnElement="SequenceFlow_1jygjln">
- <di:waypoint x="530" y="410" />
- <di:waypoint x="660" y="410" />
+ <bpmndi:BPMNEdge id="Flow_0sj0mtu_di" bpmnElement="Flow_0sj0mtu">
+ <di:waypoint x="375" y="471" />
+ <di:waypoint x="439" y="471" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="400" y="453" width="18" height="14" />
+ </bpmndi:BPMNLabel>
</bpmndi:BPMNEdge>
- <bpmndi:BPMNEdge id="SequenceFlow_07e12rt_di" bpmnElement="SequenceFlow_07e12rt">
- <di:waypoint x="385" y="121" />
- <di:waypoint x="455" y="121" />
+ <bpmndi:BPMNEdge id="Flow_0ca4l8d_di" bpmnElement="Flow_0ca4l8d">
+ <di:waypoint x="570" y="910" />
+ <di:waypoint x="662" y="910" />
</bpmndi:BPMNEdge>
<bpmndi:BPMNEdge id="Flow_1jdb2oq_di" bpmnElement="SequenceFlow_1jdb2oq">
- <di:waypoint x="1130" y="121" />
- <di:waypoint x="1220" y="121" />
- <di:waypoint x="1220" y="260" />
- <di:waypoint x="480" y="260" />
- <di:waypoint x="480" y="370" />
+ <di:waypoint x="1000" y="471" />
+ <di:waypoint x="1090" y="471" />
+ <di:waypoint x="1090" y="610" />
+ <di:waypoint x="350" y="610" />
+ <di:waypoint x="350" y="680" />
</bpmndi:BPMNEdge>
<bpmndi:BPMNEdge id="Flow_0fuabjs_di" bpmnElement="Flow_0fuabjs">
- <di:waypoint x="910" y="121" />
- <di:waypoint x="1009" y="121" />
+ <di:waypoint x="780" y="471" />
+ <di:waypoint x="879" y="471" />
</bpmndi:BPMNEdge>
<bpmndi:BPMNEdge id="Flow_0cpctye_di" bpmnElement="Flow_0cpctye">
- <di:waypoint x="690" y="121" />
- <di:waypoint x="789" y="121" />
+ <di:waypoint x="560" y="471" />
+ <di:waypoint x="659" y="471" />
</bpmndi:BPMNEdge>
<bpmndi:BPMNEdge id="SequenceFlow_1qv8qw1_di" bpmnElement="SequenceFlow_1qv8qw1">
- <di:waypoint x="760" y="410" />
- <di:waypoint x="930" y="410" />
+ <di:waypoint x="400" y="910" />
+ <di:waypoint x="470" y="910" />
</bpmndi:BPMNEdge>
<bpmndi:BPMNEdge id="SequenceFlow_03s744c_di" bpmnElement="SequenceFlow_03s744c">
- <di:waypoint x="214" y="121" />
- <di:waypoint x="285" y="121" />
+ <di:waypoint x="208" y="140" />
+ <di:waypoint x="280" y="140" />
</bpmndi:BPMNEdge>
- <bpmndi:BPMNEdge id="Flow_0sj0mtu_di" bpmnElement="Flow_0sj0mtu">
- <di:waypoint x="505" y="121" />
- <di:waypoint x="569" y="121" />
+ <bpmndi:BPMNEdge id="Flow_1xxj5g6_di" bpmnElement="Flow_1xxj5g6">
+ <di:waypoint x="380" y="140" />
+ <di:waypoint x="445" y="140" />
+ </bpmndi:BPMNEdge>
+ <bpmndi:BPMNEdge id="Flow_0elnhnt_di" bpmnElement="Flow_0elnhnt">
+ <di:waypoint x="495" y="140" />
+ <di:waypoint x="570" y="140" />
<bpmndi:BPMNLabel>
- <dc:Bounds x="529" y="103" width="19" height="14" />
+ <dc:Bounds x="524" y="122" width="18" height="14" />
</bpmndi:BPMNLabel>
</bpmndi:BPMNEdge>
- <bpmndi:BPMNEdge id="Flow_0dirb5b_di" bpmnElement="Flow_0dirb5b">
- <di:waypoint x="480" y="146" />
- <di:waypoint x="480" y="370" />
+ <bpmndi:BPMNEdge id="Flow_1yadxwl_di" bpmnElement="Flow_1yadxwl">
+ <di:waypoint x="670" y="140" />
+ <di:waypoint x="750" y="140" />
+ </bpmndi:BPMNEdge>
+ <bpmndi:BPMNEdge id="Flow_14tkuoh_di" bpmnElement="Flow_14tkuoh">
+ <di:waypoint x="208" y="910" />
+ <di:waypoint x="300" y="910" />
+ </bpmndi:BPMNEdge>
+ <bpmndi:BPMNEdge id="Flow_14pzrs9_di" bpmnElement="Flow_14pzrs9">
+ <di:waypoint x="400" y="720" />
+ <di:waypoint x="502" y="720" />
+ </bpmndi:BPMNEdge>
+ <bpmndi:BPMNEdge id="Flow_18xmkvl_di" bpmnElement="Flow_18xmkvl">
+ <di:waypoint x="850" y="140" />
+ <di:waypoint x="921" y="140" />
+ </bpmndi:BPMNEdge>
+ <bpmndi:BPMNEdge id="Flow_1oxjcb2_di" bpmnElement="Flow_1oxjcb2">
+ <di:waypoint x="946" y="165" />
+ <di:waypoint x="946" y="260" />
+ <di:waypoint x="1062" y="260" />
<bpmndi:BPMNLabel>
- <dc:Bounds x="483" y="166" width="14" height="14" />
+ <dc:Bounds x="954" y="210" width="15" height="14" />
</bpmndi:BPMNLabel>
</bpmndi:BPMNEdge>
- <bpmndi:BPMNShape id="StartEvent_1nbljfd_di" bpmnElement="StartEvent_1nbljfd">
- <dc:Bounds x="178" y="103" width="36" height="36" />
+ <bpmndi:BPMNEdge id="Flow_083usqs_di" bpmnElement="Flow_083usqs">
+ <di:waypoint x="971" y="140" />
+ <di:waypoint x="1062" y="140" />
<bpmndi:BPMNLabel>
- <dc:Bounds x="166" y="146" width="70" height="53" />
+ <dc:Bounds x="1008" y="122" width="18" height="14" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNEdge>
+ <bpmndi:BPMNEdge id="Flow_08so17j_di" bpmnElement="Flow_08so17j">
+ <di:waypoint x="208" y="471" />
+ <di:waypoint x="325" y="471" />
+ </bpmndi:BPMNEdge>
+ <bpmndi:BPMNEdge id="Flow_0buil9w_di" bpmnElement="Flow_0buil9w">
+ <di:waypoint x="470" y="165" />
+ <di:waypoint x="470" y="250" />
+ <di:waypoint x="532" y="250" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="478" y="205" width="15" height="14" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNEdge>
+ <bpmndi:BPMNShape id="Event_0ypmuow_di" bpmnElement="Event_0ypmuow">
+ <dc:Bounds x="172" y="892" width="36" height="36" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="154" y="935" width="73" height="27" />
</bpmndi:BPMNLabel>
- </bpmndi:BPMNShape>
- <bpmndi:BPMNShape id="ScriptTask_1ssh2l9_di" bpmnElement="ScriptTask_1ssh2l9">
- <dc:Bounds x="660" y="370" width="100" height="80" />
</bpmndi:BPMNShape>
<bpmndi:BPMNShape id="Activity_013rjwc_di" bpmnElement="Activity_013rjwc">
- <dc:Bounds x="430" y="370" width="100" height="80" />
+ <dc:Bounds x="300" y="680" width="100" height="80" />
+ </bpmndi:BPMNShape>
+ <bpmndi:BPMNShape id="ScriptTask_1ssh2l9_di" bpmnElement="ScriptTask_1ssh2l9">
+ <dc:Bounds x="300" y="870" width="100" height="80" />
</bpmndi:BPMNShape>
<bpmndi:BPMNShape id="Activity_0rgeefb_di" bpmnElement="Activity_0rgeefb">
- <dc:Bounds x="930" y="370" width="100" height="80" />
+ <dc:Bounds x="470" y="870" width="100" height="80" />
</bpmndi:BPMNShape>
<bpmndi:BPMNShape id="EndEvent_05h01gx_di" bpmnElement="EndEvent_05h01gx">
- <dc:Bounds x="1152" y="392" width="36" height="36" />
+ <dc:Bounds x="662" y="892" width="36" height="36" />
<bpmndi:BPMNLabel>
- <dc:Bounds x="1160" y="435" width="20" height="14" />
+ <dc:Bounds x="670" y="935" width="20" height="14" />
</bpmndi:BPMNLabel>
</bpmndi:BPMNShape>
- <bpmndi:BPMNShape id="Activity_1tw8eyy_di" bpmnElement="Activity_1tw8eyy">
- <dc:Bounds x="569" y="74" width="121" height="94" />
+ <bpmndi:BPMNShape id="Event_0c3sko9_di" bpmnElement="Event_0c3sko9">
+ <dc:Bounds x="502" y="702" width="36" height="36" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="480" y="750" width="79" height="40" />
+ </bpmndi:BPMNLabel>
</bpmndi:BPMNShape>
- <bpmndi:BPMNShape id="Gateway_1spi9lo_di" bpmnElement="Gateway_1spi9lo" isMarkerVisible="true">
- <dc:Bounds x="455" y="96" width="50" height="50" />
+ <bpmndi:BPMNShape id="Event_0a5fzwt_di" bpmnElement="Event_0a5fzwt">
+ <dc:Bounds x="172" y="453" width="36" height="36" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="152" y="496" width="77" height="27" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNShape>
+ <bpmndi:BPMNShape id="Gateway_0evcwr8_di" bpmnElement="Gateway_0evcwr8" isMarkerVisible="true">
+ <dc:Bounds x="445" y="115" width="50" height="50" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="437" y="92" width="68" height="14" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNShape>
+ <bpmndi:BPMNShape id="Event_06m6kud_di" bpmnElement="Event_06m6kud">
+ <dc:Bounds x="532" y="232" width="36" height="36" />
<bpmndi:BPMNLabel>
- <dc:Bounds x="443" y="73" width="75" height="14" />
+ <dc:Bounds x="509" y="280" width="81" height="27" />
</bpmndi:BPMNLabel>
</bpmndi:BPMNShape>
+ <bpmndi:BPMNShape id="ScriptTask_1tc44ge_di" bpmnElement="ScriptTask_1tc44ge">
+ <dc:Bounds x="280" y="100" width="100" height="80" />
+ </bpmndi:BPMNShape>
+ <bpmndi:BPMNShape id="StartEvent_1nbljfd_di" bpmnElement="StartEvent_1nbljfd">
+ <dc:Bounds x="172" y="122" width="36" height="36" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="160" y="165" width="70" height="53" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNShape>
+ <bpmndi:BPMNShape id="Activity_1tw8eyy_di" bpmnElement="Activity_1tw8eyy">
+ <dc:Bounds x="439" y="424" width="121" height="94" />
+ </bpmndi:BPMNShape>
<bpmndi:BPMNShape id="Activity_0p20esb_di" bpmnElement="Activity_0p20esb">
- <dc:Bounds x="789" y="74" width="121" height="94" />
+ <dc:Bounds x="659" y="424" width="121" height="94" />
</bpmndi:BPMNShape>
<bpmndi:BPMNShape id="Activity_0phv8e5_di" bpmnElement="Activity_0phv8e5">
- <dc:Bounds x="1009" y="74" width="121" height="94" />
+ <dc:Bounds x="879" y="424" width="121" height="94" />
+ </bpmndi:BPMNShape>
+ <bpmndi:BPMNShape id="Gateway_1spi9lo_di" bpmnElement="Gateway_1spi9lo" isMarkerVisible="true">
+ <dc:Bounds x="325" y="446" width="50" height="50" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="313" y="423" width="75" height="14" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNShape>
+ <bpmndi:BPMNShape id="Event_01bin3l_di" bpmnElement="Event_01bin3l">
+ <dc:Bounds x="1062" y="122" width="36" height="36" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="1039" y="170" width="81" height="27" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNShape>
+ <bpmndi:BPMNShape id="Event_0l28lqi_di" bpmnElement="Event_0l28lqi">
+ <dc:Bounds x="1062" y="242" width="36" height="36" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="1040" y="290" width="79" height="40" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNShape>
+ <bpmndi:BPMNShape id="Gateway_0m3yrzp_di" bpmnElement="Gateway_0m3yrzp" isMarkerVisible="true">
+ <dc:Bounds x="921" y="115" width="50" height="50" />
+ <bpmndi:BPMNLabel>
+ <dc:Bounds x="915" y="85" width="64" height="27" />
+ </bpmndi:BPMNLabel>
+ </bpmndi:BPMNShape>
+ <bpmndi:BPMNShape id="Activity_0ztykbe_di" bpmnElement="Activity_0ztykbe">
+ <dc:Bounds x="750" y="100" width="100" height="80" />
+ </bpmndi:BPMNShape>
+ <bpmndi:BPMNShape id="Activity_0tw406b_di" bpmnElement="Activity_0tw406b">
+ <dc:Bounds x="570" y="100" width="100" height="80" />
</bpmndi:BPMNShape>
<bpmndi:BPMNShape id="SubProcess_1yv9i68_di" bpmnElement="SubProcess_1yv9i68" isExpanded="true">
- <dc:Bounds x="685" y="1080" width="781" height="196" />
+ <dc:Bounds x="555" y="1430" width="781" height="196" />
</bpmndi:BPMNShape>
<bpmndi:BPMNEdge id="SequenceFlow_08mlzwz_di" bpmnElement="SequenceFlow_08mlzwz">
- <di:waypoint x="1079" y="1184" />
- <di:waypoint x="1353" y="1184" />
+ <di:waypoint x="949" y="1534" />
+ <di:waypoint x="1223" y="1534" />
</bpmndi:BPMNEdge>
<bpmndi:BPMNEdge id="SequenceFlow_1w67v6s_di" bpmnElement="SequenceFlow_1w67v6s">
- <di:waypoint x="751" y="1184" />
- <di:waypoint x="979" y="1184" />
+ <di:waypoint x="621" y="1534" />
+ <di:waypoint x="849" y="1534" />
</bpmndi:BPMNEdge>
<bpmndi:BPMNShape id="StartEvent_1omdx56_di" bpmnElement="StartEvent_1omdx56">
- <dc:Bounds x="715" y="1166" width="36" height="36" />
+ <dc:Bounds x="585" y="1516" width="36" height="36" />
</bpmndi:BPMNShape>
<bpmndi:BPMNShape id="EndEvent_1jx3026_di" bpmnElement="EndEvent_1jx3026">
- <dc:Bounds x="1353" y="1166" width="36" height="36" />
+ <dc:Bounds x="1223" y="1516" width="36" height="36" />
</bpmndi:BPMNShape>
<bpmndi:BPMNShape id="ScriptTask_1swzdpw_di" bpmnElement="ScriptTask_1swzdpw">
- <dc:Bounds x="979" y="1144" width="100" height="80" />
- </bpmndi:BPMNShape>
- <bpmndi:BPMNShape id="ScriptTask_1tc44ge_di" bpmnElement="ScriptTask_1tc44ge">
- <dc:Bounds x="285" y="81" width="100" height="80" />
+ <dc:Bounds x="849" y="1494" width="100" height="80" />
</bpmndi:BPMNShape>
</bpmndi:BPMNPlane>
</bpmndi:BPMNDiagram>
--- /dev/null
+/*-
+ * ============LICENSE_START=======================================================
+ * ONAP - SO
+ * ================================================================================
+ * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved.
+ * ================================================================================
+ * Modifications Copyright (c) 2019 Samsung
+ * ================================================================================
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ * ============LICENSE_END=========================================================
+ */
+
+package org.onap.so.bpmn.infrastructure.adapter.cnf.tasks;
+
+import java.io.IOException;
+import java.util.HashMap;
+import java.util.Map;
+import org.onap.so.bpmn.common.BuildingBlockExecution;
+import org.onap.so.bpmn.servicedecomposition.bbobjects.CloudRegion;
+import org.onap.so.bpmn.servicedecomposition.bbobjects.GenericVnf;
+import org.onap.so.bpmn.servicedecomposition.bbobjects.ServiceInstance;
+import org.onap.so.bpmn.servicedecomposition.bbobjects.VfModule;
+import org.onap.so.bpmn.servicedecomposition.entities.GeneralBuildingBlock;
+import org.onap.so.bpmn.servicedecomposition.entities.ResourceKey;
+import org.onap.so.bpmn.servicedecomposition.generalobjects.RequestContext;
+import org.onap.so.bpmn.servicedecomposition.tasks.ExtractPojosForBB;
+import org.onap.so.client.adapter.cnf.CnfAdapterClient;
+import org.onap.so.client.adapter.cnf.entities.UpgradeInstanceRequest;
+import org.onap.so.client.adapter.cnf.entities.UpgradeInstanceResponse;
+import org.onap.so.client.adapter.vnf.mapper.AttributeNameValue;
+import org.onap.so.client.adapter.vnf.mapper.Attributes;
+import org.onap.so.client.adapter.vnf.mapper.VnfAdapterVfModuleObjectMapper;
+import org.onap.so.client.exception.ExceptionBuilder;
+import org.onap.so.openstack.utils.MsoMulticloudUtils;
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
+import org.springframework.beans.factory.annotation.Autowired;
+import org.springframework.stereotype.Component;
+import com.fasterxml.jackson.core.JsonParseException;
+import com.fasterxml.jackson.core.JsonProcessingException;
+import com.fasterxml.jackson.databind.JsonMappingException;
+import com.fasterxml.jackson.databind.ObjectMapper;
+
+@Component
+public class CnfAdapterUpgradeTasks {
+ private static final Logger logger = LoggerFactory.getLogger(CnfAdapterUpgradeTasks.class);
+
+ public static final String SDNCQUERY_RESPONSE = "SDNCQueryResponse_";
+
+ @Autowired
+ private ExtractPojosForBB extractPojosForBB;
+ @Autowired
+ private ExceptionBuilder exceptionUtil;
+ @Autowired
+ private CnfAdapterClient cnfAdapterClient;
+ @Autowired
+ private VnfAdapterVfModuleObjectMapper vfModuleMapper;
+
+ private ObjectMapper mapper = new ObjectMapper();
+
+ /**
+ * This method is used for updating the request for an Instance in Multicloud K8s Plugin.
+ *
+ * @param execution
+ * @return
+ */
+ public void upgradeInstance(BuildingBlockExecution execution) {
+ try {
+ GeneralBuildingBlock gBBInput = execution.getGeneralBuildingBlock();
+ ServiceInstance serviceInstance =
+ gBBInput.getCustomer().getServiceSubscription().getServiceInstances().get(0);
+ GenericVnf genericVnf = extractPojosForBB.extractByKey(execution, ResourceKey.GENERIC_VNF_ID);
+ VfModule vfModule = extractPojosForBB.extractByKey(execution, ResourceKey.VF_MODULE_ID);
+ RequestContext requestContext = gBBInput.getRequestContext();
+ CloudRegion cloudRegion = gBBInput.getCloudRegion();
+ String sdncVfModuleQueryResponse = execution.getVariable(SDNCQUERY_RESPONSE + vfModule.getVfModuleId());
+ String sdncVnfQueryResponse = execution.getVariable(SDNCQUERY_RESPONSE + genericVnf.getVnfId());
+ Map<String, Object> paramsMap = vfModuleMapper.buildVfModuleParamsMap(requestContext, serviceInstance,
+ genericVnf, vfModule, sdncVnfQueryResponse, sdncVfModuleQueryResponse);
+ Map<String, String> sdncDirectives = getSdncDirectives(paramsMap);
+ UpgradeInstanceRequest upgradeInstanceRequest =
+ upgradeInstanceRequest(vfModule, cloudRegion, sdncDirectives);
+ UpgradeInstanceResponse response = cnfAdapterClient.upgradeVfModule(upgradeInstanceRequest);
+ execution.setVariable("heatStackId", response.getId());
+ } catch (Exception ex) {
+ logger.error("Exception occurred", ex);
+ exceptionUtil.buildAndThrowWorkflowException(execution, 7000, ex);
+ }
+ }
+
+ protected Map<String, String> getSdncDirectives(Map<String, Object> paramsMap)
+ throws JsonParseException, JsonMappingException, IOException {
+ Map<String, String> sdncDirectivesMap = new HashMap<>();
+ String sdncDirectivesString = (String) paramsMap.get(MsoMulticloudUtils.SDNC_DIRECTIVES);
+ Attributes sdncDirectives = mapper.readValue(sdncDirectivesString, Attributes.class);
+ for (AttributeNameValue nameVal : sdncDirectives.getAttributes()) {
+ sdncDirectivesMap.put(nameVal.getAttributeName(), (String) nameVal.getAttributeValue());
+ }
+ return sdncDirectivesMap;
+ }
+
+ protected UpgradeInstanceRequest upgradeInstanceRequest(VfModule vfModule, CloudRegion cloudRegion,
+ Map<String, String> sdncDirectives) {
+
+ UpgradeInstanceRequest request = new UpgradeInstanceRequest();
+
+ request.setModelInvariantId(vfModule.getModelInfoVfModule().getModelInvariantUUID());
+ request.setModelCustomizationId(vfModule.getModelInfoVfModule().getModelCustomizationUUID());
+ request.setCloudRegion(cloudRegion.getLcpCloudRegionId());
+ request.setVfModuleUUID(vfModule.getVfModuleId());
+ request.setProfileName(sdncDirectives.get("k8s-rb-profile-name"));
+ request.setLabels(sdncDirectives);
+ if (sdncDirectives.containsKey("k8s-rb-instance-status-check"))
+ request.setStatusCheck(sdncDirectives.get("k8s-rb-instance-status-check").equalsIgnoreCase("true"));
+ request.setOverrideValues(sdncDirectives);
+ return request;
+ }
+
+}
private static final String VFMODULE = "VfModule";
private static final String NETWORK = "Network";
private static final String HEALTH_CHECK = "HealthCheckBB";
+ private static final String UPGRADE_CNF = "UpgradeVfModuleBB";
protected List<ExecuteBuildingBlock> buildExecuteBuildingBlockList(List<OrchestrationFlow> orchFlows,
List<Resource> originalResourceList, String requestId, String apiVersion, String resourceId,
&& (VNF).equalsIgnoreCase(orchFlow.getBpmnScope())) {
addBuildingBlockToExecuteBBList(flowsToExecute, resource, WorkflowType.VNF, orchFlow, requestId, apiVersion,
resourceId, requestAction, vnfType, workflowResourceIds, requestDetails, false, false);
+ } else if ((orchFlow.getFlowName().equalsIgnoreCase(UPGRADE_CNF))
+ && (VNF).equalsIgnoreCase(orchFlow.getBpmnScope())) {
+ addBuildingBlockToExecuteBBList(flowsToExecute, resource, WorkflowType.VNF, orchFlow, requestId, apiVersion,
+ resourceId, requestAction, vnfType, workflowResourceIds, requestDetails, false, false);
} else if (orchFlow.getFlowName().contains(PNF)
|| (orchFlow.getFlowName().contains(CONTROLLER) && (PNF).equalsIgnoreCase(orchFlow.getBpmnScope()))) {
addBuildingBlockToExecuteBBList(flowsToExecute, resource, WorkflowType.PNF, orchFlow, requestId, apiVersion,
import static org.onap.so.bpmn.infrastructure.workflow.tasks.WorkflowActionConstants.UPDATE_INSTANCE;
import static org.onap.so.bpmn.infrastructure.workflow.tasks.WorkflowActionConstants.HEALTH_CHECK;
import static org.onap.so.bpmn.infrastructure.workflow.tasks.WorkflowActionConstants.WORKFLOW_ACTION_ERROR_MESSAGE;
+import static org.onap.so.bpmn.infrastructure.workflow.tasks.WorkflowActionConstants.UPGRADE_CNF;
import java.io.IOException;
import java.util.ArrayList;
import java.util.Arrays;
} else if (resourceType == WorkflowType.VNF && HEALTH_CHECK.equalsIgnoreCase(requestAction)) {
vnfEBBLoader.customTraverseAAIVnf(execution, resourceList, workflowResourceIds.getServiceInstanceId(),
workflowResourceIds.getVnfId(), aaiResourceIds);
+ } else if (resourceType == WorkflowType.VNF && UPGRADE_CNF.equalsIgnoreCase(requestAction)) {
+ vnfEBBLoader.customTraverseAAIVnf(execution, resourceList, workflowResourceIds.getServiceInstanceId(),
+ workflowResourceIds.getVnfId(), aaiResourceIds);
} else {
buildAndThrowException(execution, "Current Macro Request is not supported");
}
public static final String VOLUMEGROUP = "VolumeGroup";
public static final String HEALTH_CHECK = "healthCheck";
public static final String WORKFLOW_ACTION_ERROR_MESSAGE = "WorkflowActionErrorMessage";
+ public static final String UPGRADE_CNF = "upgradeCnf";
}
import org.apache.http.HttpStatus;
import org.onap.so.client.adapter.cnf.entities.InstanceRequest;
import org.onap.so.client.adapter.cnf.entities.InstanceResponse;
+import org.onap.so.client.adapter.cnf.entities.UpgradeInstanceResponse;
+import org.onap.so.client.adapter.cnf.entities.UpgradeInstanceRequest;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import org.springframework.beans.factory.annotation.Autowired;
}
}
+ @Retryable(value = {HttpServerErrorException.class}, maxAttempts = 3, backoff = @Backoff(delay = 3000))
+ public UpgradeInstanceResponse upgradeVfModule(UpgradeInstanceRequest request) throws CnfAdapterClientException {
+ try {
+ String uri = "http://so-cnf-adapter:8090";
+ String endpoint = UriBuilder.fromUri(uri).path("/api/cnf-adapter/v1/instance/{instanceID}/upgrade").build()
+ .toString();
+ HttpEntity<?> entity = getHttpEntity(request);
+ ResponseEntity<UpgradeInstanceResponse> result =
+ restTemplate.exchange(endpoint, HttpMethod.POST, entity, UpgradeInstanceResponse.class);
+ return result.getBody();
+ } catch (HttpClientErrorException e) {
+ logger.error("Error Calling CNF Adapter, e");
+ if (HttpStatus.SC_NOT_FOUND == e.getStatusCode().value()) {
+ throw new EntityNotFoundException(e.getResponseBodyAsString());
+ }
+ throw e;
+ }
+ }
+
protected HttpHeaders getHttpHeaders() {
HttpHeaders headers = new HttpHeaders();
List<MediaType> acceptableMediaTypes = new ArrayList<>();
return new HttpEntity<>(request, headers);
}
+ protected HttpEntity<?> getHttpEntity(UpgradeInstanceRequest request) {
+ HttpHeaders headers = getHttpHeaders();
+ return new HttpEntity<>(request, headers);
+ }
}
--- /dev/null
+
+package org.onap.so.client.adapter.cnf.entities;
+
+import java.util.Map;
+import com.fasterxml.jackson.annotation.JsonInclude;
+import com.fasterxml.jackson.annotation.JsonProperty;
+import com.fasterxml.jackson.annotation.JsonPropertyOrder;
+
+@JsonInclude(JsonInclude.Include.NON_NULL)
+public class UpgradeInstanceRequest {
+
+ @JsonProperty("modelInvariantId")
+ private String modelInvariantId;
+
+ @JsonProperty("modelCustomizationId")
+ private String modelCustomizationId;
+
+ @JsonProperty("k8sRBProfileName")
+ private String profileName;
+
+ @JsonProperty("k8sRBInstanceStatusCheck")
+ private Boolean statusCheck = false;
+
+ @JsonProperty("cloudRegionId")
+ private String cloudRegion;
+
+ @JsonProperty("vfModuleUUID")
+ private String vfModuleUUID;
+
+ @JsonProperty("labels")
+ private Map<String, String> labels;
+
+ @JsonProperty("override-values")
+ private Map<String, String> overrideValues;
+
+ public String getModelInvariantId() {
+ return modelInvariantId;
+ }
+
+ public void setModelInvariantId(String modelInvariantId) {
+ this.modelInvariantId = modelInvariantId;
+ }
+
+ public String getModelCustomizationId() {
+ return modelCustomizationId;
+ }
+
+ public void setModelCustomizationId(String modelCustomizationId) {
+ this.modelCustomizationId = modelCustomizationId;
+ }
+
+ public String getProfileName() {
+ return profileName;
+ }
+
+ public void setProfileName(String profileName) {
+ this.profileName = profileName;
+ }
+
+ public Boolean getStatusCheck() {
+ return statusCheck;
+ }
+
+ public void setStatusCheck(Boolean statusCheck) {
+ this.statusCheck = statusCheck;
+ }
+
+ public String getCloudRegion() {
+ return cloudRegion;
+ }
+
+ public void setCloudRegion(String cloudRegion) {
+ this.cloudRegion = cloudRegion;
+ }
+
+ public Map<String, String> getLabels() {
+ return labels;
+ }
+
+ public void setLabels(Map<String, String> labels) {
+ this.labels = labels;
+ }
+
+ public String getVfModuleUUID() {
+ return vfModuleUUID;
+ }
+
+ public void setVfModuleUUID(String vfModuleUUID) {
+ this.vfModuleUUID = vfModuleUUID;
+ }
+
+ public Map<String, String> getOverrideValues() {
+ return overrideValues;
+ }
+
+ public void setOverrideValues(Map<String, String> overrideValues) {
+ this.overrideValues = overrideValues;
+ }
+
+}
--- /dev/null
+
+package org.onap.so.client.adapter.cnf.entities;
+
+import java.util.List;
+import com.fasterxml.jackson.annotation.JsonInclude;
+import com.fasterxml.jackson.annotation.JsonProperty;
+import com.fasterxml.jackson.annotation.JsonPropertyOrder;
+
+@JsonInclude(JsonInclude.Include.NON_NULL)
+@JsonPropertyOrder({"id", "request", "namespace", "release-name", "resources"})
+public class UpgradeInstanceResponse {
+
+ @JsonProperty("id")
+ private String id;
+
+ @JsonProperty("request")
+ private InstanceRequest request;
+
+ @JsonProperty("namespace")
+ private String namespace;
+
+ @JsonProperty("release-name")
+ private String releaseName;
+
+ @JsonProperty("resources")
+ private List<Resource> resources = null;
+
+ @JsonProperty("id")
+ public String getId() {
+ return id;
+ }
+
+ @JsonProperty("id")
+ public void setId(String id) {
+ this.id = id;
+ }
+
+ @JsonProperty("request")
+ public InstanceRequest getRequest() {
+ return request;
+ }
+
+ @JsonProperty("request")
+ public void setRequest(InstanceRequest request) {
+ this.request = request;
+ }
+
+ @JsonProperty("namespace")
+ public String getNamespace() {
+ return namespace;
+ }
+
+ @JsonProperty("namespace")
+ public void setNamespace(String namespace) {
+ this.namespace = namespace;
+ }
+
+ @JsonProperty("resources")
+ public List<Resource> getResources() {
+ return resources;
+ }
+
+ @JsonProperty("resources")
+ public void setResources(List<Resource> resources) {
+ this.resources = resources;
+ }
+
+ @JsonProperty("release-name")
+ public String getReleaseName() {
+ return releaseName;
+ }
+
+ @JsonProperty("release-name")
+ public void setReleaseName(String releaseName) {
+ this.releaseName = releaseName;
+ }
+
+}
import org.camunda.bpm.engine.delegate.BpmnError;
import org.junit.Before;
import org.junit.Test;
+import org.junit.runner.RunWith;
import org.mockito.ArgumentMatchers;
import org.mockito.InjectMocks;
+import org.mockito.Mock;
import org.mockito.Mockito;
+import org.mockito.junit.MockitoJUnitRunner;
import org.onap.so.adapters.nwrest.CreateNetworkResponse;
import org.onap.so.adapters.nwrest.UpdateNetworkResponse;
-import org.onap.so.bpmn.BaseTaskTest;
import org.onap.so.bpmn.common.BuildingBlockExecution;
+import org.onap.so.bpmn.common.data.TestDataSetup;
import org.onap.so.bpmn.servicedecomposition.bbobjects.CloudRegion;
import org.onap.so.bpmn.servicedecomposition.bbobjects.Configuration;
import org.onap.so.bpmn.servicedecomposition.bbobjects.GenericVnf;
import org.onap.so.bpmn.servicedecomposition.bbobjects.VfModule;
import org.onap.so.bpmn.servicedecomposition.bbobjects.VolumeGroup;
import org.onap.so.bpmn.servicedecomposition.entities.ResourceKey;
+import org.onap.so.bpmn.servicedecomposition.tasks.ExtractPojosForBB;
import org.onap.so.client.exception.BBObjectNotFoundException;
+import org.onap.so.client.exception.ExceptionBuilder;
+import org.onap.so.client.orchestration.AAICollectionResources;
+import org.onap.so.client.orchestration.AAIConfigurationResources;
+import org.onap.so.client.orchestration.AAINetworkResources;
+import org.onap.so.client.orchestration.AAIPnfResources;
+import org.onap.so.client.orchestration.AAIServiceInstanceResources;
+import org.onap.so.client.orchestration.AAIVfModuleResources;
+import org.onap.so.client.orchestration.AAIVnfResources;
+import org.onap.so.client.orchestration.AAIVolumeGroupResources;
import org.onap.so.db.catalog.beans.OrchestrationStatus;
import java.util.HashMap;
import static org.junit.Assert.assertEquals;
import static org.mockito.Mockito.verify;
import static org.mockito.Mockito.when;
-public class AAIUpdateTasksTest extends BaseTaskTest {
-
+@RunWith(MockitoJUnitRunner.Silent.class)
+public class AAIUpdateTasksTest extends TestDataSetup {
+
+ @Mock
+ protected ExtractPojosForBB extractPojosForBB;
+ @Mock
+ protected ExceptionBuilder exceptionUtil;
+ @Mock
+ protected AAIServiceInstanceResources aaiServiceInstanceResources;
+ @Mock
+ protected AAIPnfResources aaiPnfResources;
+ @Mock
+ protected AAIVnfResources aaiVnfResources;
+ @Mock
+ protected AAIVfModuleResources aaiVfModuleResources;
+ @Mock
+ protected AAIVolumeGroupResources aaiVolumeGroupResources;
+ @Mock
+ protected AAINetworkResources aaiNetworkResources;
+ @Mock
+ protected AAICollectionResources aaiCollectionResources;
+ @Mock
+ protected AAIConfigurationResources aaiConfigurationResources;
@InjectMocks
private AAIUpdateTasks aaiUpdateTasks = new AAIUpdateTasks();
}
@Test
- public void updateOrchestrationStatusAssignedServiceTest() throws Exception {
+ public void updateOrchestrationStatusAssignedServiceTest() {
doNothing().when(aaiServiceInstanceResources).updateOrchestrationStatusServiceInstance(serviceInstance,
OrchestrationStatus.ASSIGNED);
}
@Test
- public void updateOrchestrationStatusAssignedServiceExceptionTest() throws Exception {
+ public void updateOrchestrationStatusAssignedServiceExceptionTest() {
expectedException.expect(BpmnError.class);
doThrow(RuntimeException.class).when(aaiServiceInstanceResources)
}
@Test
- public void updateOrchestrationStatusActiveServiceTest() throws Exception {
+ public void updateOrchestrationStatusActiveServiceTest() {
doNothing().when(aaiServiceInstanceResources).updateOrchestrationStatusServiceInstance(serviceInstance,
OrchestrationStatus.ACTIVE);
}
@Test
- public void updateOrchestrationStatusActiveServiceExceptionTest() throws Exception {
+ public void updateOrchestrationStatusActiveServiceExceptionTest() {
expectedException.expect(BpmnError.class);
doThrow(RuntimeException.class).when(aaiServiceInstanceResources)
}
@Test
- public void updateOrchestrationStatusAssignedVnfTest() throws Exception {
+ public void updateOrchestrationStatusAssignedVnfTest() {
doNothing().when(aaiVnfResources).updateOrchestrationStatusVnf(genericVnf, OrchestrationStatus.ASSIGNED);
aaiUpdateTasks.updateOrchestrationStatusAssignedVnf(execution);
}
@Test
- public void updateOrchestrationStatusAssignedVnfExceptionTest() throws Exception {
+ public void updateOrchestrationStatusAssignedVnfExceptionTest() {
expectedException.expect(BpmnError.class);
doThrow(RuntimeException.class).when(aaiVnfResources).updateOrchestrationStatusVnf(genericVnf,
}
@Test
- public void updateOrchestrationStatusActiveVnfTest() throws Exception {
+ public void updateOrchestrationStatusActiveVnfTest() {
doNothing().when(aaiVnfResources).updateOrchestrationStatusVnf(genericVnf, OrchestrationStatus.ACTIVE);
aaiUpdateTasks.updateOrchestrationStatusActiveVnf(execution);
}
@Test
- public void updateOrchestrationStatusActiveVnfExceptionTest() throws Exception {
+ public void updateOrchestrationStatusActiveVnfExceptionTest() {
expectedException.expect(BpmnError.class);
doThrow(RuntimeException.class).when(aaiVnfResources).updateOrchestrationStatusVnf(genericVnf,
}
@Test
- public void updateOrchestrationStatusAssignVfModuleTest() throws Exception {
+ public void updateOrchestrationStatusAssignVfModuleTest() {
doNothing().when(aaiVfModuleResources).updateOrchestrationStatusVfModule(vfModule, genericVnf,
OrchestrationStatus.ASSIGNED);
aaiUpdateTasks.updateOrchestrationStatusAssignedVfModule(execution);
}
@Test
- public void updateOrchestrationStatusAssignVfModuleExceptionTest() throws Exception {
+ public void updateOrchestrationStatusAssignVfModuleExceptionTest() {
doThrow(RuntimeException.class).when(aaiVfModuleResources).updateOrchestrationStatusVfModule(vfModule,
genericVnf, OrchestrationStatus.ASSIGNED);
}
@Test
- public void updateOrchestrationStatusCreatedVfModuleTest() throws Exception {
+ public void updateOrchestrationStatusCreatedVfModuleTest() {
doNothing().when(aaiVfModuleResources).updateOrchestrationStatusVfModule(vfModule, genericVnf,
OrchestrationStatus.CREATED);
aaiUpdateTasks.updateOrchestrationStatusCreatedVfModule(execution);
}
@Test
- public void updateOrchestrationStatusCreatedVfModuleExceptionTest() throws Exception {
+ public void updateOrchestrationStatusCreatedVfModuleExceptionTest() {
doThrow(RuntimeException.class).when(aaiVfModuleResources).updateOrchestrationStatusVfModule(vfModule,
genericVnf, OrchestrationStatus.CREATED);
}
@Test
- public void updateOrchestrationStatusPendingActivatefModuleTest() throws Exception {
+ public void updateOrchestrationStatusPendingActivatefModuleTest() {
doNothing().when(aaiVfModuleResources).updateOrchestrationStatusVfModule(vfModule, genericVnf,
OrchestrationStatus.PENDING_ACTIVATION);
}
@Test
- public void updateOrchestrationStatusPendingActivatefModuleExceptionTest() throws Exception {
+ public void updateOrchestrationStatusPendingActivatefModuleExceptionTest() {
doThrow(RuntimeException.class).when(aaiVfModuleResources).updateOrchestrationStatusVfModule(vfModule,
genericVnf, OrchestrationStatus.PENDING_ACTIVATION);
}
@Test
- public void updateOrchestrationStatusDectivateVfModuleTest() throws Exception {
+ public void updateOrchestrationStatusDectivateVfModuleTest() {
doNothing().when(aaiVfModuleResources).updateOrchestrationStatusVfModule(vfModule, genericVnf,
OrchestrationStatus.CREATED);
}
@Test
- public void updateOrchestrationStatusDectivateVfModuleExceptionTest() throws Exception {
+ public void updateOrchestrationStatusDectivateVfModuleExceptionTest() {
doThrow(RuntimeException.class).when(aaiVfModuleResources).updateOrchestrationStatusVfModule(vfModule,
genericVnf, OrchestrationStatus.CREATED);
}
@Test
- public void updateHeatStackIdVfModuleTest() throws Exception {
+ public void updateHeatStackIdVfModuleTest() {
execution.setVariable("heatStackId", "newHeatStackId");
doNothing().when(aaiVfModuleResources).updateHeatStackIdVfModule(vfModule, genericVnf);
}
@Test
- public void updateHeatStackIdVfModuleToNullTest() throws Exception {
+ public void updateHeatStackIdVfModuleToNullTest() {
execution.setVariable("heatStackId", null);
doNothing().when(aaiVfModuleResources).updateHeatStackIdVfModule(vfModule, genericVnf);
aaiUpdateTasks.updateHeatStackIdVfModule(execution);
verify(aaiVfModuleResources, times(1)).updateHeatStackIdVfModule(vfModule, genericVnf);
- assertEquals(vfModule.getHeatStackId(), "");
+ assertEquals("", vfModule.getHeatStackId());
}
@Test
- public void updateHeatStackIdVfModuleExceptionTest() throws Exception {
+ public void updateHeatStackIdVfModuleExceptionTest() {
doThrow(RuntimeException.class).when(aaiVfModuleResources).updateHeatStackIdVfModule(vfModule, genericVnf);
expectedException.expect(BpmnError.class);
}
@Test
- public void updateOrchestrationStatusActiveVolumeGroupTest() throws Exception {
+ public void updateOrchestrationStatusActiveVolumeGroupTest() {
doNothing().when(aaiVolumeGroupResources).updateOrchestrationStatusVolumeGroup(volumeGroup, cloudRegion,
OrchestrationStatus.ACTIVE);
}
@Test
- public void updateOrchestrationStatusActiveVolumeGroupExceptionTest() throws Exception {
+ public void updateOrchestrationStatusActiveVolumeGroupExceptionTest() {
expectedException.expect(BpmnError.class);
doThrow(RuntimeException.class).when(aaiVolumeGroupResources).updateOrchestrationStatusVolumeGroup(volumeGroup,
cloudRegion, OrchestrationStatus.ACTIVE);
}
@Test
- public void updateOrchestrationStatusCreatedVolumeGroupTest() throws Exception {
+ public void updateOrchestrationStatusCreatedVolumeGroupTest() {
doNothing().when(aaiVolumeGroupResources).updateOrchestrationStatusVolumeGroup(volumeGroup, cloudRegion,
OrchestrationStatus.CREATED);
}
@Test
- public void updateOrchestrationStatusCreatedVolumeGroupExceptionTest() throws Exception {
+ public void updateOrchestrationStatusCreatedVolumeGroupExceptionTest() {
expectedException.expect(BpmnError.class);
doThrow(RuntimeException.class).when(aaiVolumeGroupResources).updateOrchestrationStatusVolumeGroup(volumeGroup,
cloudRegion, OrchestrationStatus.CREATED);
}
@Test
- public void test_updateOrchestrationStatusAssignedVolumeGroup() throws Exception {
+ public void test_updateOrchestrationStatusAssignedVolumeGroup() {
doNothing().when(aaiVolumeGroupResources).updateOrchestrationStatusVolumeGroup(volumeGroup, cloudRegion,
OrchestrationStatus.ASSIGNED);
}
@Test
- public void test_updateOrchestrationStatusAssignedVolumeGroup_exception() throws Exception {
+ public void test_updateOrchestrationStatusAssignedVolumeGroup_exception() {
expectedException.expect(BpmnError.class);
doThrow(RuntimeException.class).when(aaiVolumeGroupResources).updateOrchestrationStatusVolumeGroup(volumeGroup,
cloudRegion, OrchestrationStatus.ASSIGNED);
}
@Test
- public void updateHeatStackIdVolumeGroupTest() throws Exception {
+ public void updateHeatStackIdVolumeGroupTest() {
execution.setVariable("heatStackId", "newHeatStackId");
doNothing().when(aaiVolumeGroupResources).updateHeatStackIdVolumeGroup(volumeGroup, cloudRegion);
}
@Test
- public void updateHeatStackIdVolumeGroupToNullTest() throws Exception {
+ public void updateHeatStackIdVolumeGroupToNullTest() {
execution.setVariable("heatStackId", null);
doNothing().when(aaiVolumeGroupResources).updateHeatStackIdVolumeGroup(volumeGroup, cloudRegion);
aaiUpdateTasks.updateHeatStackIdVolumeGroup(execution);
verify(aaiVolumeGroupResources, times(1)).updateHeatStackIdVolumeGroup(volumeGroup, cloudRegion);
- assertEquals(volumeGroup.getHeatStackId(), "");
+ assertEquals("", volumeGroup.getHeatStackId());
}
@Test
- public void updateHeatStackIdVolumeGroupExceptionTest() throws Exception {
+ public void updateHeatStackIdVolumeGroupExceptionTest() {
expectedException.expect(BpmnError.class);
doThrow(RuntimeException.class).when(aaiVolumeGroupResources).updateHeatStackIdVolumeGroup(volumeGroup,
cloudRegion);
}
@Test
- public void updateNetworkExceptionTest() throws Exception {
+ public void updateNetworkExceptionTest() {
expectedException.expect(BpmnError.class);
doThrow(RuntimeException.class).when(aaiNetworkResources).updateNetwork(network);
}
@Test
- public void updateOstatusActivedNetworkCollectionTest() throws Exception {
+ public void updateOstatusActivedNetworkCollectionTest() {
doNothing().when(aaiCollectionResources).updateCollection(serviceInstance.getCollection());
aaiUpdateTasks.updateOrchestrationStatusActiveNetworkCollection(execution);
verify(aaiCollectionResources, times(1)).updateCollection(serviceInstance.getCollection());
}
@Test
- public void updateOstatusActiveNetworkColectionExceptionTest() throws Exception {
+ public void updateOstatusActiveNetworkColectionExceptionTest() {
expectedException.expect(BpmnError.class);
doThrow(RuntimeException.class).when(aaiCollectionResources).updateCollection(serviceInstance.getCollection());
aaiUpdateTasks.updateOrchestrationStatusActiveNetworkCollection(execution);
}
@Test
- public void updateOrchestrationStatusActivateVfModuleTest() throws Exception {
+ public void updateOrchestrationStatusActivateVfModuleTest() {
doNothing().when(aaiVfModuleResources).updateOrchestrationStatusVfModule(vfModule, genericVnf,
OrchestrationStatus.ACTIVE);
}
@Test
- public void updateOrchestrationStatusActivateVfModuleExceptionTest() throws Exception {
+ public void updateOrchestrationStatusActivateVfModuleExceptionTest() {
doThrow(RuntimeException.class).when(aaiVfModuleResources).updateOrchestrationStatusVfModule(vfModule,
genericVnf, OrchestrationStatus.ACTIVE);
}
@Test
- public void updateOrchestrationStatusDeleteVfModuleTest() throws Exception {
+ public void updateOrchestrationStatusDeleteVfModuleTest() {
doNothing().when(aaiVfModuleResources).updateOrchestrationStatusVfModule(vfModule, genericVnf,
OrchestrationStatus.ASSIGNED);
}
@Test
- public void updateOrchestrationStatusDeactivateFabricConfigurationTest() throws Exception {
+ public void updateOrchestrationStatusDeactivateFabricConfigurationTest() {
gBBInput = execution.getGeneralBuildingBlock();
doNothing().when(aaiConfigurationResources).updateOrchestrationStatusConfiguration(configuration,
OrchestrationStatus.ASSIGNED);
}
@Test
- public void updateOrchestrationStatusActivateFabricConfigurationTest() throws Exception {
+ public void updateOrchestrationStatusActivateFabricConfigurationTest() {
gBBInput = execution.getGeneralBuildingBlock();
doNothing().when(aaiConfigurationResources).updateOrchestrationStatusConfiguration(configuration,
OrchestrationStatus.ACTIVE);
}
@Test
- public void updateOrchestrationStatusAssignedFabricConfigurationTest() throws Exception {
+ public void updateOrchestrationStatusAssignedFabricConfigurationTest() {
gBBInput = execution.getGeneralBuildingBlock();
doNothing().when(aaiConfigurationResources).updateOrchestrationStatusConfiguration(configuration,
OrchestrationStatus.ASSIGNED);
}
@Test
- public void updateContrailServiceInstanceFqdnVfModuleTest() throws Exception {
+ public void updateContrailServiceInstanceFqdnVfModuleTest() {
execution.setVariable("contrailServiceInstanceFqdn", "newContrailServiceInstanceFqdn");
doNothing().when(aaiVfModuleResources).updateContrailServiceInstanceFqdnVfModule(vfModule, genericVnf);
}
@Test
- public void updateContrailServiceInstanceFqdnVfModuleNoUpdateTest() throws Exception {
+ public void updateContrailServiceInstanceFqdnVfModuleNoUpdateTest() {
aaiUpdateTasks.updateContrailServiceInstanceFqdnVfModule(execution);
verify(aaiVfModuleResources, times(0)).updateContrailServiceInstanceFqdnVfModule(vfModule, genericVnf);
}
@Test
- public void updateIpv4OamAddressVnfTest() throws Exception {
+ public void updateIpv4OamAddressVnfTest() {
execution.setVariable("oamManagementV4Address", "newIpv4OamAddress");
doNothing().when(aaiVnfResources).updateObjectVnf(genericVnf);
}
@Test
- public void updateIpv4OamAddressVnfNoUpdateTest() throws Exception {
+ public void updateIpv4OamAddressVnfNoUpdateTest() {
aaiUpdateTasks.updateIpv4OamAddressVnf(execution);
verify(aaiVnfResources, times(0)).updateObjectVnf(genericVnf);
}
@Test
- public void updateManagementV6AddressVnfTest() throws Exception {
+ public void updateManagementV6AddressVnfTest() {
execution.setVariable("oamManagementV6Address", "newManagementV6Address");
doNothing().when(aaiVnfResources).updateObjectVnf(genericVnf);
}
@Test
- public void updateManagementV6AddressVnfNoUpdateTest() throws Exception {
+ public void updateManagementV6AddressVnfNoUpdateTest() {
aaiUpdateTasks.updateManagementV6AddressVnf(execution);
verify(aaiVnfResources, times(0)).updateObjectVnf(genericVnf);
}
@Test
- public void updateOrchestrationStatusVnfConfigureTest() throws Exception {
+ public void updateOrchestrationStatusVnfConfigureTest() {
doNothing().when(aaiVfModuleResources).updateOrchestrationStatusVfModule(vfModule, genericVnf,
OrchestrationStatus.CONFIGURE);
}
@Test
- public void updateOrchestrationStatusVnfConfiguredTest() throws Exception {
+ public void updateOrchestrationStatusVnfConfiguredTest() {
doNothing().when(aaiVfModuleResources).updateOrchestrationStatusVfModule(vfModule, genericVnf,
OrchestrationStatus.CONFIGURED);
}
@Test
- public void updateOrchestrationStatusVnfConfigAssignedTest() throws Exception {
+ public void updateOrchestrationStatusVnfConfigAssignedTest() {
doNothing().when(aaiVnfResources).updateOrchestrationStatusVnf(genericVnf, OrchestrationStatus.CONFIGASSIGNED);
aaiUpdateTasks.updateOrchestrationStatus(execution, "vnf", "config-assign");
}
@Test
- public void updateOrchestrationStatusVnfConfigDeployedTest() throws Exception {
+ public void updateOrchestrationStatusVnfConfigDeployedTest() {
doNothing().when(aaiVnfResources).updateOrchestrationStatusVnf(genericVnf, OrchestrationStatus.CONFIGDEPLOYED);
aaiUpdateTasks.updateOrchestrationStatus(execution, "vnf", "config-deploy");
}
@Test
- public void updateOrchestrationStatusVfModuleConfigDeployedTest() throws Exception {
+ public void updateOrchestrationStatusVfModuleConfigDeployedTest() {
doNothing().when(aaiVfModuleResources).updateOrchestrationStatusVfModule(vfModule, genericVnf,
OrchestrationStatus.CONFIGDEPLOYED);
aaiUpdateTasks.updateOrchestrationStatus(execution, "vfmodule", "config-deploy");
}
@Test
- public void updateOrchestrationStatusVfModuleConfigAssignedTest() throws Exception {
+ public void updateOrchestrationStatusVfModuleConfigAssignedTest() {
doNothing().when(aaiVfModuleResources).updateOrchestrationStatusVfModule(vfModule, genericVnf,
OrchestrationStatus.CONFIGASSIGNED);
aaiUpdateTasks.updateOrchestrationStatus(execution, "vfmodule", "config-assign");
import java.util.Optional;
import org.junit.Before;
import org.junit.Test;
+import org.junit.runner.RunWith;
import org.mockito.ArgumentMatchers;
import org.mockito.InjectMocks;
+import org.mockito.Mock;
+import org.mockito.junit.MockitoJUnitRunner;
import org.onap.so.adapters.nwrest.CreateNetworkRequest;
import org.onap.so.adapters.nwrest.CreateNetworkResponse;
-import org.onap.so.bpmn.BaseTaskTest;
+import org.onap.so.bpmn.common.data.TestDataSetup;
import org.onap.so.bpmn.servicedecomposition.bbobjects.CloudRegion;
import org.onap.so.bpmn.servicedecomposition.bbobjects.Customer;
import org.onap.so.bpmn.servicedecomposition.bbobjects.L3Network;
import org.onap.so.bpmn.servicedecomposition.entities.ResourceKey;
import org.onap.so.bpmn.servicedecomposition.generalobjects.OrchestrationContext;
import org.onap.so.bpmn.servicedecomposition.generalobjects.RequestContext;
+import org.onap.so.bpmn.servicedecomposition.tasks.ExtractPojosForBB;
+import org.onap.so.client.adapter.network.mapper.NetworkAdapterObjectMapper;
import org.onap.so.client.exception.BBObjectNotFoundException;
+import org.onap.so.client.orchestration.NetworkAdapterResources;
-public class NetworkAdapterCreateTasksTest extends BaseTaskTest {
+@RunWith(MockitoJUnitRunner.Silent.class)
+public class NetworkAdapterCreateTasksTest extends TestDataSetup {
+
+ @Mock
+ protected ExtractPojosForBB extractPojosForBB;
+ @Mock
+ protected NetworkAdapterObjectMapper networkAdapterObjectMapper;
+ @Mock
+ protected NetworkAdapterResources networkAdapterResources;
@InjectMocks
private NetworkAdapterCreateTasks networkAdapterCreateTasks = new NetworkAdapterCreateTasks();
}
@Test
- public void createNetworkTest() throws Exception {
+ public void createNetworkTest() {
String cloudRegionPo = "cloudRegionPo";
CreateNetworkRequest createNetworkRequest = new CreateNetworkRequest();
execution.setVariable("cloudRegionPo", cloudRegionPo);
import static org.mockito.Mockito.times;
import static org.mockito.Mockito.verify;
import static org.mockito.Mockito.when;
-import java.io.UnsupportedEncodingException;
import org.camunda.bpm.engine.delegate.BpmnError;
import org.junit.Before;
import org.junit.Test;
+import org.junit.runner.RunWith;
import org.mockito.ArgumentMatchers;
import org.mockito.InjectMocks;
import org.mockito.Mock;
+import org.mockito.junit.MockitoJUnitRunner;
import org.onap.so.adapters.nwrest.DeleteNetworkRequest;
-import org.onap.so.bpmn.BaseTaskTest;
import org.onap.so.bpmn.common.BuildingBlockExecution;
+import org.onap.so.bpmn.common.data.TestDataSetup;
import org.onap.so.bpmn.servicedecomposition.bbobjects.CloudRegion;
import org.onap.so.bpmn.servicedecomposition.bbobjects.L3Network;
import org.onap.so.bpmn.servicedecomposition.bbobjects.ServiceInstance;
import org.onap.so.bpmn.servicedecomposition.entities.ResourceKey;
import org.onap.so.bpmn.servicedecomposition.generalobjects.RequestContext;
-import org.onap.so.client.adapter.network.NetworkAdapterClientException;
+import org.onap.so.bpmn.servicedecomposition.tasks.ExtractPojosForBB;
+import org.onap.so.client.adapter.network.mapper.NetworkAdapterObjectMapper;
import org.onap.so.client.exception.BBObjectNotFoundException;
+import org.onap.so.client.exception.ExceptionBuilder;
+@RunWith(MockitoJUnitRunner.Silent.class)
+public class NetworkAdapterDeleteTasksTest extends TestDataSetup {
-public class NetworkAdapterDeleteTasksTest extends BaseTaskTest {
-
+ @Mock
+ protected ExtractPojosForBB extractPojosForBB;
+ @Mock
+ protected ExceptionBuilder exceptionUtil;
+ @Mock
+ protected NetworkAdapterObjectMapper networkAdapterObjectMapper;
@InjectMocks
private NetworkAdapterDeleteTasks networkAdapterDeleteTasks = new NetworkAdapterDeleteTasks();
}
@Test
- public void test_deleteNetwork() throws UnsupportedEncodingException, NetworkAdapterClientException {
+ public void test_deleteNetwork() {
DeleteNetworkRequest deleteNetworkRequest = new DeleteNetworkRequest();
doReturn(deleteNetworkRequest).when(networkAdapterObjectMapper).deleteNetworkRequestMapper(requestContext,
cloudRegion, serviceInstance, l3Network);
}
@Test
- public void test_deleteNetwork_exception() throws UnsupportedEncodingException, NetworkAdapterClientException {
+ public void test_deleteNetwork_exception() {
expectedException.expect(BpmnError.class);
doThrow(RuntimeException.class).when(networkAdapterObjectMapper).deleteNetworkRequestMapper(
import static org.junit.Assert.assertNotNull;
import javax.xml.bind.JAXBException;
import org.junit.Test;
+import org.junit.runner.RunWith;
import org.mockito.InjectMocks;
+import org.mockito.Mock;
+import org.mockito.junit.MockitoJUnitRunner;
import org.onap.so.FileUtil;
import org.onap.so.adapters.nwrest.CreateNetworkResponse;
-import org.onap.so.bpmn.BaseTaskTest;
+import org.onap.so.bpmn.common.data.TestDataSetup;
+import org.onap.so.bpmn.servicedecomposition.tasks.ExtractPojosForBB;
-public class NetworkAdapterImplTest extends BaseTaskTest {
+@RunWith(MockitoJUnitRunner.Silent.class)
+public class NetworkAdapterImplTest extends TestDataSetup {
+ @Mock
+ protected ExtractPojosForBB extractPojosForBB;
@InjectMocks
private NetworkAdapterImpl networkAdapterImpl = new NetworkAdapterImpl();
package org.onap.so.bpmn.infrastructure.adapter.network.tasks;
import static org.junit.Assert.assertEquals;
-import static org.junit.Assert.assertNull;
import static org.mockito.ArgumentMatchers.any;
-import static org.mockito.ArgumentMatchers.eq;
import static org.mockito.ArgumentMatchers.isA;
import static org.mockito.Mockito.doReturn;
-import static org.mockito.Mockito.doThrow;
import static org.mockito.Mockito.times;
import static org.mockito.Mockito.verify;
import static org.mockito.Mockito.when;
-import java.io.UnsupportedEncodingException;
import java.util.Map;
-import java.util.Optional;
-import org.camunda.bpm.engine.delegate.BpmnError;
import org.junit.Before;
import org.junit.Test;
+import org.junit.runner.RunWith;
import org.mockito.ArgumentMatchers;
import org.mockito.InjectMocks;
-import org.onap.so.adapters.nwrest.CreateNetworkRequest;
+import org.mockito.Mock;
+import org.mockito.junit.MockitoJUnitRunner;
import org.onap.so.adapters.nwrest.UpdateNetworkRequest;
-import org.onap.so.adapters.nwrest.UpdateNetworkResponse;
-import org.onap.so.bpmn.BaseTaskTest;
-import org.onap.so.bpmn.common.BuildingBlockExecution;
+import org.onap.so.bpmn.common.data.TestDataSetup;
import org.onap.so.bpmn.servicedecomposition.bbobjects.CloudRegion;
import org.onap.so.bpmn.servicedecomposition.bbobjects.Customer;
import org.onap.so.bpmn.servicedecomposition.bbobjects.L3Network;
import org.onap.so.bpmn.servicedecomposition.entities.ResourceKey;
import org.onap.so.bpmn.servicedecomposition.generalobjects.OrchestrationContext;
import org.onap.so.bpmn.servicedecomposition.generalobjects.RequestContext;
-import org.onap.so.client.adapter.network.NetworkAdapterClientException;
+import org.onap.so.bpmn.servicedecomposition.tasks.ExtractPojosForBB;
+import org.onap.so.client.adapter.network.mapper.NetworkAdapterObjectMapper;
import org.onap.so.client.exception.BBObjectNotFoundException;
-import org.springframework.beans.factory.annotation.Autowired;
-public class NetworkAdapterUpdateTasksTest extends BaseTaskTest {
+@RunWith(MockitoJUnitRunner.Silent.class)
+public class NetworkAdapterUpdateTasksTest extends TestDataSetup {
+ @Mock
+ protected ExtractPojosForBB extractPojosForBB;
+ @Mock
+ protected NetworkAdapterObjectMapper networkAdapterObjectMapper;
@InjectMocks
private NetworkAdapterUpdateTasks networkAdapterUpdateTasks = new NetworkAdapterUpdateTasks();
}
@Test
- public void updateNetworkTest() throws Exception {
+ public void updateNetworkTest() {
String cloudRegionPo = "cloudRegionPo";
UpdateNetworkRequest updateNetworkRequest = new UpdateNetworkRequest();
execution.setVariable("cloudRegionPo", cloudRegionPo);
import static org.mockito.Mockito.when;
import org.camunda.bpm.engine.delegate.BpmnError;
import org.junit.Test;
+import org.junit.runner.RunWith;
import org.mockito.ArgumentMatchers;
import org.mockito.InjectMocks;
+import org.mockito.Mock;
+import org.mockito.junit.MockitoJUnitRunner;
import org.onap.so.adapters.vnfrest.CreateVfModuleRequest;
import org.onap.so.adapters.vnfrest.CreateVolumeGroupRequest;
-import org.onap.so.bpmn.BaseTaskTest;
import org.onap.so.bpmn.common.BuildingBlockExecution;
+import org.onap.so.bpmn.common.data.TestDataSetup;
import org.onap.so.bpmn.servicedecomposition.bbobjects.CloudRegion;
import org.onap.so.bpmn.servicedecomposition.bbobjects.GenericVnf;
import org.onap.so.bpmn.servicedecomposition.bbobjects.ServiceInstance;
import org.onap.so.bpmn.servicedecomposition.entities.ResourceKey;
import org.onap.so.bpmn.servicedecomposition.generalobjects.OrchestrationContext;
import org.onap.so.bpmn.servicedecomposition.generalobjects.RequestContext;
+import org.onap.so.bpmn.servicedecomposition.tasks.ExtractPojosForBB;
+import org.onap.so.client.exception.ExceptionBuilder;
+import org.onap.so.client.orchestration.VnfAdapterVfModuleResources;
+import org.onap.so.client.orchestration.VnfAdapterVolumeGroupResources;
import org.onap.so.db.catalog.beans.OrchestrationStatus;
-public class VnfAdapterCreateTasksTest extends BaseTaskTest {
+@RunWith(MockitoJUnitRunner.Silent.class)
+public class VnfAdapterCreateTasksTest extends TestDataSetup {
+ @Mock
+ protected ExceptionBuilder exceptionUtil;
+ @Mock
+ protected ExtractPojosForBB extractPojosForBB;
+ @Mock
+ protected VnfAdapterVolumeGroupResources vnfAdapterVolumeGroupResources;
+ @Mock
+ protected VnfAdapterVfModuleResources vnfAdapterVfModuleResources;
@InjectMocks
private VnfAdapterCreateTasks vnfAdapterCreateTasks = new VnfAdapterCreateTasks();
import org.camunda.bpm.engine.delegate.BpmnError;
import org.junit.Before;
import org.junit.Test;
+import org.junit.runner.RunWith;
import org.mockito.ArgumentMatchers;
import org.mockito.InjectMocks;
+import org.mockito.Mock;
+import org.mockito.junit.MockitoJUnitRunner;
import org.onap.so.adapters.vnfrest.DeleteVfModuleRequest;
import org.onap.so.adapters.vnfrest.DeleteVolumeGroupRequest;
-import org.onap.so.bpmn.BaseTaskTest;
import org.onap.so.bpmn.common.BuildingBlockExecution;
+import org.onap.so.bpmn.common.data.TestDataSetup;
import org.onap.so.bpmn.servicedecomposition.bbobjects.CloudRegion;
import org.onap.so.bpmn.servicedecomposition.bbobjects.GenericVnf;
import org.onap.so.bpmn.servicedecomposition.bbobjects.ServiceInstance;
import org.onap.so.bpmn.servicedecomposition.entities.ResourceKey;
import org.onap.so.bpmn.servicedecomposition.generalobjects.OrchestrationContext;
import org.onap.so.bpmn.servicedecomposition.generalobjects.RequestContext;
-
-public class VnfAdapterDeleteTasksTest extends BaseTaskTest {
+import org.onap.so.bpmn.servicedecomposition.tasks.ExtractPojosForBB;
+import org.onap.so.client.exception.ExceptionBuilder;
+import org.onap.so.client.orchestration.VnfAdapterVfModuleResources;
+import org.onap.so.client.orchestration.VnfAdapterVolumeGroupResources;
+
+@RunWith(MockitoJUnitRunner.Silent.class)
+public class VnfAdapterDeleteTasksTest extends TestDataSetup {
+
+ @Mock
+ protected ExceptionBuilder exceptionUtil;
+ @Mock
+ protected ExtractPojosForBB extractPojosForBB;
+ @Mock
+ protected VnfAdapterVfModuleResources vnfAdapterVfModuleResources;
+ @Mock
+ protected VnfAdapterVolumeGroupResources vnfAdapterVolumeGroupResources;
@InjectMocks
private VnfAdapterDeleteTasks vnfAdapterDeleteTasks = new VnfAdapterDeleteTasks();
import org.camunda.bpm.engine.delegate.BpmnError;
import org.junit.Before;
import org.junit.Test;
+import org.junit.runner.RunWith;
import org.mockito.ArgumentMatchers;
import org.mockito.InjectMocks;
+import org.mockito.Mock;
+import org.mockito.junit.MockitoJUnitRunner;
import org.onap.so.FileUtil;
-import org.onap.so.bpmn.BaseTaskTest;
import org.onap.so.bpmn.common.BuildingBlockExecution;
+import org.onap.so.bpmn.common.data.TestDataSetup;
import org.onap.so.bpmn.servicedecomposition.bbobjects.GenericVnf;
import org.onap.so.bpmn.servicedecomposition.bbobjects.ServiceInstance;
import org.onap.so.bpmn.servicedecomposition.bbobjects.VfModule;
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.bpmn.servicedecomposition.tasks.ExtractPojosForBB;
import org.onap.so.client.exception.BBObjectNotFoundException;
-import org.springframework.beans.factory.annotation.Autowired;
-
-public class VnfAdapterImplTest extends BaseTaskTest {
-
+import org.onap.so.client.exception.ExceptionBuilder;
+
+@RunWith(MockitoJUnitRunner.Silent.class)
+public class VnfAdapterImplTest extends TestDataSetup {
+ @Mock
+ protected ExceptionBuilder exceptionUtil;
+ @Mock
+ protected ExtractPojosForBB extractPojosForBB;
@InjectMocks
private VnfAdapterImpl vnfAdapterImpl = new VnfAdapterImpl();
execution.setVariable("WorkflowResponse", VNF_ADAPTER_REST_DELETE_RESPONSE);
vnfAdapterImpl.postProcessVnfAdapter(execution);
assertNull(vfModule.getHeatStackId());
- assertEquals(vfModule.getContrailServiceInstanceFqdn(), "");
- assertEquals(execution.getVariable("contrailServiceInstanceFqdn"), "");
- assertEquals(genericVnf.getIpv4OamAddress(), "");
- assertEquals(execution.getVariable("oamManagementV4Address"), "");
- assertEquals(genericVnf.getManagementV6Address(), "");
- assertEquals(execution.getVariable("oamManagementV6Address"), "");
+ assertEquals("", vfModule.getContrailServiceInstanceFqdn());
+ assertEquals("", execution.getVariable("contrailServiceInstanceFqdn"));
+ assertEquals("", genericVnf.getIpv4OamAddress());
+ assertEquals("", execution.getVariable("oamManagementV4Address"));
+ assertEquals("", genericVnf.getManagementV6Address());
+ assertEquals("", execution.getVariable("oamManagementV6Address"));
assertEquals(TEST_CONTRAIL_NETWORK_POLICY_FQDNS, execution.getVariable("contrailNetworkPolicyFqdnList"));
}
import java.util.ArrayList;
import java.util.Optional;
import org.junit.Test;
+import org.junit.runner.RunWith;
import org.mockito.ArgumentMatchers;
import org.mockito.InjectMocks;
+import org.mockito.Mock;
+import org.mockito.junit.MockitoJUnitRunner;
import org.onap.aai.domain.yang.Vserver;
import org.onap.appc.client.lcm.model.Action;
import org.onap.so.appc.orchestrator.service.beans.ApplicationControllerTaskRequest;
import org.onap.so.appc.orchestrator.service.beans.ApplicationControllerVnf;
-import org.onap.so.bpmn.BaseTaskTest;
+import org.onap.so.bpmn.common.data.TestDataSetup;
import org.onap.so.bpmn.servicedecomposition.bbobjects.GenericVnf;
import org.onap.so.bpmn.servicedecomposition.bbobjects.VfModule;
import org.onap.so.bpmn.servicedecomposition.entities.ResourceKey;
import org.onap.so.bpmn.servicedecomposition.generalobjects.RequestParameters;
import org.onap.aaiclient.client.aai.entities.AAIResultWrapper;
import org.onap.aaiclient.client.aai.entities.uri.AAIResourceUri;
+import org.onap.so.bpmn.servicedecomposition.tasks.ExtractPojosForBB;
+import org.onap.so.client.orchestration.AAIVnfResources;
import org.onap.so.client.policy.JettisonStyleMapperProvider;
import org.onap.so.db.catalog.beans.ControllerSelectionReference;
import com.fasterxml.jackson.databind.ObjectMapper;
+import org.onap.so.db.catalog.client.CatalogDbClient;
-public class AppcOrchestratorPreProcessorTest extends BaseTaskTest {
+@RunWith(MockitoJUnitRunner.Silent.class)
+public class AppcOrchestratorPreProcessorTest extends TestDataSetup {
private final static String JSON_FILE_LOCATION = "src/test/resources/__files/BuildingBlocks/";
-
+ @Mock
+ protected ExtractPojosForBB extractPojosForBB;
+ @Mock
+ protected AAIVnfResources aaiVnfResources;
+ @Mock
+ protected CatalogDbClient catalogDbClient;
@InjectMocks
private AppcOrchestratorPreProcessor appcOrchestratorPreProcessor = new AppcOrchestratorPreProcessor();
}
@Test
- public void addVmInfoToAppcTaskRequestTest() throws Exception {
+ public void addVmInfoToAppcTaskRequestTest() {
ApplicationControllerTaskRequest appcTaskRequest = new ApplicationControllerTaskRequest();
ApplicationControllerVnf applicationControllerVnf = new ApplicationControllerVnf();
appcTaskRequest.setApplicationControllerVnf(applicationControllerVnf);
import java.util.Map;
import java.util.Optional;
import org.junit.Test;
+import org.junit.runner.RunWith;
import org.mockito.InjectMocks;
+import org.mockito.Mock;
+import org.mockito.junit.MockitoJUnitRunner;
import org.onap.aai.domain.yang.Vserver;
import org.onap.appc.client.lcm.model.Action;
-import org.onap.so.bpmn.BaseTaskTest;
import org.onap.so.bpmn.common.BuildingBlockExecution;
+import org.onap.so.bpmn.common.data.TestDataSetup;
import org.onap.so.bpmn.servicedecomposition.bbobjects.GenericVnf;
import org.onap.so.bpmn.servicedecomposition.bbobjects.VfModule;
import org.onap.so.bpmn.servicedecomposition.entities.ResourceKey;
import org.onap.so.bpmn.servicedecomposition.generalobjects.RequestContext;
import org.onap.aaiclient.client.aai.entities.AAIResultWrapper;
import org.onap.aaiclient.client.aai.entities.uri.AAIResourceUri;
+import org.onap.so.bpmn.servicedecomposition.tasks.ExtractPojosForBB;
+import org.onap.so.client.appc.ApplicationControllerAction;
import org.onap.so.client.exception.BBObjectNotFoundException;
+import org.onap.so.client.exception.ExceptionBuilder;
+import org.onap.so.client.orchestration.AAIVnfResources;
import org.onap.so.db.catalog.beans.ControllerSelectionReference;
import com.fasterxml.jackson.databind.ObjectMapper;
+import org.onap.so.db.catalog.client.CatalogDbClient;
-public class AppcRunTasksTest extends BaseTaskTest {
+@RunWith(MockitoJUnitRunner.Silent.class)
+public class AppcRunTasksTest extends TestDataSetup {
private final static String JSON_FILE_LOCATION = "src/test/resources/__files/BuildingBlocks/";
-
+ @Mock
+ protected ExtractPojosForBB extractPojosForBB;
+ @Mock
+ protected CatalogDbClient catalogDbClient;
+ @Mock
+ protected ExceptionBuilder exceptionUtil;
+ @Mock
+ protected ApplicationControllerAction appCClient;
+ @Mock
+ protected AAIVnfResources aaiVnfResources;
@InjectMocks
private AppcRunTasks appcRunTasks = new AppcRunTasks();
}
@Test
- public void testUserParams() throws Exception {
+ public void testUserParams() {
Map<String, Object> userParams = new HashMap<String, Object>();
userParams.put("existing_software_version", "3.1");
userParams.put("new_software_version", "3.2");
healthCheck,
addMembers,
removeMembers,
- forCustomWorkflow
+ forCustomWorkflow,
+ upgradeCnf
}
requestHandlerUtils.getRequestUri(requestContext, uriPrefix));
}
+ @POST
+ @Path("/{version:[vV][5-7]}/serviceInstances/{serviceInstanceId}/vnfs/{vnfInstanceId}/upgradeCnf")
+ @Consumes(MediaType.APPLICATION_JSON)
+ @Produces(MediaType.APPLICATION_JSON)
+ @Operation(description = "Upgrade CNF instance", responses = @ApiResponse(
+ content = @Content(array = @ArraySchema(schema = @Schema(implementation = Response.class)))))
+ @Transactional
+ public Response cnfUpgrade(String request, @PathParam("version") String version,
+ @PathParam("serviceInstanceId") String serviceInstanceId, @PathParam("vnfInstanceId") String vnfInstanceId,
+ @Context ContainerRequestContext requestContext) throws ApiException {
+ String requestId = requestHandlerUtils.getRequestId(requestContext);
+ HashMap<String, String> instanceIdMap = new HashMap<>();
+ instanceIdMap.put("serviceInstanceId", serviceInstanceId);
+ instanceIdMap.put("vnfInstanceId", vnfInstanceId);
+ return serviceInstances(request, Action.upgradeCnf, instanceIdMap, version, requestId,
+ requestHandlerUtils.getRequestUri(requestContext, uriPrefix));
+ }
+
@PUT
@Path("/{version:[vV][5-7]}/serviceInstances/{serviceInstanceId}/vnfs/{vnfInstanceId}")
@Consumes(MediaType.APPLICATION_JSON)
import static org.apache.commons.lang3.StringUtils.*;
-import java.util.LinkedHashMap;
+import java.util.Map;
import org.json.JSONObject;
import org.onap.so.client.exception.BadResponseException;
import org.slf4j.Logger;
private static final Logger logger = LoggerFactory.getLogger(SniroValidator.class);
+ private static final String MESSAGE_NOT_PROVIDED = "error message not provided";
+
/**
* Validates the synchronous homing response from sniro manager
*
* @throws BadResponseException
*/
- public void validateDemandsResponse(LinkedHashMap<String, Object> response) throws BadResponseException {
+ public void validateDemandsResponse(Map<String, Object> response) throws BadResponseException {
logger.debug("Validating Sniro Managers synchronous response");
if (!response.isEmpty()) {
JSONObject jsonResponse = new JSONObject(response);
} else {
String message = jsonResponse.getString("statusMessage");
if (isNotBlank(message)) {
- logger.debug("Sniro Managers response indicates failed: " + message);
+ logger.debug("Sniro Managers response indicates failed: {}", message);
} else {
logger.debug("Sniro Managers response indicates failed: no status message provided");
- message = "error message not provided";
+ message = MESSAGE_NOT_PROVIDED;
}
throw new BadResponseException("Sniro Managers synchronous response indicates failed: " + message);
}
}
} else {
logger.debug("Sniro Managers synchronous response is empty");
- throw new BadResponseException("Sniro Managers synchronous response i is empty");
+ throw new BadResponseException("Sniro Managers synchronous response is empty");
}
}
} else {
String message = jsonResponse.getJSONObject("serviceException").getString("text");
if (isNotBlank(message)) {
- logger.debug("Sniro Managers response contains a service exception: " + message);
+ logger.debug("Sniro Managers response contains a service exception: {}", message);
} else {
logger.debug(
"Sniro Managers response contains a service exception: no service exception text provided");
- message = "error message not provided";
+ message = MESSAGE_NOT_PROVIDED;
}
throw new BadResponseException(
"Sniro Managers asynchronous response contains a service exception: " + message);
*
* @throws BadResponseException
*/
- public void validateReleaseResponse(LinkedHashMap<String, Object> response) throws BadResponseException {
+ public void validateReleaseResponse(Map<String, Object> response) throws BadResponseException {
logger.debug("Validating Sniro Conductors response");
if (!response.isEmpty()) {
String status = (String) response.get("status");
} else {
String message = (String) response.get("message");
if (isNotBlank(message)) {
- logger.debug("Sniro Conductors response indicates failed: " + message);
+ logger.debug("Sniro Conductors response indicates failed: {}", message);
} else {
logger.debug("Sniro Conductors response indicates failed: error message not provided");
- message = "error message not provided";
+ message = MESSAGE_NOT_PROVIDED;
}
throw new BadResponseException(
"Sniro Conductors synchronous response indicates failed: " + message);
--- /dev/null
+package org.onap.so.client.sniro;
+
+import static org.assertj.core.api.Assertions.assertThat;
+import java.util.LinkedHashMap;
+import java.util.Map;
+import org.junit.Test;
+import org.onap.so.client.exception.BadResponseException;
+
+public class SniroValidatorTest {
+
+ @Test
+ public void validateDemandsResponse_success() throws BadResponseException {
+ Map<String, Object> testMap = new LinkedHashMap<>();
+ testMap.put("requestStatus", "accepted");
+ new SniroValidator().validateDemandsResponse(testMap);
+ }
+
+ @Test
+ public void validateDemandsResponse_emptyResponse() {
+ try {
+ new SniroValidator().validateDemandsResponse(new LinkedHashMap<>());
+ } catch (BadResponseException e) {
+ assertThat(e.getMessage()).contains("Sniro Managers synchronous response is empty");
+ }
+ }
+
+ @Test
+ public void validateDemandsResponse_responseWithErrorMessage() {
+ String message = "An error occurred";
+ Map<String, Object> testMap = new LinkedHashMap<>();
+ testMap.put("requestStatus", "not_accepted");
+ testMap.put("statusMessage", message);
+ try {
+ new SniroValidator().validateDemandsResponse(testMap);
+ } catch (BadResponseException e) {
+ assertThat(e.getMessage()).contains("Sniro Managers synchronous response indicates failed: " + message);
+ }
+ }
+
+ @Test
+ public void validateDemandsResponse_responseWithoutMessage() {
+ Map<String, Object> testMap = new LinkedHashMap<>();
+ testMap.put("requestStatus", "not_accepted");
+ testMap.put("statusMessage", "");
+ try {
+ new SniroValidator().validateDemandsResponse(testMap);
+ } catch (BadResponseException e) {
+ assertThat(e.getMessage()).contains("error message not provided");
+ }
+ }
+
+ @Test
+ public void validateDemandsResponse_responseWithoutRequestStatus() {
+ Map<String, Object> testMap = new LinkedHashMap<>();
+ testMap.put("statusMessage", "");
+ try {
+ new SniroValidator().validateDemandsResponse(testMap);
+ } catch (BadResponseException e) {
+ assertThat(e.getMessage()).contains("Sniro Managers synchronous response does not contain: request status");
+ }
+ }
+
+ @Test
+ public void validateSolution_success() throws BadResponseException {
+ SniroValidator.validateSolution("{statusMessage:key}");
+ }
+
+ @Test
+ public void validateSolution_emptyResponse() {
+ try {
+ SniroValidator.validateSolution("");
+ } catch (BadResponseException e) {
+ assertThat(e.getMessage()).contains("Sniro Managers asynchronous response is empty");
+ }
+ }
+
+ @Test
+ public void validateSolution_errorResponseWithoutMessage() {
+ try {
+ SniroValidator.validateSolution("{\"serviceException\":{\"text\":\"\"}}");
+ } catch (BadResponseException e) {
+ assertThat(e.getMessage()).contains(
+ "Sniro Managers asynchronous response contains a service exception: error message not provided");
+ }
+ }
+
+ @Test
+ public void validateSolution_errorResponseWithErrorMessage() {
+ String message = "An error occurred";
+ try {
+ SniroValidator.validateSolution("{\"serviceException\":{\"text\":\"" + message + "\"}}");
+ } catch (BadResponseException e) {
+ assertThat(e.getMessage())
+ .contains("Sniro Managers asynchronous response contains a service exception: " + message);
+ }
+ }
+
+ @Test
+ public void validateReleaseResponse_success() throws BadResponseException {
+ Map<String, Object> testMap = new LinkedHashMap<>();
+ testMap.put("status", "success");
+ new SniroValidator().validateReleaseResponse(testMap);
+ }
+
+ @Test
+ public void validateReleaseResponse_emptyResponse() {
+ try {
+ new SniroValidator().validateReleaseResponse(new LinkedHashMap<>());
+ } catch (BadResponseException e) {
+ assertThat(e.getMessage()).contains("Sniro Conductors response is empty");
+ }
+ }
+
+ @Test
+ public void validateReleaseResponse_errorResponseWithErrorMessage() {
+ String message = "An error occurred";
+ Map<String, Object> testMap = new LinkedHashMap<>();
+ testMap.put("status", "failed");
+ testMap.put("message", message);
+ try {
+ new SniroValidator().validateReleaseResponse(testMap);
+ } catch (BadResponseException e) {
+ assertThat(e.getMessage()).contains("Sniro Conductors synchronous response indicates failed: " + message);
+ }
+ }
+
+ @Test
+ public void validateReleaseResponse_errorResponseWithNoMessage() {
+ Map<String, Object> testMap = new LinkedHashMap<>();
+ testMap.put("status", "failed");
+ testMap.put("message", "");
+ try {
+ new SniroValidator().validateReleaseResponse(testMap);
+ } catch (BadResponseException e) {
+ assertThat(e.getMessage())
+ .contains("Sniro Conductors synchronous response indicates failed: error message not provided");
+ }
+ }
+
+ @Test
+ public void validateReleaseResponse_responseWithoutStatus() {
+ Map<String, Object> testMap = new LinkedHashMap<>();
+ testMap.put("statusMessage", "");
+ try {
+ new SniroValidator().validateReleaseResponse(testMap);
+ } catch (BadResponseException e) {
+ assertThat(e.getMessage()).contains("Sniro Conductors synchronous response does not contain: status");
+ }
+ }
+}
# because they are used in Jenkins, whose plug-in doesn't support
major=1
-minor=9
-patch=2
+minor=10
+patch=0
base_version=${major}.${minor}.${patch}