public interface ClusterManager extends ClusterInfo
| Modifier and Type | Field and Description |
|---|---|
static String |
ALL_NODES |
static String |
ANY_NODE |
| Modifier and Type | Method and Description |
|---|---|
void |
checkIndex() |
List<Node> |
findActiveAndNotAliveNodes() |
Collection<Node> |
findLiveNodes()
Returns a snapshot of the live nodes.
|
List<Node> |
findOfflineNodes() |
Set<Node> |
getAllNodes()
Returns all the nodes in the cluster.
|
boolean |
isActive() |
boolean |
isClusterLicensed()
Returns whether or not JIRA is licensed for clustered configurations.
|
boolean |
isNodeActive(@NotNull String nodeId) |
boolean |
isNodeAlive(@NotNull String nodeId) |
boolean |
isNodeOffline(@NotNull String nodeId) |
boolean |
isNodePresent(@NotNull String id) |
List<String> |
moveNodesToOfflineIfOlderThan(@NotNull java.time.Duration retentionPeriod)
Update nodes's state to
Node.NodeState.OFFLINE if current node's state is Node.NodeState.ACTIVE and Not Alive for specified retention period |
void |
moveToOffline(@NotNull String nodeId)
Update nodes's state to
Node.NodeState.OFFLINE if current state is Node.NodeState.ACTIVE and Not Alive |
void |
refreshLiveNodes()
Merges the information from the heartbeat table and the clusternode table
to give accurate information of which nodes are alive.
|
void |
removeIfOffline(@NotNull String nodeId)
Remove node from cluster if node is
Node.NodeState.OFFLINE |
List<String> |
removeOfflineNodesIfOlderThan(@NotNull java.time.Duration retentionPeriod)
Remove node from cluster if node is in
Node.NodeState.OFFLINE state for specified retention period |
void |
requestCurrentIndexFromNode(String node)
We send a message to the node we wish a copy from.
|
getNodeId, isClusteredstatic final String ALL_NODES
static final String ANY_NODE
void checkIndex()
boolean isActive()
Set<Node> getAllNodes()
Nodes in a clusterboolean isClusterLicensed()
void requestCurrentIndexFromNode(String node)
node - Node to send the message to get an Index Copy from.Collection<Node> findLiveNodes()
void refreshLiveNodes()
void removeIfOffline(@NotNull
@NotNull String nodeId)
throws ClusterStateException
Node.NodeState.OFFLINEClusterStateException - if node is not offlineList<String> removeOfflineNodesIfOlderThan(@NotNull @NotNull java.time.Duration retentionPeriod)
Node.NodeState.OFFLINE state for specified retention periodvoid moveToOffline(@NotNull
@NotNull String nodeId)
throws ClusterStateException
Node.NodeState.OFFLINE if current state is Node.NodeState.ACTIVE and Not AliveClusterStateException - if node is aliveList<String> moveNodesToOfflineIfOlderThan(@NotNull @NotNull java.time.Duration retentionPeriod)
Node.NodeState.OFFLINE if current node's state is Node.NodeState.ACTIVE and Not Alive for specified retention periodNode.NodeState.OFFLINE stateboolean isNodeAlive(@NotNull
@NotNull String nodeId)
boolean isNodePresent(@NotNull
@NotNull String id)
boolean isNodeOffline(@NotNull
@NotNull String nodeId)
Node.NodeState.OFFLINE otherwise return falseboolean isNodeActive(@NotNull
@NotNull String nodeId)
Node.NodeState.ACTIVE otherwise return falseList<Node> findActiveAndNotAliveNodes()
Node.NodeState.ACTIVE and not alive isNodeAlive(java.lang.String)List<Node> findOfflineNodes()
Node.NodeState.OFFLINECopyright © 2002-2021 Atlassian. All Rights Reserved.