You are viewing a plain text version of this content. The canonical link for it is here.
Posted to reviews@helix.apache.org by GitBox <gi...@apache.org> on 2020/12/04 02:45:54 UTC

[GitHub] [helix] narendly commented on a change in pull request #1562: Fix ZkClient leakage by correctly setting usesExternalZkClient flag

narendly commented on a change in pull request #1562:
URL: https://github.com/apache/helix/pull/1562#discussion_r535795170



##########
File path: helix-core/src/main/java/org/apache/helix/manager/zk/ZkBaseDataAccessor.java
##########
@@ -134,14 +134,13 @@ public AccessResult() {
    */
   @Deprecated
   public ZkBaseDataAccessor(RealmAwareZkClient zkClient) {
-    if (zkClient == null) {
-      throw new NullPointerException("zkclient is null");
-    }
-    _zkClient = zkClient;
-    _usesExternalZkClient = true;
+    this(zkClient, true);
   }
 
   private ZkBaseDataAccessor(RealmAwareZkClient zkClient, boolean usesExternalZkClient) {
+    if (zkClient == null) {
+      throw new NullPointerException("zkclient is null");

Review comment:
       Yes. Good catch.




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



---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@helix.apache.org
For additional commands, e-mail: reviews-help@helix.apache.org