diff options
author | Sooriyaa <soponraj@in.ibm.com> | 2018-08-24 14:29:31 +0530 |
---|---|---|
committer | Sooriyaa p.r <soponraj@in.ibm.com> | 2018-08-28 06:13:45 +0000 |
commit | 33c2762822f77bf5f08a33248f96571cc5cff6de (patch) | |
tree | 714f160a95ab28ac029eb62aa3b000b397f6e520 | |
parent | 5b405672f47c86b53aa094057afb5c21b4cd961a (diff) |
Adding a constant to remove duplicate string
Adding a constant to remove duplicate string
Issue-ID: VFC-1074
Change-Id: Ibf6b61dc5ef8b547277861aad6ffe5d5bb8a479c
Signed-off-by: Sooriyaa <soponraj@in.ibm.com>
-rw-r--r-- | ems/boco/src/main/java/org/onap/vfc/nfvo/emsdriver/collector/TaskThread.java | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/ems/boco/src/main/java/org/onap/vfc/nfvo/emsdriver/collector/TaskThread.java b/ems/boco/src/main/java/org/onap/vfc/nfvo/emsdriver/collector/TaskThread.java index 2e8656d..3b20f2c 100644 --- a/ems/boco/src/main/java/org/onap/vfc/nfvo/emsdriver/collector/TaskThread.java +++ b/ems/boco/src/main/java/org/onap/vfc/nfvo/emsdriver/collector/TaskThread.java @@ -51,6 +51,7 @@ public class TaskThread implements Runnable { private String resultPath = Constant.SYS_DATA_RESULT; private SimpleDateFormat dateFormat = new SimpleDateFormat("yyyyMMddHHmmss"); private SimpleDateFormat dateFormat2 = new SimpleDateFormat("yyyy-MM-dd HH:mm:ss"); + public static final String PORT_STRING = "] port=["; public TaskThread(CollectMsg data) { this.data = data; @@ -567,7 +568,7 @@ public class TaskThread implements Runnable { ftpClient.login(ip, Integer.parseInt(port), ftpUser, ftpPassword, "GBK", Boolean.parseBoolean(ftpPassive), 5 * 60 * 1000); } catch (Exception e) { - log.error("login fail,ip=[" + ip + "] port=[" + port + "] user=[" + log.error("login fail,ip=[" + ip + PORT_STRING + port + "] user=[" + ftpUser + "]pwd=[" + ftpPassword + "]" + StringUtil.getStackTrace(e)); return; @@ -740,12 +741,12 @@ public class TaskThread implements Runnable { // login try { - log.info("ftp login ,ip=[" + ip + "] port=[" + port + "] user=[" + log.info("ftp login ,ip=[" + ip + PORT_STRING + port + "] user=[" + user + /* "]password=[" + password + */"]"); ftpClient.login(ip, Integer.parseInt(port), user, password, "GBK", Boolean.parseBoolean(passivemode), 5 * 60 * 1000); } catch (Exception e) { - log.error("login fail,ip=[" + ip + "] port=[" + port + "] user=[" + log.error("login fail,ip=[" + ip + PORT_STRING + port + "] user=[" + user + /* "]password=[" + password + */"]" + StringUtil.getStackTrace(e)); return fileList; |