From 8fa2659ec0f0b94f22f5caa5d7e61048be18068c Mon Sep 17 00:00:00 2001 From: c00149107 Date: Mon, 23 Apr 2018 11:37:23 +0800 Subject: Update response for delete e2e service Update response for delete e2e service Change-Id: I8cd96981e085111e55211e8a24cb3b2cebe7ef9a Issue-ID: SO-587 Signed-off-by: c00149107 --- .../scripts/DeleteCustomE2EServiceInstance.groovy | 16 +++++++--------- .../resources/subprocess/DoDeleteE2EServiceInstance.bpmn | 10 +++++++++- 2 files changed, 16 insertions(+), 10 deletions(-) (limited to 'bpmn/MSOInfrastructureBPMN') diff --git a/bpmn/MSOInfrastructureBPMN/src/main/groovy/org/openecomp/mso/bpmn/infrastructure/scripts/DeleteCustomE2EServiceInstance.groovy b/bpmn/MSOInfrastructureBPMN/src/main/groovy/org/openecomp/mso/bpmn/infrastructure/scripts/DeleteCustomE2EServiceInstance.groovy index d218adc279..ebf9ae7825 100644 --- a/bpmn/MSOInfrastructureBPMN/src/main/groovy/org/openecomp/mso/bpmn/infrastructure/scripts/DeleteCustomE2EServiceInstance.groovy +++ b/bpmn/MSOInfrastructureBPMN/src/main/groovy/org/openecomp/mso/bpmn/infrastructure/scripts/DeleteCustomE2EServiceInstance.groovy @@ -73,9 +73,9 @@ public class DeleteCustomE2EServiceInstance extends AbstractServiceTaskProcessor String requestId = execution.getVariable("mso-request-id") - execution.setVariable("msoRequestId", requestId) + execution.setVariable("msoRequestId", requestId) utils.log("INFO", "Input Request:" + siRequest + " reqId:" + requestId, isDebugEnabled) - + String serviceInstanceId = execution.getVariable("serviceInstanceId") if (isBlank(serviceInstanceId)) { msg = "Input serviceInstanceId' is null" @@ -114,7 +114,9 @@ public class DeleteCustomE2EServiceInstance extends AbstractServiceTaskProcessor } else { execution.setVariable("subscriptionServiceType", subscriptionServiceType) } - + String operationId = jsonUtil.getJsonValue(siRequest, "operationId") + execution.setVariable("operationId", operationId) + execution.setVariable("operationType", "DELETE") } catch (BpmnError e) { throw e; @@ -129,13 +131,9 @@ public class DeleteCustomE2EServiceInstance extends AbstractServiceTaskProcessor public void sendSyncResponse (DelegateExecution execution) { def isDebugEnabled=execution.getVariable("isDebugLogEnabled") utils.log("INFO", " *** sendSyncResponse *** ", isDebugEnabled) - try { - String requestId = execution.getVariable("msoRequestId") - String serviceInstanceId = execution.getVariable("serviceInstanceId") - - // RESTResponse (for API Handler (APIH) Reply Task) - String syncResponse = """{"requestReferences":{"instanceId":"${serviceInstanceId}","requestId":"${requestId}"}}""".trim() + String operationId = execution.getVariable("operationId") + String syncResponse = """{"operationId":"${operationId}"}""".trim() utils.log("INFO", " sendSynchResponse: xmlSyncResponse - " + "\n" + syncResponse, isDebugEnabled) sendWorkflowResponse(execution, 202, syncResponse) diff --git a/bpmn/MSOInfrastructureBPMN/src/main/resources/subprocess/DoDeleteE2EServiceInstance.bpmn b/bpmn/MSOInfrastructureBPMN/src/main/resources/subprocess/DoDeleteE2EServiceInstance.bpmn index 20686252bd..8a3d441a8e 100644 --- a/bpmn/MSOInfrastructureBPMN/src/main/resources/subprocess/DoDeleteE2EServiceInstance.bpmn +++ b/bpmn/MSOInfrastructureBPMN/src/main/resources/subprocess/DoDeleteE2EServiceInstance.bpmn @@ -1,5 +1,5 @@ - + SequenceFlow_0vz7cd9 @@ -165,6 +165,7 @@ dcsi.postDecomposeService(execution)]]> + SequenceFlow_1j08ko3 SequenceFlow_1cevtpy @@ -180,6 +181,10 @@ dcsi.postDecomposeService(execution)]]> + + @@ -398,6 +403,9 @@ dcsi.postDecomposeService(execution)]]> + + + -- cgit 1.2.3-korg