kaisun2000 commented on a change in pull request #1328:
URL: https://github.com/apache/helix/pull/1328#discussion_r486738697



##########
File path: 
helix-core/src/main/java/org/apache/helix/tools/ClusterVerifiers/ZkHelixClusterVerifier.java
##########
@@ -19,6 +19,7 @@
  * under the License.
  */
 
+import java.util.Arrays;

Review comment:
       removed.

##########
File path: 
helix-core/src/main/java/org/apache/helix/tools/ClusterVerifiers/ZkHelixClusterVerifier.java
##########
@@ -234,6 +236,9 @@ protected boolean verifyByCallback(long timeout, 
List<ClusterVerifyTrigger> trig
         if (!success) {
           // make a final try if timeout
           success = verifyState();
+          if (!success) {
+            LOG.error("verifyByCallback failed due to timeout");

Review comment:
       fixed.

##########
File path: 
helix-core/src/main/java/org/apache/helix/tools/ClusterVerifiers/BestPossibleExternalViewVerifier.java
##########
@@ -105,7 +105,7 @@ public BestPossibleExternalViewVerifier(RealmAwareZkClient 
zkClient, String clus
     _dataProvider = new ResourceControllerDataProvider();
   }
 
-  private BestPossibleExternalViewVerifier(RealmAwareZkClient zkClient, String 
clusterName,
+  protected BestPossibleExternalViewVerifier(RealmAwareZkClient zkClient, 
String clusterName,

Review comment:
       refactored.

##########
File path: 
helix-core/src/main/java/org/apache/helix/tools/ClusterVerifiers/BestPossibleExternalViewVerifier.java
##########
@@ -224,12 +224,15 @@ public boolean verifyByZkCallback(long timeout) {
   @Override
   protected synchronized boolean verifyState() {
     try {
+      LOG.debug("Verifier start verifyState at {}", 
System.currentTimeMillis());

Review comment:
       removed all

##########
File path: 
helix-core/src/main/java/org/apache/helix/tools/ClusterVerifiers/ZkHelixClusterVerifier.java
##########
@@ -335,6 +352,11 @@ public B setZkAddr(String zkAddress) {
       return setZkAddress(zkAddress);
     }
 
+    public B setWaitTillVerify(int waitPeriod) {
+      _coolDown = waitPeriod;

Review comment:
       changed

##########
File path: 
helix-core/src/main/java/org/apache/helix/tools/ClusterVerifiers/ZkHelixClusterVerifier.java
##########
@@ -187,6 +190,14 @@ public boolean verifyByZkCallback() {
    * @return
    */
   public boolean verifyByPolling(long timeout, long period) {

Review comment:
       make sense.

##########
File path: 
helix-core/src/main/java/org/apache/helix/tools/ClusterVerifiers/ZkHelixClusterVerifier.java
##########
@@ -19,6 +19,7 @@
  * under the License.
  */
 
+import java.util.Arrays;

Review comment:
       removed.

##########
File path: 
helix-core/src/main/java/org/apache/helix/tools/ClusterVerifiers/ZkHelixClusterVerifier.java
##########
@@ -234,6 +236,9 @@ protected boolean verifyByCallback(long timeout, 
List<ClusterVerifyTrigger> trig
         if (!success) {
           // make a final try if timeout
           success = verifyState();
+          if (!success) {
+            LOG.error("verifyByCallback failed due to timeout");

Review comment:
       fixed.

##########
File path: 
helix-core/src/main/java/org/apache/helix/tools/ClusterVerifiers/BestPossibleExternalViewVerifier.java
##########
@@ -105,7 +105,7 @@ public BestPossibleExternalViewVerifier(RealmAwareZkClient 
zkClient, String clus
     _dataProvider = new ResourceControllerDataProvider();
   }
 
-  private BestPossibleExternalViewVerifier(RealmAwareZkClient zkClient, String 
clusterName,
+  protected BestPossibleExternalViewVerifier(RealmAwareZkClient zkClient, 
String clusterName,

Review comment:
       refactored.

##########
File path: 
helix-core/src/main/java/org/apache/helix/tools/ClusterVerifiers/BestPossibleExternalViewVerifier.java
##########
@@ -224,12 +224,15 @@ public boolean verifyByZkCallback(long timeout) {
   @Override
   protected synchronized boolean verifyState() {
     try {
+      LOG.debug("Verifier start verifyState at {}", 
System.currentTimeMillis());

Review comment:
       removed all

##########
File path: 
helix-core/src/main/java/org/apache/helix/tools/ClusterVerifiers/ZkHelixClusterVerifier.java
##########
@@ -335,6 +352,11 @@ public B setZkAddr(String zkAddress) {
       return setZkAddress(zkAddress);
     }
 
+    public B setWaitTillVerify(int waitPeriod) {
+      _coolDown = waitPeriod;

Review comment:
       changed

##########
File path: 
helix-core/src/main/java/org/apache/helix/tools/ClusterVerifiers/ZkHelixClusterVerifier.java
##########
@@ -187,6 +190,14 @@ public boolean verifyByZkCallback() {
    * @return
    */
   public boolean verifyByPolling(long timeout, long period) {

Review comment:
       make sense.




----------------------------------------------------------------
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:
[email protected]



---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to