Package org.apache.solr.cloud
Class ElectionContext
- java.lang.Object
-
- org.apache.solr.cloud.ElectionContext
-
- All Implemented Interfaces:
Closeable
,AutoCloseable
public abstract class ElectionContext extends Object implements Closeable
-
-
Constructor Summary
Constructors Constructor Description ElectionContext(String coreNodeName, String electionPath, String leaderPath, ZkNodeProps leaderProps, SolrZkClient zkClient)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description void
cancelElection()
void
checkIfIamLeaderFired()
void
close()
ElectionContext
copy()
void
joinedElectionFired()
-
-
-
Constructor Detail
-
ElectionContext
public ElectionContext(String coreNodeName, String electionPath, String leaderPath, ZkNodeProps leaderProps, SolrZkClient zkClient)
-
-
Method Detail
-
close
public void close()
- Specified by:
close
in interfaceAutoCloseable
- Specified by:
close
in interfaceCloseable
-
cancelElection
public void cancelElection() throws InterruptedException, org.apache.zookeeper.KeeperException
- Throws:
InterruptedException
org.apache.zookeeper.KeeperException
-
checkIfIamLeaderFired
public void checkIfIamLeaderFired()
-
joinedElectionFired
public void joinedElectionFired()
-
copy
public ElectionContext copy()
-
-