summaryrefslogtreecommitdiffstats
path: root/bpmn/so-bpmn-infrastructure-flows/src/main/groovy
diff options
context:
space:
mode:
authorsubhash kumar singh <subhash.kumar.singh@huawei.com>2018-08-06 18:31:58 +0530
committersubhash kumar singh <subhash.kumar.singh@huawei.com>2018-08-06 19:15:41 +0530
commitfed3cb184644da1a516394751ec6237de77614a1 (patch)
tree67fba124512b90403efa1ee737a107bb32ad924d /bpmn/so-bpmn-infrastructure-flows/src/main/groovy
parentb3b689f3fca302e653061e95086d7e622ee845a3 (diff)
Correct logging for DeactivateSDNCNetwork
Correct logging for "DeactivateSDNCNetworkResource.groovy". Change-Id: I3cf60ab9bfd0c82a19fd4e418956692c50af1086 Issue-ID: SO-689 Signed-off-by: subhash kumar singh <subhash.kumar.singh@huawei.com>
Diffstat (limited to 'bpmn/so-bpmn-infrastructure-flows/src/main/groovy')
-rw-r--r--bpmn/so-bpmn-infrastructure-flows/src/main/groovy/org/onap/so/bpmn/infrastructure/scripts/DeActivateSDNCNetworkResource.groovy26
1 files changed, 12 insertions, 14 deletions
diff --git a/bpmn/so-bpmn-infrastructure-flows/src/main/groovy/org/onap/so/bpmn/infrastructure/scripts/DeActivateSDNCNetworkResource.groovy b/bpmn/so-bpmn-infrastructure-flows/src/main/groovy/org/onap/so/bpmn/infrastructure/scripts/DeActivateSDNCNetworkResource.groovy
index 52249f0300..913c82fc58 100644
--- a/bpmn/so-bpmn-infrastructure-flows/src/main/groovy/org/onap/so/bpmn/infrastructure/scripts/DeActivateSDNCNetworkResource.groovy
+++ b/bpmn/so-bpmn-infrastructure-flows/src/main/groovy/org/onap/so/bpmn/infrastructure/scripts/DeActivateSDNCNetworkResource.groovy
@@ -24,6 +24,7 @@ import org.apache.commons.lang3.StringUtils
import org.camunda.bpm.engine.delegate.BpmnError
import org.json.JSONObject
import org.json.XML
+import org.onap.so.logger.MsoLogger
import org.openecomp.mso.bpmn.common.recipe.ResourceInput
import org.openecomp.mso.bpmn.common.resource.ResourceRequestBuilder
import org.openecomp.mso.bpmn.common.scripts.AbstractServiceTaskProcessor
@@ -37,8 +38,9 @@ import org.openecomp.mso.bpmn.common.scripts.SDNCAdapterUtils
* flow for SDNC Network Resource Activate
*/
public class DeActivateSDNCNetworkResource extends AbstractServiceTaskProcessor {
-
- String Prefix = "ACTSDNCRES_"
+ private static final MsoLogger msoLogger = MsoLogger.getMsoLogger(MsoLogger.Catalog.BPEL,
+ CreateSDNCNetworkResource.class);
+ String Prefix = "DEACTSDNCRES_"
ExceptionUtil exceptionUtil = new ExceptionUtil()
@@ -47,43 +49,39 @@ public class DeActivateSDNCNetworkResource extends AbstractServiceTaskProcessor
SDNCAdapterUtils sdncAdapterUtils = new SDNCAdapterUtils()
public void preProcessRequest(DelegateExecution execution) {
- def isDebugEnabled = execution.getVariable("isDebugLogEnabled")
- utils.log("INFO"," ***** started preProcessRequest*****", isDebug)
+ msoLogger.info(" ***** started preProcessRequest*****")
}
public void prepareSDNCRequest(DelegateExecution execution) {
- def isDebugEnabled = execution.getVariable("isDebugLogEnabled")
- utils.log("INFO"," ***** started prepareSDNCRequest *****", isDebug)
+ msoLogger.info(" ***** started prepareSDNCRequest *****")
}
public void prepareUpdateAfterDeActivateSDNCResource(DelegateExecution execution) {
- def isDebugEnabled = execution.getVariable("isDebugLogEnabled")
- utils.log("INFO"," ***** started prepareUpdateAfterDeActivateSDNCResource *****", isDebug)
+ msoLogger.info("***** started prepareUpdateAfterDeActivateSDNCResource *****")
}
public void postDeactivateSDNCCall(DelegateExecution execution) {
- def isDebugEnabled = execution.getVariable("isDebugLogEnabled")
- utils.log("INFO"," ***** started postDeactivateSDNCCall *****", isDebugEnabled)
+ msoLogger.info(" ***** started postDeactivateSDNCCall *****")
}
public void sendSyncResponse(DelegateExecution execution) {
def isDebugEnabled = execution.getVariable("isDebugLogEnabled")
- utils.log("INFO"," ***** started sendSyncResponse *****", isDebugEnabled)
+ msoLogger.info(" ***** started sendSyncResponse *****")
try {
String operationStatus = "finished"
// RESTResponse for main flow
String resourceOperationResp = """{"operationStatus":"${operationStatus}"}""".trim()
- utils.log("DEBUG", " sendSyncResponse to APIH:" + "\n" + resourceOperationResp, isDebugEnabled)
+ msoLogger.debug(" sendSyncResponse to APIH:" + "\n" + resourceOperationResp)
sendWorkflowResponse(execution, 202, resourceOperationResp)
execution.setVariable("sentSyncResponse", true)
} catch (Exception ex) {
String msg = "Exceptuion in sendSyncResponse:" + ex.getMessage()
- utils.log("DEBUG", msg, isDebugEnabled)
+ msoLogger.debug(msg)
exceptionUtil.buildAndThrowWorkflowException(execution, 7000, msg)
}
- utils.log("DEBUG"," ***** Exit sendSyncResopnse *****", isDebugEnabled)
+ msoLogger.debug(" ***** Exit sendSyncResopnse *****")
}
} \ No newline at end of file