zookeeper-notifications mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From GitBox <...@apache.org>
Subject [GitHub] [zookeeper] hanm commented on a change in pull request #958: ZOOKEEPER-1523: Better logging during instance loading/syncing
Date Fri, 28 Jun 2019 23:16:54 GMT
hanm commented on a change in pull request #958: ZOOKEEPER-1523: Better logging during instance
loading/syncing
URL: https://github.com/apache/zookeeper/pull/958#discussion_r298772062
 
 

 ##########
 File path: zookeeper-server/src/main/java/org/apache/zookeeper/server/quorum/QuorumPeer.java
 ##########
 @@ -416,6 +416,22 @@ public void checkAddressDuplicate(QuorumServer s) throws BadArgumentsException
{
         LOOKING, FOLLOWING, LEADING, OBSERVING;
     }
 
+    /**
+     * (Used for monitoring) When peer is in non-LOOKING phase, this shows the
+     * current phase of Zab protocol that peer is running.
+     */
+    public enum ZabState {
+        NONE, DISCOVERY, SYNCHRONIZATION, BROADCAST;
 
 Review comment:
   Do we need 'NONE' here? As the comment said, ZAB is only relevant for non-looking phase,
but later in the code we are setting the state to 'NONE' for non looking peer. I guess we
could:
   * Update comment saying 'NONE' maps to the looking phase
   Or 
   * Remove 'NONE' from the state (which might be more consistent with traditional ZAB literatures),
and don't set the zab state for looking peers.
   

----------------------------------------------------------------
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