From 726587ef50339f071960d153cc4599882aa71ac7 Mon Sep 17 00:00:00 2001 From: Christine Poerschke Date: Fri, 27 Jul 2018 19:30:06 -0700 Subject: [PATCH] ZOOKEEPER-3061: add more details to 'Unhandled scenario for peer' log.warn message Author: Christine Poerschke Author: Christine Poerschke Reviewers: Allan Lyu , Benjamin Reed , Norbert Kalmar Closes #555 from cpoerschke/master-ZOOKEEPER-3061 and squashes the following commits: 139968228 [Christine Poerschke] Merge remote-tracking branch 'origin/master' into master-ZOOKEEPER-3061 1840c2bb6 [Christine Poerschke] Merge remote-tracking branch 'origin/master' into master-ZOOKEEPER-3061 1d3e7bc0b [Christine Poerschke] ZOOKEEPER-3061: add more details to 'Unhandled scenario for peer' log.warn message --- .../apache/zookeeper/server/quorum/LearnerHandler.java | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/src/java/main/org/apache/zookeeper/server/quorum/LearnerHandler.java b/src/java/main/org/apache/zookeeper/server/quorum/LearnerHandler.java index f6c68b01355..023d6a63ca2 100644 --- a/src/java/main/org/apache/zookeeper/server/quorum/LearnerHandler.java +++ b/src/java/main/org/apache/zookeeper/server/quorum/LearnerHandler.java @@ -792,7 +792,14 @@ public boolean syncFollower(long peerLastZxid, ZKDatabase db, Leader leader) { txnProposalItr.close(); } } else { - LOG.warn("Unhandled scenario for peer sid: " + getSid()); + LOG.warn("Unhandled scenario for peer sid: {} maxCommittedLog=0x{}" + + " minCommittedLog=0x{} lastProcessedZxid=0x{}" + + " peerLastZxid=0x{} txnLogSyncEnabled={}", getSid(), + Long.toHexString(maxCommittedLog), + Long.toHexString(minCommittedLog), + Long.toHexString(lastProcessedZxid), + Long.toHexString(peerLastZxid), + txnLogSyncEnabled); } LOG.debug("Start forwarding 0x" + Long.toHexString(currentZxid) + " for peer sid: " + getSid());