Package io.atomix.cluster.protocol
Class SwimMembershipProtocolConfig
java.lang.Object
io.atomix.cluster.protocol.GroupMembershipProtocolConfig
io.atomix.cluster.protocol.SwimMembershipProtocolConfig
- All Implemented Interfaces:
io.atomix.utils.config.Config,io.atomix.utils.config.TypedConfig<GroupMembershipProtocol.Type>
public class SwimMembershipProtocolConfig extends GroupMembershipProtocolConfig
SWIM membership protocol configuration.
-
Constructor Summary
Constructors Constructor Description SwimMembershipProtocolConfig() -
Method Summary
Modifier and Type Method Description java.time.DurationgetFailureTimeout()Returns the base failure timeout.intgetGossipFanout()Returns the gossip fanout.java.time.DurationgetGossipInterval()Returns the gossip interval.java.time.DurationgetProbeInterval()Returns the probe interval.java.time.DurationgetProbeTimeout()Returns the probe timeout.intgetSuspectProbes()Returns the number of probes to perform on suspect members.GroupMembershipProtocol.TypegetType()booleanisBroadcastDisputes()Returns whether to broadcast disputes to all peers.booleanisBroadcastUpdates()Returns whether to broadcast member updates to all peers.booleanisNotifySuspect()Returns whether to notify a suspect node on state changes.booleanisRetainTombstones()Returns whether tombstone retention is enabled.SwimMembershipProtocolConfigsetBroadcastDisputes(boolean broadcastDisputes)Sets whether to broadcast disputes to all peers.SwimMembershipProtocolConfigsetBroadcastUpdates(boolean broadcastUpdates)Sets whether to broadcast member updates to all peers.SwimMembershipProtocolConfigsetFailureTimeout(java.time.Duration failureTimeout)Sets the base failure timeout.SwimMembershipProtocolConfigsetGossipFanout(int gossipFanout)Sets the gossip fanout.SwimMembershipProtocolConfigsetGossipInterval(java.time.Duration gossipInterval)Sets the gossip interval.SwimMembershipProtocolConfigsetNotifySuspect(boolean notifySuspect)Sets whether to notify a suspect node on state changes.SwimMembershipProtocolConfigsetProbeInterval(java.time.Duration probeInterval)Sets the probe interval.SwimMembershipProtocolConfigsetProbeTimeout(java.time.Duration probeTimeout)Sets the probe timeout.SwimMembershipProtocolConfigsetRetainTombstones(boolean retainTombstones)Sets whether to retain tombstones.SwimMembershipProtocolConfigsetSuspectProbes(int suspectProbes)Sets the number of probes to perform on suspect members.
-
Constructor Details
-
SwimMembershipProtocolConfig
public SwimMembershipProtocolConfig()
-
-
Method Details
-
isBroadcastUpdates
public boolean isBroadcastUpdates()Returns whether to broadcast member updates to all peers.- Returns:
- whether to broadcast member updates to all peers
-
setBroadcastUpdates
Sets whether to broadcast member updates to all peers.- Parameters:
broadcastUpdates- whether to broadcast member updates to all peers- Returns:
- the protocol configuration
-
isBroadcastDisputes
public boolean isBroadcastDisputes()Returns whether to broadcast disputes to all peers.- Returns:
- whether to broadcast disputes to all peers
-
setBroadcastDisputes
Sets whether to broadcast disputes to all peers.- Parameters:
broadcastDisputes- whether to broadcast disputes to all peers- Returns:
- the protocol configuration
-
isNotifySuspect
public boolean isNotifySuspect()Returns whether to notify a suspect node on state changes.- Returns:
- whether to notify a suspect node on state changes
-
setNotifySuspect
Sets whether to notify a suspect node on state changes.- Parameters:
notifySuspect- whether to notify a suspect node on state changes- Returns:
- the protocol configuration
-
getGossipInterval
public java.time.Duration getGossipInterval()Returns the gossip interval.- Returns:
- the gossip interval
-
setGossipInterval
Sets the gossip interval.- Parameters:
gossipInterval- the gossip interval- Returns:
- the protocol configuration
-
getGossipFanout
public int getGossipFanout()Returns the gossip fanout.- Returns:
- the gossip fanout
-
setGossipFanout
Sets the gossip fanout.- Parameters:
gossipFanout- the gossip fanout- Returns:
- the protocol configuration
-
getProbeInterval
public java.time.Duration getProbeInterval()Returns the probe interval.- Returns:
- the probe interval
-
setProbeInterval
Sets the probe interval.- Parameters:
probeInterval- the probe interval- Returns:
- the membership configuration
-
getProbeTimeout
public java.time.Duration getProbeTimeout()Returns the probe timeout.- Returns:
- the probe timeout
-
setProbeTimeout
Sets the probe timeout.- Parameters:
probeTimeout- the probe timeout- Returns:
- the membership protocol configuration
-
getSuspectProbes
public int getSuspectProbes()Returns the number of probes to perform on suspect members.- Returns:
- the number of probes to perform on suspect members
-
setSuspectProbes
Sets the number of probes to perform on suspect members.- Parameters:
suspectProbes- the number of probes to perform on suspect members- Returns:
- the membership configuration
-
getFailureTimeout
public java.time.Duration getFailureTimeout()Returns the base failure timeout.- Returns:
- the base failure timeout
-
setFailureTimeout
Sets the base failure timeout.- Parameters:
failureTimeout- the base failure timeout- Returns:
- the group membership configuration
-
isRetainTombstones
public boolean isRetainTombstones()Returns whether tombstone retention is enabled.- Returns:
- whether tombstone retention is enabled
-
setRetainTombstones
Sets whether to retain tombstones.- Parameters:
retainTombstones- whether to retain tombstones- Returns:
- the membership protocol configuration
-
getType
-