public class ClusterHeartBeatMaster extends ClusterHeartBeat
| Modifier and Type | Field and Description |
|---|---|
Map<HostSpec,Set<HostSpec>> |
CLUSTER_NODE_RELATIONSHIP |
CLUSTER_PROPERTIES| Modifier and Type | Method and Description |
|---|---|
void |
addClusterNode(HostSpec hostSpecs,
HostSpec... value)
Perform cache maintenance on cluster nodes connected to hosts
|
void |
clear() |
Set<HostSpec> |
get(HostSpec hostSpec) |
Map<HostSpec,Set<HostSpec>> |
getClusterRelationship() |
static ClusterHeartBeatMaster |
getInstance() |
void |
removeClusterNode(HostSpec key,
HostSpec newKey,
Set<HostSpec> slaves)
Update the cluster node relationship
|
void |
run()
the primary node is active and added to the failure set after failure
|
addNodeRelationship, addProperties, cacheProcess, findMasterNode, getClusterSalveNode, getProperties, getQueryExecutor, initPeriodTime, masterNodeProbe, nodeRoleIsMaster, removeProperties, updateDetectionpublic static ClusterHeartBeatMaster getInstance()
public void run()
public Map<HostSpec,Set<HostSpec>> getClusterRelationship()
getClusterRelationship in class ClusterHeartBeatpublic void addClusterNode(HostSpec hostSpecs, HostSpec... value)
ClusterHeartBeataddClusterNode in class ClusterHeartBeathostSpecs - the parsed/defaulted connection propertiesvalue - slaves setpublic void removeClusterNode(HostSpec key, HostSpec newKey, Set<HostSpec> slaves)
ClusterHeartBeatremoveClusterNode in class ClusterHeartBeatkey - old masternewKey - new masterslaves - slaves setpublic void clear()
clear in class ClusterHeartBeatCopyright © 2023 openGauss. All rights reserved.