pkuwm commented on a change in pull request #1119:
URL: https://github.com/apache/helix/pull/1119#discussion_r457665020



##########
File path: 
zookeeper-api/src/main/java/org/apache/helix/zookeeper/zkclient/ZkClient.java
##########
@@ -63,6 +68,10 @@
 import org.slf4j.Logger;
 import org.slf4j.LoggerFactory;
 
+import static org.apache.zookeeper.KeeperException.Code.CONNECTIONLOSS;
+import static org.apache.zookeeper.KeeperException.Code.OK;
+import static org.apache.zookeeper.KeeperException.Code.SESSIONMOVED;

Review comment:
       Don't forget to remove these unused static imports.
   
   FYI, actually I would prefer not to import the static constant. You could 
just use `KeeperException.Code.CONNECTIONLOSS` for better readability. Ref: 
https://docs.oracle.com/javase/7/docs/technotes/guides/language/static-import.html

##########
File path: 
zookeeper-api/src/main/java/org/apache/helix/zookeeper/zkclient/ZkClient.java
##########
@@ -74,6 +83,7 @@
 public class ZkClient implements Watcher {
   private static Logger LOG = LoggerFactory.getLogger(ZkClient.class);
   private static long MAX_RECONNECT_INTERVAL_MS = 30000; // 30 seconds
+  private static String ZK_AUTOSYNC_ENABLED_DEFAULT = "true";

Review comment:
       static **final**?

##########
File path: 
zookeeper-api/src/main/java/org/apache/helix/zookeeper/zkclient/ZkClient.java
##########
@@ -105,6 +115,9 @@
   // ZkEventThread. Otherwise the retry request might block the normal event 
processing.
   protected final ZkAsyncRetryThread _asyncCallRetryThread;
 
+  private final boolean _syncOnNewSession;
+  private final String _syncPath = "/";

Review comment:
       I think it is better to make it a constant: static final SYNC_PATH?




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