summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--src/main/java/org/onap/nbi/apis/serviceorder/SoClient.java8
-rw-r--r--src/main/java/org/onap/nbi/apis/serviceorder/model/consumer/ModelInfo.java24
-rw-r--r--src/main/java/org/onap/nbi/apis/serviceorder/model/consumer/RequestParameters.java2
-rw-r--r--src/main/java/org/onap/nbi/apis/serviceorder/workflow/SOTaskProcessor.java1
4 files changed, 24 insertions, 11 deletions
diff --git a/src/main/java/org/onap/nbi/apis/serviceorder/SoClient.java b/src/main/java/org/onap/nbi/apis/serviceorder/SoClient.java
index 5f10d63..ef4d8c3 100644
--- a/src/main/java/org/onap/nbi/apis/serviceorder/SoClient.java
+++ b/src/main/java/org/onap/nbi/apis/serviceorder/SoClient.java
@@ -61,11 +61,9 @@ public class SoClient {
String url = soHostname + OnapComponentsUrlPaths.MSO_CREATE_SERVICE_INSTANCE_PATH;
- HttpEntity<MSOPayload> requestDetailEntity = new HttpEntity<>(msoPayload, buildRequestHeader());
-
try {
ResponseEntity<CreateServiceInstanceResponse> response = restTemplate.exchange(url, HttpMethod.POST,
- new HttpEntity<>(requestDetailEntity, buildRequestHeader()), CreateServiceInstanceResponse.class);
+ new HttpEntity<>(msoPayload, buildRequestHeader()), CreateServiceInstanceResponse.class);
logResponsePost(url, response);
return response;
@@ -85,11 +83,9 @@ public class SoClient {
String url = soHostname + OnapComponentsUrlPaths.MSO_DELETE_REQUEST_STATUS_PATH + serviceId;
- HttpEntity<MSOPayload> requestDetailEntity = new HttpEntity<>(msoPayload, buildRequestHeader());
-
try {
ResponseEntity<CreateServiceInstanceResponse> response = restTemplate.exchange(url, HttpMethod.DELETE,
- new HttpEntity<>(requestDetailEntity, buildRequestHeader()), CreateServiceInstanceResponse.class);
+ new HttpEntity<>(msoPayload, buildRequestHeader()), CreateServiceInstanceResponse.class);
logResponsePost(url, response);
return response;
diff --git a/src/main/java/org/onap/nbi/apis/serviceorder/model/consumer/ModelInfo.java b/src/main/java/org/onap/nbi/apis/serviceorder/model/consumer/ModelInfo.java
index 3479f85..bef4183 100644
--- a/src/main/java/org/onap/nbi/apis/serviceorder/model/consumer/ModelInfo.java
+++ b/src/main/java/org/onap/nbi/apis/serviceorder/model/consumer/ModelInfo.java
@@ -21,6 +21,8 @@ public class ModelInfo {
private String modelInvariantId;
+ private String modelVersionId;
+
private String modelNameVersionId;
private String modelName;
@@ -87,11 +89,25 @@ public class ModelInfo {
this.modelCustomizationId = modelCustomizationId;
}
+ public String getModelVersionId() {
+ return modelVersionId;
+ }
+
+ public void setModelVersionId(String modelVersionId) {
+ this.modelVersionId = modelVersionId;
+ }
+
@Override
public String toString() {
- return "ModelInfo{" + "modelType='" + modelType + '\'' + ", modelInvariantId='" + modelInvariantId + '\''
- + ", modelNameVersionId='" + modelNameVersionId + '\'' + ", modelName='" + modelName + '\''
- + ", modelVersion='" + modelVersion + '\'' + ", modelCustomizationName='" + modelCustomizationName
- + '\'' + ", modelCustomizationId='" + modelCustomizationId + '\'' + '}';
+ return "ModelInfo{" +
+ "modelType='" + modelType + '\'' +
+ ", modelInvariantId='" + modelInvariantId + '\'' +
+ ", modelVersionId='" + modelVersionId + '\'' +
+ ", modelNameVersionId='" + modelNameVersionId + '\'' +
+ ", modelName='" + modelName + '\'' +
+ ", modelVersion='" + modelVersion + '\'' +
+ ", modelCustomizationName='" + modelCustomizationName + '\'' +
+ ", modelCustomizationId='" + modelCustomizationId + '\'' +
+ '}';
}
}
diff --git a/src/main/java/org/onap/nbi/apis/serviceorder/model/consumer/RequestParameters.java b/src/main/java/org/onap/nbi/apis/serviceorder/model/consumer/RequestParameters.java
index 31a1853..e4bbfbb 100644
--- a/src/main/java/org/onap/nbi/apis/serviceorder/model/consumer/RequestParameters.java
+++ b/src/main/java/org/onap/nbi/apis/serviceorder/model/consumer/RequestParameters.java
@@ -32,7 +32,7 @@ public class RequestParameters {
}
public void setSubscriptionServiceType(String subscriptionServiceType) {
- subscriptionServiceType = subscriptionServiceType;
+ this.subscriptionServiceType = subscriptionServiceType;
}
public List<UserParams> getUserParams() {
diff --git a/src/main/java/org/onap/nbi/apis/serviceorder/workflow/SOTaskProcessor.java b/src/main/java/org/onap/nbi/apis/serviceorder/workflow/SOTaskProcessor.java
index 1d1ef36..d623b89 100644
--- a/src/main/java/org/onap/nbi/apis/serviceorder/workflow/SOTaskProcessor.java
+++ b/src/main/java/org/onap/nbi/apis/serviceorder/workflow/SOTaskProcessor.java
@@ -246,6 +246,7 @@ public class SOTaskProcessor {
modelInfo.setModelType("service");
modelInfo.setModelInvariantId((String) sdcInfos.get("invariantUUID"));
modelInfo.setModelNameVersionId(orderItem.getService().getServiceSpecification().getId());
+ modelInfo.setModelVersionId(orderItem.getService().getServiceSpecification().getId());
modelInfo.setModelName((String) sdcInfos.get("name"));
modelInfo.setModelVersion((String) sdcInfos.get("version"));
requestDetails.setModelInfo(modelInfo);