zookeeper-notifications mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From GitBox <...@apache.org>
Subject [GitHub] [zookeeper] enixon commented on a change in pull request #1100: ZOOKEEPER-3509: Revisit log format
Date Mon, 30 Sep 2019 18:01:01 GMT
enixon commented on a change in pull request #1100: ZOOKEEPER-3509: Revisit log format
URL: https://github.com/apache/zookeeper/pull/1100#discussion_r329701560
 
 

 ##########
 File path: zookeeper-server/src/main/java/org/apache/zookeeper/server/quorum/Learner.java
 ##########
 @@ -441,11 +450,11 @@ protected void syncWithLeader(long newLeaderZxid) throws Exception
{
             } else if (qp.getType() == Leader.TRUNC) {
                 //we need to truncate the log to the lastzxid of the leader
                 self.setSyncMode(QuorumPeer.SyncMode.TRUNC);
-                LOG.warn("Truncating log to get in sync with the leader 0x" + Long.toHexString(qp.getZxid()));
+                LOG.warn("Truncating log to get in sync with the leader 0x{}", Long.toHexString(qp.getZxid()));
                 boolean truncated = zk.getZKDatabase().truncateLog(qp.getZxid());
                 if (!truncated) {
                     // not able to truncate the log
-                    LOG.error("Not able to truncate the log " + Long.toHexString(qp.getZxid()));
+                    LOG.error("Not able to truncate the log {}", Long.toHexString(qp.getZxid()));
 
 Review comment:
   Add "0x"?

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
users@infra.apache.org


With regards,
Apache Git Services

Mime
View raw message