aboutsummaryrefslogtreecommitdiffstats
path: root/so-etsi-nfvo-ns-lcm
diff options
context:
space:
mode:
authorBhagyalakshmi <Bhagyalakshmi_r01@infosys.com>2023-06-19 11:46:58 +0530
committerBhagyalakshmi <Bhagyalakshmi_r01@infosys.com>2023-06-19 11:55:19 +0530
commitf72f3366be2813bd0c2236dfd82bb6a9d8c1209d (patch)
treeccc0eeb48c7970a6a33e95b8573bb42bbd8e2874 /so-etsi-nfvo-ns-lcm
parentce8ea034347552cdfbf39bd4b704a04c92165901 (diff)
Replacing NS InstanceId as Operation idHEADmaster
Change-Id: I2d9545631fbcb1c435fc157353f8e4eeae78823c Issue-ID: SO-4099 Signed-off-by: Bhagyalakshmi <Bhagyalakshmi_r01@infosys.com>
Diffstat (limited to 'so-etsi-nfvo-ns-lcm')
-rw-r--r--so-etsi-nfvo-ns-lcm/so-etsi-nfvo-ns-lcm-bpmn-flows/src/main/java/org/onap/so/etsi/nfvo/ns/lcm/bpmn/flows/service/JobExecutorService.java5
1 files changed, 3 insertions, 2 deletions
diff --git a/so-etsi-nfvo-ns-lcm/so-etsi-nfvo-ns-lcm-bpmn-flows/src/main/java/org/onap/so/etsi/nfvo/ns/lcm/bpmn/flows/service/JobExecutorService.java b/so-etsi-nfvo-ns-lcm/so-etsi-nfvo-ns-lcm-bpmn-flows/src/main/java/org/onap/so/etsi/nfvo/ns/lcm/bpmn/flows/service/JobExecutorService.java
index 14d4fa2..f83d959 100644
--- a/so-etsi-nfvo-ns-lcm/so-etsi-nfvo-ns-lcm-bpmn-flows/src/main/java/org/onap/so/etsi/nfvo/ns/lcm/bpmn/flows/service/JobExecutorService.java
+++ b/so-etsi-nfvo-ns-lcm/so-etsi-nfvo-ns-lcm-bpmn-flows/src/main/java/org/onap/so/etsi/nfvo/ns/lcm/bpmn/flows/service/JobExecutorService.java
@@ -44,6 +44,7 @@ import java.time.Instant;
import java.time.LocalDateTime;
import java.util.HashMap;
import java.util.Map;
+import java.util.UUID;
import java.util.Optional;
import java.util.concurrent.TimeUnit;
import org.apache.commons.lang3.tuple.ImmutablePair;
@@ -162,7 +163,7 @@ public class JobExecutorService {
logger.info("New job created in database :\n{}", newJob);
final LocalDateTime currentDateTime = LocalDateTime.now();
- final NsLcmOpOcc newNsLcmOpOcc = new NsLcmOpOcc().id(nsInstanceId).operation(NsLcmOpType.INSTANTIATE)
+ final NsLcmOpOcc newNsLcmOpOcc = new NsLcmOpOcc().id(UUID.randomUUID().toString()).operation(NsLcmOpType.INSTANTIATE)
.operationState(OperationStateEnum.PROCESSING).stateEnteredTime(currentDateTime)
.startTime(currentDateTime).nfvoNsInst(getNfvoNsInst(nsInstanceId)).isAutoInvocation(false)
.isCancelPending(false).operationParams(gson.toJson(instantiateNsRequest));
@@ -207,7 +208,7 @@ public class JobExecutorService {
logger.info("New job created in database :\n{}", nfvoJob);
final LocalDateTime currentDateTime = LocalDateTime.now();
- final NsLcmOpOcc nsLcmOpOcc = new NsLcmOpOcc().id(nsInstanceId).operation(NsLcmOpType.TERMINATE)
+ final NsLcmOpOcc nsLcmOpOcc = new NsLcmOpOcc().id(UUID.randomUUID().toString()).operation(NsLcmOpType.TERMINATE)
.operationState(OperationStateEnum.PROCESSING).stateEnteredTime(currentDateTime)
.startTime(currentDateTime).nfvoNsInst(getNfvoNsInst(nsInstanceId)).isAutoInvocation(false)
.isCancelPending(false).operationParams(gson.toJson(terminateNsRequest));