You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@helix.apache.org by "Hudson (JIRA)" <ji...@apache.org> on 2013/02/04 09:24:12 UTC

[jira] [Commented] (HELIX-40) fix zkclient subscribe path leaking and zk callback-handler leaking in case of session expiry

    [ https://issues.apache.org/jira/browse/HELIX-40?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13570059#comment-13570059 ] 

Hudson commented on HELIX-40:
-----------------------------

Integrated in helix #525 (See [https://builds.apache.org/job/helix/525/])
    HELIX-40: fix zkclient subscribe path leaking and zk callback-handler leaking in case of session expiry (Revision 03423e6248fb970251c4443ddba94fac79076d93)

     Result = UNSTABLE
zzhang : 
Files : 
* helix-core/src/test/java/org/apache/helix/manager/zk/TestLiveInstanceBounce.java
* helix-core/src/test/java/org/apache/helix/participant/MockZKHelixManager.java
* helix-core/src/test/java/org/apache/helix/controller/stages/DummyClusterManager.java
* helix-core/src/test/java/org/apache/helix/ZkTestHelper.java
* helix-core/src/main/java/org/apache/helix/controller/HelixControllerMain.java
* helix-core/src/main/java/org/apache/helix/manager/zk/CallbackHandler.java
* helix-core/src/test/java/org/apache/helix/Mocks.java
* helix-core/src/test/java/org/apache/helix/mock/participant/MockParticipant.java
* helix-core/src/main/java/org/apache/helix/manager/zk/ZKHelixManager.java
* helix-core/src/main/java/org/apache/helix/participant/GenericLeaderStandbyModel.java
* helix-core/src/main/java/org/apache/helix/HelixManager.java
* helix-core/src/test/java/org/apache/helix/mock/controller/ClusterController.java
* helix-core/src/test/java/org/apache/helix/manager/zk/TestZkClusterManager.java
* helix-core/src/main/java/org/apache/helix/controller/GenericHelixController.java
* helix-core/src/test/java/org/apache/helix/integration/TestZkCallbackHandlerLeak.java

                
> fix zkclient subscribe path leaking and zk callback-handler leaking in case of session expiry
> ---------------------------------------------------------------------------------------------
>
>                 Key: HELIX-40
>                 URL: https://issues.apache.org/jira/browse/HELIX-40
>             Project: Apache Helix
>          Issue Type: Bug
>            Reporter: dafu
>            Assignee: dafu
>
> zkclient subscribe path leaking:
> when a zk-path is deleted, zookeeper client will auto remove watchers from it watch set, but we also need to remove zk paths from zkclient's subscribe path set. this is achieved by calling zkclient.unsubscribe() whenever there is a zk path deleted.
> zk callback handler leaking:
> current-state listener and message listener are added during on-live-instance-change. we are not removing current-state listener and message listener when an instance is gone or a session is expired. the solution is keep a cache to remember what live-instance we saw last time, and upon live-instance change, we compare the current live-instance list against this cache. remove current-state and message listener that belongs to instance/session that are no longer valid.
> we also need to clear the callback-handler list in zk-helix-manager during handle-new-session.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira