aboutsummaryrefslogtreecommitdiffstats
path: root/mso-api-handlers/mso-api-handler-infra/src/main/java
diff options
context:
space:
mode:
authorYulian Han <elaine.hanyulian@huawei.com>2018-04-19 11:03:35 +0800
committerYulian Han <elaine.hanyulian@huawei.com>2018-04-19 11:03:35 +0800
commit38d65a0371f6d638537e0c76fd72a3ec9b483434 (patch)
tree0b482d1046eaf1416e8b84a6c17f7d29c09fbb97 /mso-api-handlers/mso-api-handler-infra/src/main/java
parentd631e30d8198a74ce938e11cbd2da7b0f55f5d2b (diff)
E2EServiceInstance Update API bugs fix
Change-Id: Idaa55084f5ecb0dd3636c232cebc14fa5f064300 Issue-ID: SO-578 Signed-off-by: Yulian Han <elaine.hanyulian@huawei.com>
Diffstat (limited to 'mso-api-handlers/mso-api-handler-infra/src/main/java')
-rw-r--r--mso-api-handlers/mso-api-handler-infra/src/main/java/org/openecomp/mso/apihandlerinfra/E2EServiceInstances.java10
1 files changed, 5 insertions, 5 deletions
diff --git a/mso-api-handlers/mso-api-handler-infra/src/main/java/org/openecomp/mso/apihandlerinfra/E2EServiceInstances.java b/mso-api-handlers/mso-api-handler-infra/src/main/java/org/openecomp/mso/apihandlerinfra/E2EServiceInstances.java
index 08fe0f856b..8d3a64340d 100644
--- a/mso-api-handlers/mso-api-handler-infra/src/main/java/org/openecomp/mso/apihandlerinfra/E2EServiceInstances.java
+++ b/mso-api-handlers/mso-api-handler-infra/src/main/java/org/openecomp/mso/apihandlerinfra/E2EServiceInstances.java
@@ -533,7 +533,7 @@ public class E2EServiceInstances {
private Response updateE2EserviceInstances(String requestJSON, Action action,
HashMap<String, String> instanceIdMap, String version) {
- String requestId = instanceIdMap.get("serviceId");
+ String requestId = UUIDChecker.generateUUID(msoLogger);
long startTime = System.currentTimeMillis();
msoLogger.debug("requestId is: " + requestId);
E2EServiceInstanceRequest e2eSir = null;
@@ -627,7 +627,7 @@ public class E2EServiceInstances {
String serviceInstanceType = e2eSir.getService().getServiceType();
- String serviceId = "";
+ String serviceId = instanceIdMap.get("serviceId");
RequestClient requestClient = null;
HttpResponse response = null;
@@ -675,6 +675,7 @@ public class E2EServiceInstances {
msoLogger.recordAuditEvent(startTime, MsoLogger.StatusCode.ERROR, MsoLogger.ResponseCode.InternalError,
"Null response from BPMN");
msoLogger.debug(END_OF_THE_TRANSACTION + (String) getBPMNResp.getEntity());
+ this.createOperationStatusRecordForError(action, requestId);
return getBPMNResp;
}
@@ -707,9 +708,8 @@ public class E2EServiceInstances {
if (curStatus != null && curStatus.getResult() != null && curStatus.getResult().equalsIgnoreCase("processing")) {
String chkMessage = "Error: Locked instance - This " + requestScope + " (" + requestId + ") "
- + "now being worked with a status of " + curStatus.getProgress() + " (ServiceName - "
- + curStatus.getServiceName()
- + "). The existing request must finish or be cleaned up before proceeding.";
+ + "now being worked with a status of " + curStatus.getResult()
+ + ". The latest workflow of instance must be finished or cleaned up.";
Response response = msoRequest.buildServiceErrorResponse(HttpStatus.SC_CONFLICT,
MsoException.ServiceException, chkMessage, ErrorNumbers.SVC_DETAILED_SERVICE_ERROR, null);