public interface Discovery extends LifecycleComponent
Modifier and Type | Interface and Description |
---|---|
static interface |
Discovery.AckListener |
static class |
Discovery.FailedToCommitClusterStateException |
Modifier and Type | Method and Description |
---|---|
DiscoverySettings |
getDiscoverySettings() |
int |
getMinimumMasterNodes() |
DiscoveryNode |
localNode() |
java.lang.String |
nodeDescription() |
void |
publish(ClusterChangedEvent clusterChangedEvent,
Discovery.AckListener ackListener)
Publish all the changes to the cluster from the master (can be called just by the master).
|
void |
setAllocationService(AllocationService allocationService)
Another hack to solve dep injection problem..., note, this will be called before
any start is called.
|
void |
startInitialJoin()
Triggers the first join cycle
|
DiscoveryStats |
stats() |
addLifecycleListener, lifecycleState, removeLifecycleListener, start, stop
close
DiscoveryNode localNode()
java.lang.String nodeDescription()
void setAllocationService(AllocationService allocationService)
void publish(ClusterChangedEvent clusterChangedEvent, Discovery.AckListener ackListener)
Discovery.AckListener
allows to keep track of the ack received from nodes, and verify whether
they updated their own cluster state or not.
The method is guaranteed to throw a Discovery.FailedToCommitClusterStateException
if the change is not committed and should be rejected.
Any other exception signals the something wrong happened but the change is committed.DiscoveryStats stats()
DiscoverySettings getDiscoverySettings()
void startInitialJoin()
int getMinimumMasterNodes()