aboutsummaryrefslogtreecommitdiffstats
path: root/bpmn
diff options
context:
space:
mode:
Diffstat (limited to 'bpmn')
-rw-r--r--bpmn/MSOCommonBPMN/src/main/java/org/openecomp/mso/bpmn/common/recipe/ResourceInput.java589
-rw-r--r--bpmn/MSOCommonBPMN/src/main/java/org/openecomp/mso/bpmn/common/recipe/ResourceRecipeRequest.java6
-rw-r--r--bpmn/MSOCommonBPMN/src/main/java/org/openecomp/mso/bpmn/common/resource/ResourceRequestBuilder.java3
-rw-r--r--bpmn/MSOInfrastructureBPMN/src/main/java/org/openecomp/mso/bpmn/infrastructure/pnf/delegate/CheckAaiForCorrelationIdDelegate.java4
-rw-r--r--bpmn/MSOInfrastructureBPMN/src/main/java/org/openecomp/mso/bpmn/infrastructure/workflow/serviceTask/AbstractSdncOperationTask.java2
5 files changed, 307 insertions, 297 deletions
diff --git a/bpmn/MSOCommonBPMN/src/main/java/org/openecomp/mso/bpmn/common/recipe/ResourceInput.java b/bpmn/MSOCommonBPMN/src/main/java/org/openecomp/mso/bpmn/common/recipe/ResourceInput.java
index 00e4ae71d6..13b1666991 100644
--- a/bpmn/MSOCommonBPMN/src/main/java/org/openecomp/mso/bpmn/common/recipe/ResourceInput.java
+++ b/bpmn/MSOCommonBPMN/src/main/java/org/openecomp/mso/bpmn/common/recipe/ResourceInput.java
@@ -1,293 +1,296 @@
-/*-
- * ============LICENSE_START=======================================================
- * ONAP - SO
- * ================================================================================
- * Copyright (C) 2018 Huawei Technologies Co., Ltd. All rights reserved.
- * ================================================================================
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- * ============LICENSE_END=========================================================
- */
-package org.openecomp.mso.bpmn.common.recipe;
-
-import org.openecomp.mso.bpmn.core.domain.ModelInfo;
-
-import com.fasterxml.jackson.annotation.JsonProperty;
-import com.fasterxml.jackson.annotation.JsonPropertyOrder;
-import com.fasterxml.jackson.annotation.JsonRootName;
-import com.fasterxml.jackson.core.JsonProcessingException;
-import com.fasterxml.jackson.databind.ObjectMapper;
-import com.fasterxml.jackson.databind.SerializationFeature;
-
-/**
- * the inputs for the resource recipe
- * <br>
- * <p>
- * </p>
- *
- * @author
- * @version ONAP Beijing Release 2018-03-08
- */
-@JsonPropertyOrder({"resourceInstanceName", "resourceInstanceDes", "globalSubscriberId", "serviceType", "serviceId", "operationId", "serviceModelInfo","resourceModelInfo", "resourceInstancenUuid","resourceParameters","operationType"})
-@JsonRootName("variables")
-public class ResourceInput {
-
- @JsonProperty("resourceInstanceName")
- private String resourceInstanceName;
-
- @JsonProperty("resourceInstanceDes")
- private String resourceInstanceDes;
-
- @JsonProperty("globalSubscriberId")
- private String globalSubscriberId;
-
- @JsonProperty("serviceType")
- private String serviceType;
-
- @JsonProperty("serviceInstanceId")
- private String serviceInstanceId;
-
- @JsonProperty("operationId")
- private String operationId;
-
- @JsonProperty("serviceModelInfo")
- private ModelInfo serviceModelInfo;
-
- @JsonProperty("resourceModelInfo")
- private ModelInfo resourceModelInfo;
-
- //for delete resource
- @JsonProperty("resourceInstancenUuid")
- private String resourceInstancenUuid;
-
- @JsonProperty("resourceParameters")
- private String resourceParameters;
-
- @JsonProperty("operationType")
- private String operationType;
-
-
- /**
- * @return Returns the resourceInstanceName.
- */
- @JsonProperty("resourceInstanceName")
- public String getResourceInstanceName() {
- return resourceInstanceName;
- }
-
-
- /**
- * @param resourceInstanceName The resourceInstanceName to set.
- */
- @JsonProperty("resourceInstanceName")
- public void setResourceInstanceName(String resourceInstanceName) {
- this.resourceInstanceName = resourceInstanceName;
- }
-
-
- /**
- * @return Returns the resourceInstanceDes.
- */
- @JsonProperty("resourceInstanceDes")
- public String getResourceInstanceDes() {
- return resourceInstanceDes;
- }
-
-
- /**
- * @param resourceInstanceDes The resourceInstanceDes to set.
- */
- @JsonProperty("resourceInstanceDes")
- public void setResourceInstanceDes(String resourceInstanceDes) {
- this.resourceInstanceDes = resourceInstanceDes;
- }
-
-
- /**
- * @return Returns the globalSubscriberId.
- */
- @JsonProperty("globalSubscriberId")
- public String getGlobalSubscriberId() {
- return globalSubscriberId;
- }
-
-
- /**
- * @param globalSubscriberId The globalSubscriberId to set.
- */
- @JsonProperty("globalSubscriberId")
- public void setGlobalSubscriberId(String globalSubscriberId) {
- this.globalSubscriberId = globalSubscriberId;
- }
-
-
- /**
- * @return Returns the serviceType.
- */
- @JsonProperty("serviceType")
- public String getServiceType() {
- return serviceType;
- }
-
-
- /**
- * @param serviceType The serviceType to set.
- */
- @JsonProperty("serviceType")
- public void setServiceType(String serviceType) {
- this.serviceType = serviceType;
- }
-
-
- /**
- * @return Returns the serviceId.
- */
- @JsonProperty("serviceInstanceId")
- public String getServiceInstanceId() {
- return serviceInstanceId;
- }
-
-
- /**
- * @param serviceId The serviceId to set.
- */
- @JsonProperty("serviceInstanceId")
- public void setServiceInstanceId(String serviceId) {
- this.serviceInstanceId = serviceId;
- }
-
-
- /**
- * @return Returns the operationId.
- */
- @JsonProperty("operationId")
- public String getOperationId() {
- return operationId;
- }
-
-
- /**
- * @param operationId The operationId to set.
- */
- @JsonProperty("operationId")
- public void setOperationId(String operationId) {
- this.operationId = operationId;
- }
-
- /**
- * @return Returns the serviceModelInfo.
- */
- @JsonProperty("serviceModelInfo")
- public ModelInfo getServiceModelInfo() {
- return serviceModelInfo;
- }
-
-
-
- /**
- * @param serviceModelInfo The serviceModelInfo to set.
- */
- @JsonProperty("serviceModelInfo")
- public void setServiceModelInfo(ModelInfo serviceModelInfo) {
- this.serviceModelInfo = serviceModelInfo;
- }
-
-
-
- /**
- * @return Returns the resourceModelInfo.
- */
- @JsonProperty("resourceModelInfo")
- public ModelInfo getResourceModelInfo() {
- return resourceModelInfo;
- }
-
-
-
- /**
- * @param resourceModelInfo The resourceModelInfo to set.
- */
- @JsonProperty("resourceModelInfo")
- public void setResourceModelInfo(ModelInfo resourceModelInfo) {
- this.resourceModelInfo = resourceModelInfo;
- }
-
-
- /**
- * @return Returns the resourceParameters.
- */
- @JsonProperty("resourceParameters")
- public String getResourceParameters() {
- return resourceParameters;
- }
-
-
- /**
- * @param resourceParameters The resourceParameters to set.
- */
- @JsonProperty("resourceParameters")
- public void setResourceParameters(String resourceParameters) {
- this.resourceParameters = resourceParameters;
- }
-
-
- /**
- * @return Returns the operationType.
- */
- @JsonProperty("operationType")
- public String getOperationType() {
- return operationType;
- }
-
-
- /**
- * @param operationType The operationType to set.
- */
- @JsonProperty("operationType")
- public void setOperationType(String operationType) {
- this.operationType = operationType;
- }
-
-
-
- /**
- * @return Returns the resourceInstancenUuid.
- */
- @JsonProperty("resourceInstancenUuid")
- public String getResourceInstancenUuid() {
- return resourceInstancenUuid;
- }
-
-
-
- /**
- * @param resourceInstancenUuid The resourceInstancenUuid to set.
- */
- @JsonProperty("resourceInstancenUuid")
- public void setResourceInstancenUuid(String resourceInstancenUuid) {
- this.resourceInstancenUuid = resourceInstancenUuid;
- }
-
- @Override
- public String toString() {
- ObjectMapper mapper = new ObjectMapper();
- mapper.configure(SerializationFeature.WRAP_ROOT_VALUE, false);
- String jsonStr = "";
- try {
- jsonStr = mapper.writeValueAsString(this);
- } catch(JsonProcessingException e) {
-
- e.printStackTrace();
- }
- return jsonStr;
- }
-}
+/*-
+ * ============LICENSE_START=======================================================
+ * ONAP - SO
+ * ================================================================================
+ * Copyright (C) 2018 Huawei Technologies Co., Ltd. All rights reserved.
+ * ================================================================================
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ * ============LICENSE_END=========================================================
+ */
+package org.openecomp.mso.bpmn.common.recipe;
+
+import org.openecomp.mso.bpmn.core.domain.ModelInfo;
+import org.openecomp.mso.logger.MsoLogger;
+
+import com.fasterxml.jackson.annotation.JsonProperty;
+import com.fasterxml.jackson.annotation.JsonPropertyOrder;
+import com.fasterxml.jackson.annotation.JsonRootName;
+import com.fasterxml.jackson.core.JsonProcessingException;
+import com.fasterxml.jackson.databind.ObjectMapper;
+import com.fasterxml.jackson.databind.SerializationFeature;
+
+/**
+ * the inputs for the resource recipe
+ * <br>
+ * <p>
+ * </p>
+ *
+ * @author
+ * @version ONAP Beijing Release 2018-03-08
+ */
+@JsonPropertyOrder({"resourceInstanceName", "resourceInstanceDes", "globalSubscriberId", "serviceType", "serviceId", "operationId", "serviceModelInfo","resourceModelInfo", "resourceInstancenUuid","resourceParameters","operationType"})
+@JsonRootName("variables")
+public class ResourceInput {
+
+ private static MsoLogger msoLogger = MsoLogger.getMsoLogger (MsoLogger.Catalog.GENERAL);
+
+ @JsonProperty("resourceInstanceName")
+ private String resourceInstanceName;
+
+ @JsonProperty("resourceInstanceDes")
+ private String resourceInstanceDes;
+
+ @JsonProperty("globalSubscriberId")
+ private String globalSubscriberId;
+
+ @JsonProperty("serviceType")
+ private String serviceType;
+
+ @JsonProperty("serviceInstanceId")
+ private String serviceInstanceId;
+
+ @JsonProperty("operationId")
+ private String operationId;
+
+ @JsonProperty("serviceModelInfo")
+ private ModelInfo serviceModelInfo;
+
+ @JsonProperty("resourceModelInfo")
+ private ModelInfo resourceModelInfo;
+
+ //for delete resource
+ @JsonProperty("resourceInstancenUuid")
+ private String resourceInstancenUuid;
+
+ @JsonProperty("resourceParameters")
+ private String resourceParameters;
+
+ @JsonProperty("operationType")
+ private String operationType;
+
+
+ /**
+ * @return Returns the resourceInstanceName.
+ */
+ @JsonProperty("resourceInstanceName")
+ public String getResourceInstanceName() {
+ return resourceInstanceName;
+ }
+
+
+ /**
+ * @param resourceInstanceName The resourceInstanceName to set.
+ */
+ @JsonProperty("resourceInstanceName")
+ public void setResourceInstanceName(String resourceInstanceName) {
+ this.resourceInstanceName = resourceInstanceName;
+ }
+
+
+ /**
+ * @return Returns the resourceInstanceDes.
+ */
+ @JsonProperty("resourceInstanceDes")
+ public String getResourceInstanceDes() {
+ return resourceInstanceDes;
+ }
+
+
+ /**
+ * @param resourceInstanceDes The resourceInstanceDes to set.
+ */
+ @JsonProperty("resourceInstanceDes")
+ public void setResourceInstanceDes(String resourceInstanceDes) {
+ this.resourceInstanceDes = resourceInstanceDes;
+ }
+
+
+ /**
+ * @return Returns the globalSubscriberId.
+ */
+ @JsonProperty("globalSubscriberId")
+ public String getGlobalSubscriberId() {
+ return globalSubscriberId;
+ }
+
+
+ /**
+ * @param globalSubscriberId The globalSubscriberId to set.
+ */
+ @JsonProperty("globalSubscriberId")
+ public void setGlobalSubscriberId(String globalSubscriberId) {
+ this.globalSubscriberId = globalSubscriberId;
+ }
+
+
+ /**
+ * @return Returns the serviceType.
+ */
+ @JsonProperty("serviceType")
+ public String getServiceType() {
+ return serviceType;
+ }
+
+
+ /**
+ * @param serviceType The serviceType to set.
+ */
+ @JsonProperty("serviceType")
+ public void setServiceType(String serviceType) {
+ this.serviceType = serviceType;
+ }
+
+
+ /**
+ * @return Returns the serviceId.
+ */
+ @JsonProperty("serviceInstanceId")
+ public String getServiceInstanceId() {
+ return serviceInstanceId;
+ }
+
+
+ /**
+ * @param serviceId The serviceId to set.
+ */
+ @JsonProperty("serviceInstanceId")
+ public void setServiceInstanceId(String serviceId) {
+ this.serviceInstanceId = serviceId;
+ }
+
+
+ /**
+ * @return Returns the operationId.
+ */
+ @JsonProperty("operationId")
+ public String getOperationId() {
+ return operationId;
+ }
+
+
+ /**
+ * @param operationId The operationId to set.
+ */
+ @JsonProperty("operationId")
+ public void setOperationId(String operationId) {
+ this.operationId = operationId;
+ }
+
+ /**
+ * @return Returns the serviceModelInfo.
+ */
+ @JsonProperty("serviceModelInfo")
+ public ModelInfo getServiceModelInfo() {
+ return serviceModelInfo;
+ }
+
+
+
+ /**
+ * @param serviceModelInfo The serviceModelInfo to set.
+ */
+ @JsonProperty("serviceModelInfo")
+ public void setServiceModelInfo(ModelInfo serviceModelInfo) {
+ this.serviceModelInfo = serviceModelInfo;
+ }
+
+
+
+ /**
+ * @return Returns the resourceModelInfo.
+ */
+ @JsonProperty("resourceModelInfo")
+ public ModelInfo getResourceModelInfo() {
+ return resourceModelInfo;
+ }
+
+
+
+ /**
+ * @param resourceModelInfo The resourceModelInfo to set.
+ */
+ @JsonProperty("resourceModelInfo")
+ public void setResourceModelInfo(ModelInfo resourceModelInfo) {
+ this.resourceModelInfo = resourceModelInfo;
+ }
+
+
+ /**
+ * @return Returns the resourceParameters.
+ */
+ @JsonProperty("resourceParameters")
+ public String getResourceParameters() {
+ return resourceParameters;
+ }
+
+
+ /**
+ * @param resourceParameters The resourceParameters to set.
+ */
+ @JsonProperty("resourceParameters")
+ public void setResourceParameters(String resourceParameters) {
+ this.resourceParameters = resourceParameters;
+ }
+
+
+ /**
+ * @return Returns the operationType.
+ */
+ @JsonProperty("operationType")
+ public String getOperationType() {
+ return operationType;
+ }
+
+
+ /**
+ * @param operationType The operationType to set.
+ */
+ @JsonProperty("operationType")
+ public void setOperationType(String operationType) {
+ this.operationType = operationType;
+ }
+
+
+
+ /**
+ * @return Returns the resourceInstancenUuid.
+ */
+ @JsonProperty("resourceInstancenUuid")
+ public String getResourceInstancenUuid() {
+ return resourceInstancenUuid;
+ }
+
+
+
+ /**
+ * @param resourceInstancenUuid The resourceInstancenUuid to set.
+ */
+ @JsonProperty("resourceInstancenUuid")
+ public void setResourceInstancenUuid(String resourceInstancenUuid) {
+ this.resourceInstancenUuid = resourceInstancenUuid;
+ }
+
+ @Override
+ public String toString() {
+ ObjectMapper mapper = new ObjectMapper();
+ mapper.configure(SerializationFeature.WRAP_ROOT_VALUE, false);
+ String jsonStr = "";
+ try {
+ jsonStr = mapper.writeValueAsString(this);
+ } catch(JsonProcessingException e) {
+ msoLogger.debug("JsonProcessingException", e);
+ e.printStackTrace();
+ }
+ return jsonStr;
+ }
+}
diff --git a/bpmn/MSOCommonBPMN/src/main/java/org/openecomp/mso/bpmn/common/recipe/ResourceRecipeRequest.java b/bpmn/MSOCommonBPMN/src/main/java/org/openecomp/mso/bpmn/common/recipe/ResourceRecipeRequest.java
index 194f7c43ec..a1809fe754 100644
--- a/bpmn/MSOCommonBPMN/src/main/java/org/openecomp/mso/bpmn/common/recipe/ResourceRecipeRequest.java
+++ b/bpmn/MSOCommonBPMN/src/main/java/org/openecomp/mso/bpmn/common/recipe/ResourceRecipeRequest.java
@@ -20,6 +20,8 @@
package org.openecomp.mso.bpmn.common.recipe;
+import org.openecomp.mso.logger.MsoLogger;
+
import com.fasterxml.jackson.annotation.JsonProperty;
import com.fasterxml.jackson.annotation.JsonPropertyOrder;
import com.fasterxml.jackson.annotation.JsonRootName;
@@ -35,6 +37,8 @@ import com.fasterxml.jackson.databind.SerializationFeature;
@JsonRootName("variables")
public class ResourceRecipeRequest {
+ private static MsoLogger msoLogger = MsoLogger.getMsoLogger (MsoLogger.Catalog.GENERAL);
+
@JsonProperty("resourceInput")
private BpmnParam resourceInput;
@@ -147,7 +151,7 @@ public class ResourceRecipeRequest {
try {
jsonStr = mapper.writeValueAsString(this);
} catch(JsonProcessingException e) {
-
+ msoLogger.debug("JsonProcessingException", e);
e.printStackTrace();
}
return jsonStr;
diff --git a/bpmn/MSOCommonBPMN/src/main/java/org/openecomp/mso/bpmn/common/resource/ResourceRequestBuilder.java b/bpmn/MSOCommonBPMN/src/main/java/org/openecomp/mso/bpmn/common/resource/ResourceRequestBuilder.java
index 7c3ea37817..c88800273c 100644
--- a/bpmn/MSOCommonBPMN/src/main/java/org/openecomp/mso/bpmn/common/resource/ResourceRequestBuilder.java
+++ b/bpmn/MSOCommonBPMN/src/main/java/org/openecomp/mso/bpmn/common/resource/ResourceRequestBuilder.java
@@ -109,6 +109,7 @@ public class ResourceRequestBuilder {
Map<String, Object> resourceInputsFromServiceDeclaredLevel = buildResouceRequest(serviceUuid, resourceCustomizationUuid, serviceInput);
resourceInputsFromUuiMap.putAll(resourceInputsFromServiceDeclaredLevel);
} catch(SdcToscaParserException e) {
+ LOGGER.debug("SdcToscaParserException", e);
e.printStackTrace();
}
String resourceInputsStr = getJsonString(resourceInputsFromUuiMap);
@@ -216,7 +217,7 @@ public class ResourceRequestBuilder {
try {
jsonStr = mapper.writeValueAsString(srcObj);
} catch(JsonProcessingException e) {
-
+ LOGGER.debug("SdcToscaParserException", e);
e.printStackTrace();
}
return jsonStr;
diff --git a/bpmn/MSOInfrastructureBPMN/src/main/java/org/openecomp/mso/bpmn/infrastructure/pnf/delegate/CheckAaiForCorrelationIdDelegate.java b/bpmn/MSOInfrastructureBPMN/src/main/java/org/openecomp/mso/bpmn/infrastructure/pnf/delegate/CheckAaiForCorrelationIdDelegate.java
index e2dfedb6e4..0e65dd7441 100644
--- a/bpmn/MSOInfrastructureBPMN/src/main/java/org/openecomp/mso/bpmn/infrastructure/pnf/delegate/CheckAaiForCorrelationIdDelegate.java
+++ b/bpmn/MSOInfrastructureBPMN/src/main/java/org/openecomp/mso/bpmn/infrastructure/pnf/delegate/CheckAaiForCorrelationIdDelegate.java
@@ -32,6 +32,7 @@ import org.openecomp.mso.bpmn.common.scripts.ExceptionUtil;
import org.openecomp.mso.bpmn.infrastructure.pnf.implementation.AaiConnection;
import org.openecomp.mso.bpmn.infrastructure.pnf.implementation.AaiResponse;
import org.openecomp.mso.bpmn.infrastructure.pnf.implementation.CheckAaiForCorrelationIdImplementation;
+import org.openecomp.mso.logger.MsoLogger;
import org.springframework.beans.factory.annotation.Autowired;
/**
@@ -46,7 +47,7 @@ import org.springframework.beans.factory.annotation.Autowired;
*/
public class CheckAaiForCorrelationIdDelegate implements JavaDelegate {
-
+ private static MsoLogger LOGGER = MsoLogger.getMsoLogger(MsoLogger.Catalog.GENERAL);
private CheckAaiForCorrelationIdImplementation implementation = new CheckAaiForCorrelationIdImplementation();
private AaiConnection aaiConnection;
@@ -68,6 +69,7 @@ public class CheckAaiForCorrelationIdDelegate implements JavaDelegate {
execution.setVariableLocal(AAI_CONTAINS_INFO_ABOUT_PNF, aaiResponse.getContainsInfoAboutPnf());
execution.setVariableLocal(AAI_CONTAINS_INFO_ABOUT_IP, aaiResponse.getContainsInfoAboutIp());
} catch (IOException e) {
+ LOGGER.error("IOException",e);
new ExceptionUtil().buildAndThrowWorkflowException(execution, 9999, e.getMessage());
}
}
diff --git a/bpmn/MSOInfrastructureBPMN/src/main/java/org/openecomp/mso/bpmn/infrastructure/workflow/serviceTask/AbstractSdncOperationTask.java b/bpmn/MSOInfrastructureBPMN/src/main/java/org/openecomp/mso/bpmn/infrastructure/workflow/serviceTask/AbstractSdncOperationTask.java
index 25141a0c40..ee047c9dd5 100644
--- a/bpmn/MSOInfrastructureBPMN/src/main/java/org/openecomp/mso/bpmn/infrastructure/workflow/serviceTask/AbstractSdncOperationTask.java
+++ b/bpmn/MSOInfrastructureBPMN/src/main/java/org/openecomp/mso/bpmn/infrastructure/workflow/serviceTask/AbstractSdncOperationTask.java
@@ -359,7 +359,7 @@ public abstract class AbstractSdncOperationTask extends BaseTask {
return vlaue;
}
} catch (Exception e) {
- msoLogger.error(MessageEnum.GENERAL_EXCEPTION, " getMsbIp catch exception: ", "", this.getTaskName(), MsoLogger.ErrorCode.UnknownError, e.getClass().toString());
+ msoLogger.error(MessageEnum.GENERAL_EXCEPTION, " getMsbIp catch exception: ", "", this.getTaskName(), MsoLogger.ErrorCode.UnknownError, e.getClass().toString(),e);
}
return defaultValue;
}