You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@curator.apache.org by "Henrik Nordvik (JIRA)" <ji...@apache.org> on 2013/08/29 14:54:54 UTC
[jira] [Created] (CURATOR-51) LeaderSelector with custom Executor
does not guarantee unique leadership
Henrik Nordvik created CURATOR-51:
-------------------------------------
Summary: LeaderSelector with custom Executor does not guarantee unique leadership
Key: CURATOR-51
URL: https://issues.apache.org/jira/browse/CURATOR-51
Project: Apache Curator
Issue Type: Bug
Reporter: Henrik Nordvik
Assignee: Jordan Zimmerman
Priority: Minor
When providing a custom executor to the leader selector it creates a thread that waits for leadership.
When it has leadership, it submits a runnable to the custom executor and then release leadership.
If the executor is is e.g. a ThreadPoolExecutor, the takeLeadership method is executed asynchrounously, after releasing leadership.
Is this a bug or am I missing the point of using my own executor?
I have attached an example which shows multiple leaders being elected at the same time.
(The example uses curator 1.3.3, but I think it is the same in 2.x)
--
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