summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorajay priyadarshi <ajay.priyadarshi@ril.com>2018-02-19 12:15:58 +0530
committerajay priyadarshi <ajay.priyadarshi@ril.com>2018-02-19 12:15:58 +0530
commit145263833784b9a203876460b15f7a29f39342bc (patch)
treedc6cb2decf0d12cd8791bdab6cd0419372c19c1d
parent6ce7073003c176956e879888f7c7cf0144833a9e (diff)
sonar fix: Exception handling in NorthMessageMgr
5 sonar issues have been handled file name: NorthMessageMgr.java Change-Id: I11dddc33a0fbde4bf9e6efe6ae79d586dc67c8cb Issue-ID: VFC-769 Signed-off-by: ajay priyadarshi <ajay.priyadarshi@ril.com>
-rw-r--r--ems/boco/src/main/java/org/onap/vfc/nfvo/emsdriver/northbound/client/NorthMessageMgr.java16
1 files changed, 9 insertions, 7 deletions
diff --git a/ems/boco/src/main/java/org/onap/vfc/nfvo/emsdriver/northbound/client/NorthMessageMgr.java b/ems/boco/src/main/java/org/onap/vfc/nfvo/emsdriver/northbound/client/NorthMessageMgr.java
index aa01c99..feb6679 100644
--- a/ems/boco/src/main/java/org/onap/vfc/nfvo/emsdriver/northbound/client/NorthMessageMgr.java
+++ b/ems/boco/src/main/java/org/onap/vfc/nfvo/emsdriver/northbound/client/NorthMessageMgr.java
@@ -68,7 +68,7 @@ public class NorthMessageMgr extends DriverThread {
//login north
event_api_url = "http://" + event_api_url;
log.info("AgentMain.evel_initialize start event_api_url=[" + event_api_url + "]port=[" + port + "]path=[" + path + "]"
- + "topic=[" + topic + "]username=[" + username + "]password=[" + password + "]level=[" + level + "]");
+ + "topic=[" + topic + "]username=[" + username + /*"]password=[" + password +*/ "]level=[" + level + "]");
try {
EVEL_ERR_CODES evecode = AgentMain.evel_initialize(event_api_url, Integer.parseInt(port),
path, topic,
@@ -78,9 +78,9 @@ public class NorthMessageMgr extends DriverThread {
log.info("AgentMain.evel_initialize sucess EVEL_ERR_CODES=" + evecode);
} catch (Exception e) {
log.error("AgentMain.evel_initialize fail ", e);
- } catch (Error e1) {
+ }/* catch (Error e1) {
log.error("AgentMain.evel_initialize Error ", e1);
- }
+ }*/
} catch (Exception e2) {
log.error("NorthMessageMgr start fail ", e2);
}
@@ -126,7 +126,8 @@ public class NorthMessageMgr extends DriverThread {
try {
Thread.sleep(60 * 1000);
} catch (Exception e) {
- e.printStackTrace();
+ // e.printStackTrace();
+ log.error("Unable to sleep the HB thread ", e);
}
} catch (Exception e) {
log.error("HeatBeatTread exception", e);
@@ -224,7 +225,8 @@ public class NorthMessageMgr extends DriverThread {
eventTimeD = format.parse(eventTime);
} catch (ParseException e) {
// TODO Auto-generated catch block
- e.printStackTrace();
+ //e.printStackTrace();
+ log.error("ParseException ", e);
}
flt.evel_start_epoch_set(eventTimeD.getTime());
flt.evel_last_epoch_set(eventTimeD.getTime());
@@ -314,9 +316,9 @@ public class NorthMessageMgr extends DriverThread {
} catch (Exception e) {
log.error("CollectMessageRecv exception", e);
- } catch (Error e) {
+ } /*catch (Error e) {
log.error("CollectMessageRecv Error", e);
- }
+ }*/
}
}