public interface LeaderElection extends LeaderElectionObserver
| Modifier and Type | Method and Description |
|---|---|
void |
cycle()
Relinquishes the candidate's current standing (possibly as the leader) and
demotes the candidate to the last position.
|
void |
enter()
Adds the current host to the election if it is not there already.
|
void |
withdraw()
Completely removes the candidate from the election.
|
getLeadervoid enter()
throws InterruptedException,
org.apache.zookeeper.KeeperException
InterruptedExceptionorg.apache.zookeeper.KeeperExceptionvoid withdraw()
throws InterruptedException,
org.apache.zookeeper.KeeperException
InterruptedExceptionorg.apache.zookeeper.KeeperExceptionvoid cycle()
throws InterruptedException,
org.apache.zookeeper.KeeperException
InterruptedExceptionorg.apache.zookeeper.KeeperExceptionCopyright © 2012–2015 Facebook, Inc.. All rights reserved.