yangyichao-mango commented on a change in pull request #3244:
URL: 
https://github.com/apache/incubator-dolphinscheduler/pull/3244#discussion_r457024287



##########
File path: 
dolphinscheduler-server/src/main/java/org/apache/dolphinscheduler/server/master/registry/MasterRegistry.java
##########
@@ -83,19 +83,6 @@ public void registry() {
         String address = NetUtils.getHost();
         String localNodePath = getMasterPath();
         
zookeeperRegistryCenter.getZookeeperCachedOperator().persistEphemeral(localNodePath,
 "");
-        
zookeeperRegistryCenter.getZookeeperCachedOperator().getZkClient().getConnectionStateListenable().addListener(new
 ConnectionStateListener() {
-            @Override
-            public void stateChanged(CuratorFramework client, ConnectionState 
newState) {
-                if(newState == ConnectionState.LOST){
-                    logger.error("master : {} connection lost from zookeeper", 
address);
-                } else if(newState == ConnectionState.RECONNECTED){
-                    logger.info("master : {} reconnected to zookeeper", 
address);
-                    
zookeeperRegistryCenter.getZookeeperCachedOperator().persistEphemeral(localNodePath,
 "");
-                } else if(newState == ConnectionState.SUSPENDED){
-                    logger.warn("master : {} connection SUSPENDED ", address);
-                }
-            }
-        });

Review comment:
       > Hi,
   > Good job,
   > But why we need to delete the state changed and log for record the master 
address from `MasterRegistry`?
   
   Actually the CuratorZookeeperClient log will lost the `log for record the 
master address` information. And I think the master zk address info is 
important for user to debug. Can you add the address info in 
`CuratorZookeeperClient`?




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


Reply via email to