jiajunwang commented on a change in pull request #688: Fix the watcher leakage 
issue
URL: https://github.com/apache/helix/pull/688#discussion_r375670413
 
 

 ##########
 File path: 
helix-core/src/test/java/org/apache/helix/manager/zk/client/TestHelixZkClient.java
 ##########
 @@ -163,6 +163,8 @@ public void handleDataDeleted(String s) {
       // expected to be here.
     }
 
+    // client B needs to re-install the data watch
+    sharedZkClientB.watchForData(TEST_PATH);
 
 Review comment:
   Usually, I'm very cautious about changing the existing test case. This 
indicates that we changed the behavior. So after this change, the user will 
need to resubscribe the watch once it is deleted, right? Regardless of the 
Helix reserved node that has children change listeners to cover, how about the 
other zk path that we allow the user to subscribe listener? The listeners will 
be idle after the node has been removed once, right? This breaks the feature 
IMO.
   
   Overall, I think we will need to make it optional. 1. It is fine that we 
change the behavior for the reserved patch with additional children change 
listener on the parent node. But for the other random path from user's 
requests, we should keep the old behavior.

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


With regards,
Apache Git Services

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

Reply via email to