From 8e3b16a64b98b1774c4e2c2159e71668de2883c4 Mon Sep 17 00:00:00 2001 From: Wojciech Sliwka Date: Thu, 21 Mar 2019 14:01:50 +0100 Subject: align logic to new so api Change-Id: Ic1a975eb6d3d9487fc2e006d2f171fa044806ef3 Issue-ID: VID-400 Signed-off-by: Wojciech Sliwka --- .../get_workflows_by_model_id.json | 106 +++++++++++++++++++++ .../changeManagement/mso_invoke_workflow01.json | 10 +- .../changeManagement/mso_invoke_workflow02.json | 28 ------ .../changeManagement/mso_invoke_workflow03.json | 29 ------ 4 files changed, 113 insertions(+), 60 deletions(-) create mode 100644 vid-ext-services-simulator/src/main/resources/preset_registration/changeManagement/get_workflows_by_model_id.json delete mode 100644 vid-ext-services-simulator/src/main/resources/preset_registration/changeManagement/mso_invoke_workflow02.json delete mode 100644 vid-ext-services-simulator/src/main/resources/preset_registration/changeManagement/mso_invoke_workflow03.json (limited to 'vid-ext-services-simulator/src/main') diff --git a/vid-ext-services-simulator/src/main/resources/preset_registration/changeManagement/get_workflows_by_model_id.json b/vid-ext-services-simulator/src/main/resources/preset_registration/changeManagement/get_workflows_by_model_id.json new file mode 100644 index 000000000..d26d07b93 --- /dev/null +++ b/vid-ext-services-simulator/src/main/resources/preset_registration/changeManagement/get_workflows_by_model_id.json @@ -0,0 +1,106 @@ +{ + "simulatorRequest": { + "method": "GET", + "path": "/workflowSpecifications/v1/workflows", + "queryParams" : { + "vnfModelVersionId": "103b4a1b-4a15-4559-a019-1ff132180c7c" + } + } , + "simulatorResponse": { + "responseCode": 200, + "body": { + "workflowSpecificationList": [{ + "workflowSpecification": { + "artifactInfo": { + "artifactType": "workflow", + "artifactUuid": "ab6478e4-ea33-3346-ac12-ab121484a333", + "artifactName": "inPlaceSoftwareUpdate-1_0.bpmn", + "artifactVersion": "1.0", + "artifactDescription": "xyz xyz", + "workflowName": "inPlaceSoftwareUpdate", + "operationName": "inPlaceSoftwareUpdate", + "workflowSource": "sdc", + "workflowResourceTarget": "vnf" + }, + "activitySequence": [{ + "name": "VNFQuiesceTrafficActivity", + "description": "Activity to QuiesceTraffic on VNF" + }, + { + "name": "VNFHealthCheckActivity", + "description": "Activity to HealthCheck VNF" + }, + { + "name": "FlowCompleteActivity", + "description": "Activity to Complete the BPMN Flow" + } + ], + "workflowInputParameters": [{ + "label": "Cloud Owner", + "inputType": "text", + "required": true, + "validation": [{ + "maxLength": "7", + "allowableChars": "[a-zA-Z0-9]*" + }], + "soFieldName": "cloudOwner", + "soPayloadLocation": "cloudConfiguration" + }, + { + "label": "Cloud Region ID", + "inputType": "text", + "required": true, + "validation": [{ + "maxLength": "7", + "allowableChars": "[a-zA-Z0-9]*" + }], + "soFieldName": "lcpCloudRegionId", + "soPayloadLocation": "cloudConfiguration" + }, + { + "label": "Tenant/Project ID", + "inputType": "text", + "required": true, + "validation": [{ + "maxLength": "36", + "allowableChars": "[a-zA-Z0-9]*" + }], + "soFieldName": "tenantId", + "soPayloadLocation": "cloudConfiguration" + }, + { + "label": "Operations Timeout", + "inputType": "text", + "required": true, + "description": "some description", + "validation": [{ + "maxLength": "50", + "allowableChars": "[a-zA-Z0-9]*" + }], + "soFieldName": "operations_timeout", + "soPayloadLocation": "userParams" + }, + { + "label": "Existing Software Version", + "inputType": "text", + "required": true, + "validation": [{ + "maxLength": "50", + "allowableChars": "[a-zA-Z0-9]*" + }], + "soFieldName": "existing_software_version", + "soPayloadLocation": "userParams" + }, + { + "label": "New Software Version", + "inputType": "text", + "required": true, + "soFieldName": "new_software_version", + "soPayloadLocation": "userParams" + } + ] + } + }] + } + } +} diff --git a/vid-ext-services-simulator/src/main/resources/preset_registration/changeManagement/mso_invoke_workflow01.json b/vid-ext-services-simulator/src/main/resources/preset_registration/changeManagement/mso_invoke_workflow01.json index 94fc543b6..afbfde207 100644 --- a/vid-ext-services-simulator/src/main/resources/preset_registration/changeManagement/mso_invoke_workflow01.json +++ b/vid-ext-services-simulator/src/main/resources/preset_registration/changeManagement/mso_invoke_workflow01.json @@ -11,7 +11,9 @@ "requestParameters": { "userParams": [ { - "[FIRST]parameter 1": "011" + "operations_timeout": "a", + "existing_software_version": "a", + "new_software_version": "a" } ] } @@ -21,7 +23,9 @@ "simulatorResponse": { "responseCode": 200, "body": { - "inf": "workflow 1 invoked" + "requestId": "ff3514e3-5a33-55df-13ab-12abad84e7ff", + "instanceId": "078046c2-d624-4480-a11d-b92f1fb40be5", + "requestSelfLink": "https://mso-apih-dev1-s1.ecomp.idns.cip.att.com:30251/onap/so/infra/orchestrationRequests/v7/ff3514e3-5a33-55df-13ab-12abad84e7ff" } } -} \ No newline at end of file +} diff --git a/vid-ext-services-simulator/src/main/resources/preset_registration/changeManagement/mso_invoke_workflow02.json b/vid-ext-services-simulator/src/main/resources/preset_registration/changeManagement/mso_invoke_workflow02.json deleted file mode 100644 index f5018f557..000000000 --- a/vid-ext-services-simulator/src/main/resources/preset_registration/changeManagement/mso_invoke_workflow02.json +++ /dev/null @@ -1,28 +0,0 @@ -{ - "simulatorRequest": { - "method" : "POST", - "path" : "/onap/so/infra/instanceManagement/v1/serviceInstances/[a-fA-F0-9-]*/vnfs/[a-fA-F0-9-]*/workflows/[a-fA-F0-9-]*", - "body" : { - "requestDetails": { - "cloudConfiguration": { - "lcpCloudRegionId": "RegionOne", - "tenantId": "982c540f6e69488eb6be5664255e00c0" - }, - "requestParameters": { - "userParams": [ - { - "[SECOND] parameter 2": "022", - "[SECOND] parameter 1": "021" - } - ] - } - } - } - }, - "simulatorResponse": { - "responseCode": 200, - "body": { - "inf": "workflow 2 invoked" - } - } -} \ No newline at end of file diff --git a/vid-ext-services-simulator/src/main/resources/preset_registration/changeManagement/mso_invoke_workflow03.json b/vid-ext-services-simulator/src/main/resources/preset_registration/changeManagement/mso_invoke_workflow03.json deleted file mode 100644 index a9daa7cf9..000000000 --- a/vid-ext-services-simulator/src/main/resources/preset_registration/changeManagement/mso_invoke_workflow03.json +++ /dev/null @@ -1,29 +0,0 @@ -{ - "simulatorRequest": { - "method" : "POST", - "path" : "/onap/so/infra/instanceManagement/v1/serviceInstances/[a-fA-F0-9-]*/vnfs/[a-fA-F0-9-]*/workflows/[a-fA-F0-9-]*", - "body" : { - "requestDetails": { - "cloudConfiguration": { - "lcpCloudRegionId": "RegionOne", - "tenantId": "982c540f6e69488eb6be5664255e00c0" - }, - "requestParameters": { - "userParams": [ - { - "[THIRD] parameter 3": "033", - "[THIRD] parameter 2": "test", - "[THIRD] parameter 1": "031" - } - ] - } - } - } - }, - "simulatorResponse": { - "responseCode": 200, - "body": { - "inf": "workflow 3 invoked" - } - } -} \ No newline at end of file -- cgit 1.2.3-korg