X-Git-Url: https://gerrit.onap.org/r/gitweb?a=blobdiff_plain;f=bpmn%2Fso-bpmn-infrastructure-common%2Fsrc%2Fmain%2Fgroovy%2Forg%2Fonap%2Fso%2Fbpmn%2Finfrastructure%2Fscripts%2FDoCreateVfModule.groovy;h=6b4fc840f7a3aeffd5c9a9b8bb682c17aedff5d1;hb=1f8531ddb54b133ed0b25628d43ec698caa9b087;hp=7a606d515c8ca622c117c8ae1d58e948cd41159a;hpb=1b9b833a49976c449bbb65b8a7975e8b17620154;p=so.git diff --git a/bpmn/so-bpmn-infrastructure-common/src/main/groovy/org/onap/so/bpmn/infrastructure/scripts/DoCreateVfModule.groovy b/bpmn/so-bpmn-infrastructure-common/src/main/groovy/org/onap/so/bpmn/infrastructure/scripts/DoCreateVfModule.groovy index 7a606d515c..6b4fc840f7 100644 --- a/bpmn/so-bpmn-infrastructure-common/src/main/groovy/org/onap/so/bpmn/infrastructure/scripts/DoCreateVfModule.groovy +++ b/bpmn/so-bpmn-infrastructure-common/src/main/groovy/org/onap/so/bpmn/infrastructure/scripts/DoCreateVfModule.groovy @@ -84,7 +84,7 @@ public class DoCreateVfModule extends VfModuleBase { String Prefix="DCVFM_" ExceptionUtil exceptionUtil = new ExceptionUtil() JsonUtils jsonUtil = new JsonUtils() - SDNCAdapterUtils sdncAdapterUtils = new SDNCAdapterUtils(this) + SDNCAdapterUtils sdncAdapterUtils = new SDNCAdapterUtils() OofInfraUtils oofInfraUtils = new OofInfraUtils() CatalogDbUtils catalogDbUtils = new CatalogDbUtilsFactory().create() DecomposeJsonUtil decomposeJsonUtils = new DecomposeJsonUtil() @@ -598,7 +598,7 @@ public class DoCreateVfModule extends VfModuleBase { */ public void validateWorkflowResponse(DelegateExecution execution, String responseVar, String responseCodeVar, String errorResponseVar) { - SDNCAdapterUtils sdncAdapterUtils = new SDNCAdapterUtils(this) + SDNCAdapterUtils sdncAdapterUtils = new SDNCAdapterUtils() sdncAdapterUtils.validateSDNCResponse(execution, responseVar, responseCodeVar, errorResponseVar) } @@ -668,8 +668,7 @@ public class DoCreateVfModule extends VfModuleBase { rollbackData.put("VFMODULE", "rollbackPrepareUpdateVfModule", "true") execution.setVariable("rollbackData", rollbackData) } catch (Exception ex) { - ex.printStackTrace() - logger.debug('Exception occurred while postProcessing CreateAAIVfModule request:' + ex.getMessage()) + logger.debug('Exception occurred while postProcessing CreateAAIVfModule request: {}', ex.getMessage(), ex) exceptionUtil.buildAndThrowWorkflowException(execution, 1002, 'Bad response from CreateAAIVfModule' + ex.getMessage()) } logger.trace('Exited ' + method) @@ -741,8 +740,7 @@ public class DoCreateVfModule extends VfModuleBase { } } } catch (Exception ex) { - ex.printStackTrace() - logger.debug('Exception occurred while executing AAI GET:' + ex.getMessage()) + logger.debug('Exception occurred while executing AAI GET: {}', ex.getMessage(), ex) exceptionUtil.buildAndThrowWorkflowException(execution, 1002, 'AAI GET Failed:' + ex.getMessage()) } logger.trace('Exited ' + method) @@ -822,17 +820,16 @@ public class DoCreateVfModule extends VfModuleBase { } } } catch (Exception ex) { - ex.printStackTrace() - logger.debug('Exception occurred while executing AAI GET:' + ex.getMessage()) + logger.debug('Exception occurred while executing AAI GET: {}', ex.getMessage(), ex) exceptionUtil.buildAndThrowWorkflowException(execution, 1002, 'AAI GET Failed:' + ex.getMessage()) } logger.trace('Exited ' + method) } catch (BpmnError e) { throw e; } catch (Exception e) { - logger.error("{} {} {} {} {}", MessageEnum.BPMN_GENERAL_EXCEPTION_ARG.toString(), + logger.error("{} {} {} {} {} {}", MessageEnum.BPMN_GENERAL_EXCEPTION_ARG.toString(), 'Caught exception in ' + method, "BPMN", - ErrorCode.UnknownError.getValue(), "Exception is:\n" + e); + ErrorCode.UnknownError.getValue(), "Exception is:\n" + e, e); exceptionUtil.buildAndThrowWorkflowException(execution, 1002, 'Error in queryAAIVfModuleForStatus(): ' + e.getMessage()) } } @@ -1638,7 +1635,7 @@ public class DoCreateVfModule extends VfModuleBase { logger.debug("workflowException: " + workflowException) - SDNCAdapterUtils sdncAdapterUtils = new SDNCAdapterUtils(this) + SDNCAdapterUtils sdncAdapterUtils = new SDNCAdapterUtils() sdncAdapterUtils.validateSDNCResponse(execution, response, workflowException, successIndicator) String sdncResponse = response