diff options
author | Thomas Nelson Jr (arthurdent3) <tn1381@att.com> | 2018-02-20 16:50:44 -0500 |
---|---|---|
committer | Thomas Nelson Jr (arthurdent3) <tn1381@att.com> | 2018-02-20 16:50:44 -0500 |
commit | 3acbae6bf3be04f352bfaac340b8303064a2f7c4 (patch) | |
tree | ed5df3391216742cb9bfd20dc798dd5a246bc962 /src/main/java/org/onap/music/lockingservice/ProtocolSupport.java | |
parent | dffae1c7c5cd1f50e2456948942cd7716837a7f2 (diff) |
Applying bug fixes
To many overlapping changes so including all of them.
When pushing individually build was breaking.
Issue-ID: MUSIC-33,MUSIC-34,MUSIC-35,MUSIC-36,MUSIC-37
Change-Id: I15b6f7c683d0d2eeadd99c2376dedd6c43a67a8c
Signed-off-by: Thomas Nelson Jr (arthurdent3) <tn1381@att.com>
Diffstat (limited to 'src/main/java/org/onap/music/lockingservice/ProtocolSupport.java')
-rw-r--r-- | src/main/java/org/onap/music/lockingservice/ProtocolSupport.java | 11 |
1 files changed, 6 insertions, 5 deletions
diff --git a/src/main/java/org/onap/music/lockingservice/ProtocolSupport.java b/src/main/java/org/onap/music/lockingservice/ProtocolSupport.java index 37ae9e96..df4d6ad6 100644 --- a/src/main/java/org/onap/music/lockingservice/ProtocolSupport.java +++ b/src/main/java/org/onap/music/lockingservice/ProtocolSupport.java @@ -29,6 +29,7 @@ import org.apache.zookeeper.ZooDefs; import org.apache.zookeeper.ZooKeeper; import org.apache.zookeeper.data.ACL; import org.apache.zookeeper.data.Stat; +import org.onap.music.eelf.logging.EELFLoggerDelegate; import org.onap.music.lockingservice.ZooKeeperOperation; import java.util.List; import java.util.concurrent.atomic.AtomicBoolean; @@ -40,7 +41,7 @@ import java.util.concurrent.atomic.AtomicBoolean; * */ class ProtocolSupport { - private static final Logger LOG = LoggerFactory.getLogger(ProtocolSupport.class); + private EELFLoggerDelegate LOG = EELFLoggerDelegate.getLogger(ProtocolSupport.class); protected ZooKeeper zookeeper; private AtomicBoolean closed = new AtomicBoolean(false); @@ -128,7 +129,7 @@ class ProtocolSupport { try { return operation.execute(); } catch (KeeperException.SessionExpiredException e) { - LOG.warn("Session expired for: " + zookeeper + " so reconnecting due to: " + e, e); + LOG.debug("Session expired for: " + zookeeper + " so reconnecting due to: " + e, e); throw e; } catch (KeeperException.ConnectionLossException e) { if (exception == null) { @@ -173,9 +174,9 @@ class ProtocolSupport { } }); } catch (KeeperException e) { - LOG.warn("Caught: " + e, e); + LOG.error(EELFLoggerDelegate.errorLogger,"Caught: " + e, e); } catch (InterruptedException e) { - LOG.warn("Caught: " + e, e); + LOG.error(EELFLoggerDelegate.errorLogger,"Caught: " + e, e); } } @@ -198,7 +199,7 @@ class ProtocolSupport { try { Thread.sleep(attemptCount * retryDelay); } catch (InterruptedException e) { - LOG.debug("Failed to sleep: " + e, e); + LOG.error(EELFLoggerDelegate.errorLogger,"Failed to sleep: " + e, e); } } } |