From 8ecfa2367d322bdcaec91336d1ba1e16c1fb9830 Mon Sep 17 00:00:00 2001 From: Arindam Mondal Date: Mon, 19 Aug 2019 11:24:37 +0900 Subject: General sonar fixes +) Use format specifier to log exception ++) remove unused import Issue-ID: SO-2226 Change-Id: I0938d624b918eddf30e96da4f12d7a06cc0ddfe1 Signed-off-by: arindamm --- .../org/onap/so/bpmn/common/resource/ResourceRequestBuilder.java | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'bpmn/MSOCommonBPMN/src') diff --git a/bpmn/MSOCommonBPMN/src/main/java/org/onap/so/bpmn/common/resource/ResourceRequestBuilder.java b/bpmn/MSOCommonBPMN/src/main/java/org/onap/so/bpmn/common/resource/ResourceRequestBuilder.java index 8d02fa3e4f..2c1d36273d 100644 --- a/bpmn/MSOCommonBPMN/src/main/java/org/onap/so/bpmn/common/resource/ResourceRequestBuilder.java +++ b/bpmn/MSOCommonBPMN/src/main/java/org/onap/so/bpmn/common/resource/ResourceRequestBuilder.java @@ -118,7 +118,7 @@ public class ResourceRequestBuilder { logger.info("resource resolved using model uuid"); String uuid = (String) JsonUtils.getJsonValue(eachResource, "resourceUuid"); if ((null != uuid) && uuid.equals(resource.getModelInfo().getModelUuid())) { - logger.info("found resource uuid" + uuid); + logger.info("found resource uuid {}", uuid); String resourceParameters = JsonUtils.getJsonValue(eachResource, "parameters"); locationConstraints = JsonUtils.getJsonValue(resourceParameters, "locationConstraints"); } @@ -133,7 +133,7 @@ public class ResourceRequestBuilder { Map uuiRequestInputs = null; if (JsonUtils.getJsonValue(uuiServiceParameters, "requestInputs") != null) { String uuiRequestInputStr = JsonUtils.getJsonValue(uuiServiceParameters, "requestInputs"); - logger.info("resource input from UUI: " + uuiRequestInputStr); + logger.info("resource input from UUI:{} ", uuiRequestInputStr); if (uuiRequestInputStr == null || uuiRequestInputStr.isEmpty()) { uuiRequestInputStr = "{}"; } @@ -371,7 +371,7 @@ public class ResourceRequestBuilder { int val = Integer.parseInt(inputObj.toString()); return val; } catch (NumberFormatException e) { - logger.warn("Unable to parse to int", e.getMessage()); + logger.warn("Unable to parse to int", e); } } } -- cgit 1.2.3-korg