public class GroupFailoverStrategy extends FailoverStrategy<GroupFailoverClusterPaths>
The failover strategy to provide failover to groups of nodes. Under this strategy, a group of nodes can be assigned to
provide failover to another node group. Also a set of conditions can be specified to determine when to start providing
failover to a given group. FailoverGroupConfig is the class which responsible for specifying when to start
failover.
This class will be adding group names to the XEnvironment based on the decisions made on
whether to start failover. The tags will be added under the key XTAG_ACTING_AS_GROUP_NAME. They will be later used
by an EnvironmentEvaluator to determine whether to start/stop components.
client, environment, failoverClusterPaths, status| Constructor and Description |
|---|
GroupFailoverStrategy() |
| Modifier and Type | Method and Description |
|---|---|
Map<String,List<FailoverGroupConfig>> |
getFailoverMatrix() |
String |
getGroupName() |
protected void |
initStrategy() |
boolean |
isFailoverOnStartup() |
protected GroupFailoverClusterPaths |
newFailoverClusterPaths() |
void |
refresh()
This method is called whenever the failover strategy believes that the connection state became unstable and again
re became stable.
|
void |
resetTags()
Whenever the connection state changes to lost or suspended, this method will be called in order to remove the tags
added by the extending concrete strategy.
|
void |
setFailoverMatrix(Map<String,List<FailoverGroupConfig>> failoverMatrix) |
void |
setFailoverOnStartup(boolean failoverOnStartup) |
void |
setGroupName(String groupName) |
protected void |
startStrategy() |
protected void |
stopStrategy() |
String |
toString() |
addTags, getFailoverClusterPaths, initialize, removeTags, start, stateChanged, stopprotected void initStrategy()
initStrategy in class FailoverStrategy<GroupFailoverClusterPaths>protected void startStrategy()
startStrategy in class FailoverStrategy<GroupFailoverClusterPaths>public void refresh()
refresh in class FailoverStrategy<GroupFailoverClusterPaths>public void resetTags()
resetTags in class FailoverStrategy<GroupFailoverClusterPaths>protected void stopStrategy()
stopStrategy in class FailoverStrategy<GroupFailoverClusterPaths>protected GroupFailoverClusterPaths newFailoverClusterPaths()
newFailoverClusterPaths in class FailoverStrategy<GroupFailoverClusterPaths>public Map<String,List<FailoverGroupConfig>> getFailoverMatrix()
getFailoverMatrix in class FailoverStrategy<GroupFailoverClusterPaths>public String toString()
toString in class FailoverStrategy<GroupFailoverClusterPaths>public void setFailoverMatrix(Map<String,List<FailoverGroupConfig>> failoverMatrix)
public boolean isFailoverOnStartup()
public void setFailoverOnStartup(boolean failoverOnStartup)
public String getGroupName()
public void setGroupName(String groupName)
Copyright © 2016–2019 AdroitLogic. All rights reserved.