From 08234869b6e0052f312a6bb04d9cd8df7f6c252e Mon Sep 17 00:00:00 2001 From: Chandan Ghosh Date: Fri, 4 Jan 2019 12:39:42 +0530 Subject: Added logger for exception log Added logger for exception log. Reported in sonar Issue-ID: DMAAP-927 Change-Id: If3cf309c84ad931715f007a68747a51142f0db15 Signed-off-by: Chandan Ghosh --- .../org/onap/dmaap/mr/dmaapMMAgent/utils/MirrorMakerProcessHandler.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'src/main') diff --git a/src/main/java/org/onap/dmaap/mr/dmaapMMAgent/utils/MirrorMakerProcessHandler.java b/src/main/java/org/onap/dmaap/mr/dmaapMMAgent/utils/MirrorMakerProcessHandler.java index 21a3974..5246ce9 100644 --- a/src/main/java/org/onap/dmaap/mr/dmaapMMAgent/utils/MirrorMakerProcessHandler.java +++ b/src/main/java/org/onap/dmaap/mr/dmaapMMAgent/utils/MirrorMakerProcessHandler.java @@ -97,7 +97,7 @@ public class MirrorMakerProcessHandler { // } } } catch (Exception e) { - e.printStackTrace(); + logger.error("Error occured in MirrorMakerProcessHandler.checkMirrorMakerProcess"+e); } return false; } -- cgit 1.2.3-korg From 36c24531b60b2a0b909c2594f6f37741b1901ca7 Mon Sep 17 00:00:00 2001 From: Chandan Ghosh Date: Fri, 4 Jan 2019 12:47:27 +0530 Subject: Added logger for exception block Added logger for exception block reported in sonar Issue-ID: DMAAP-927 Change-Id: Ib1e120888bc1b7b4c51b39da37f49cd83ef770e8 Signed-off-by: Chandan Ghosh --- .../java/org/onap/dmaap/mr/dmaapMMAgent/MirrorMakerAgent.java | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) (limited to 'src/main') diff --git a/src/main/java/org/onap/dmaap/mr/dmaapMMAgent/MirrorMakerAgent.java b/src/main/java/org/onap/dmaap/mr/dmaapMMAgent/MirrorMakerAgent.java index 86a653d..23fd99f 100644 --- a/src/main/java/org/onap/dmaap/mr/dmaapMMAgent/MirrorMakerAgent.java +++ b/src/main/java/org/onap/dmaap/mr/dmaapMMAgent/MirrorMakerAgent.java @@ -111,7 +111,7 @@ public class MirrorMakerAgent { try { input.close(); } catch (IOException e) { - e.printStackTrace(); + logger.error("exception occured in checkStartup "+e); } } } @@ -128,7 +128,7 @@ public class MirrorMakerAgent { try { input.close(); } catch (IOException e) { - e.printStackTrace(); + logger.error("exception occured in checkStartup "+e); } } } @@ -176,7 +176,7 @@ public class MirrorMakerAgent { prop.store(out, ""); } catch (Exception e) { - e.printStackTrace(); + logger.error("exception occured in checkPropertiesFile "+e); } } finally { if (input != null) { @@ -190,7 +190,7 @@ public class MirrorMakerAgent { try { out.close(); } catch (IOException e) { - e.printStackTrace(); + logger.error("exception occured in checkPropertiesFile "+e); } } } -- cgit 1.2.3-korg