Package io.aeron.cluster
Class ClusterControl
java.lang.Object
io.aeron.cluster.ClusterControl
Toggle control
ClusterControl.ToggleStates for a cluster node such as ClusterControl.ToggleState.SUSPEND or
ClusterControl.ToggleState.RESUME. This can only be applied to the Cluster.Role.LEADER.-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic enumToggle states for controlling the cluster node once it has entered the active state after initialising. -
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final intCounter type id for the control toggle. -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionstatic AtomicCounterfindControlToggle(CountersReader counters, int clusterId) Find the control toggle counter or return null if not found.static voidMain method for launching the process.static CountersReadermapCounters(File cncFile) Map aCountersReaderover the providedFilefor the CnC file.
-
Field Details
-
CONTROL_TOGGLE_TYPE_ID
public static final int CONTROL_TOGGLE_TYPE_IDCounter type id for the control toggle.- See Also:
-
-
Constructor Details
-
ClusterControl
public ClusterControl()
-
-
Method Details
-
mapCounters
Map aCountersReaderover the providedFilefor the CnC file.- Parameters:
cncFile- for the counters.- Returns:
- a
CountersReaderover the provided CnC file.
-
findControlToggle
Find the control toggle counter or return null if not found.- Parameters:
counters- to search within.clusterId- to which the allocated counter belongs.- Returns:
- the control toggle counter or return null if not found.
-
main
Main method for launching the process.- Parameters:
args- passed to the process.
-