From b2f6cabb2d2b96bf334788f106cfee0ceb5feff1 Mon Sep 17 00:00:00 2001 From: Tom Pantelis Date: Wed, 8 Jun 2016 03:30:33 -0400 Subject: [PATCH] Debug logging in AbstractLeader is too chatty The additional debug logging added with https://git.opendaylight.org/gerrit/#/c/39796/ makes it too chatty with heartbeats when nothing changed which will roll-over log files much more quickly. Changed a debug to trace. Change-Id: I4c204c6d0734d6ac8655380adcc2df09cb2890ae Signed-off-by: Tom Pantelis --- .../controller/cluster/raft/behaviors/AbstractLeader.java | 6 +++--- .../src/test/resources/simplelogger.properties | 2 +- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/opendaylight/md-sal/sal-akka-raft/src/main/java/org/opendaylight/controller/cluster/raft/behaviors/AbstractLeader.java b/opendaylight/md-sal/sal-akka-raft/src/main/java/org/opendaylight/controller/cluster/raft/behaviors/AbstractLeader.java index 104654cb12..a1ec4d8831 100644 --- a/opendaylight/md-sal/sal-akka-raft/src/main/java/org/opendaylight/controller/cluster/raft/behaviors/AbstractLeader.java +++ b/opendaylight/md-sal/sal-akka-raft/src/main/java/org/opendaylight/controller/cluster/raft/behaviors/AbstractLeader.java @@ -268,8 +268,8 @@ public abstract class AbstractLeader extends AbstractRaftActorBehavior { final PeerInfo peerInfo = context.getPeerInfo(info.getId()); if(info.getMatchIndex() >= N && (peerInfo != null && peerInfo.isVoting())) { replicatedCount++; - } else if(LOG.isDebugEnabled()) { - LOG.debug("{}: Not counting follower {} - matchIndex: {}, {}", logName(), info.getId(), + } else if(LOG.isTraceEnabled()) { + LOG.trace("{}: Not counting follower {} - matchIndex: {}, {}", logName(), info.getId(), info.getMatchIndex(), peerInfo); } } @@ -299,7 +299,7 @@ public abstract class AbstractLeader extends AbstractRaftActorBehavior { logName(), N, replicatedLogEntry.getIndex(), replicatedLogEntry.getTerm(), currentTerm()); } } else { - LOG.trace("{}: minReplicationCount not reached - breaking", logName()); + LOG.trace("{}: minReplicationCount not reached, actual {} - breaking", logName(), replicatedCount); break; } } diff --git a/opendaylight/md-sal/sal-akka-raft/src/test/resources/simplelogger.properties b/opendaylight/md-sal/sal-akka-raft/src/test/resources/simplelogger.properties index 853fc755d2..bb24c8fe51 100644 --- a/opendaylight/md-sal/sal-akka-raft/src/test/resources/simplelogger.properties +++ b/opendaylight/md-sal/sal-akka-raft/src/test/resources/simplelogger.properties @@ -3,4 +3,4 @@ org.slf4j.simpleLogger.dateTimeFormat=hh:mm:ss,S a org.slf4j.simpleLogger.logFile=System.out org.slf4j.simpleLogger.showShortLogName=true org.slf4j.simpleLogger.levelInBrackets=true -org.slf4j.simpleLogger.log.org.opendaylight.controller.cluster.raft=trace \ No newline at end of file +org.slf4j.simpleLogger.log.org.opendaylight.controller.cluster.raft=debug \ No newline at end of file -- 2.36.6