curator-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Jordan Zimmerman (JIRA)" <>
Subject [jira] [Commented] (CURATOR-110) LeaderLatch does not complete if it is started without a connection to ZooKeeper
Date Tue, 17 Jun 2014 19:37:01 GMT


Jordan Zimmerman commented on CURATOR-110:

FYI - I made a few changes:

* I renamed ExecuteAfterConnectionEstablished to make it a bit more clear
* LeaderLatch's handleStateChange no longer does anything on CONNECTED as this is handled
by ExecuteAfterConnectionEstablished
* Moved the connection blocking code into ConnectionManager. It's cleaner and doesn't require
a connection state listener
* ExecuteAfterConnectionEstablished returns the future created by the executor. It's needed
so users can cancel the operation if needed.

> LeaderLatch does not complete if it is started without a connection to ZooKeeper
> --------------------------------------------------------------------------------
>                 Key: CURATOR-110
>                 URL:
>             Project: Apache Curator
>          Issue Type: Bug
>          Components: Recipes
>    Affects Versions: 2.5.0
>            Reporter: Cameron McKenzie
>            Priority: Minor
>              Labels: connection, latch, leader
>             Fix For: 2.6.0
>   Original Estimate: 24h
>  Remaining Estimate: 24h
> Given the following conditions:
> 1.) No connection is available to ZK
> 2.) A LeaderLatch is created and started
> 3.) All retries for the leader latch creating its ephemeral zNode have been exhausted.
> At this point the LeaderLatch will not begin functioning correctly when a connection
is established. This is due to it ignoring 'CONNECTED' connection state events (it only handles
> The fix should simply be a case of making the state handling for CONNECTED and RECONNECTED
the same.

This message was sent by Atlassian JIRA

View raw message