public class RecentlyActiveQuorumFunction extends AbstractPingAwareQuorumFunction implements HeartbeatAware, QuorumFunction, MembershipListener
heartbeatToleranceMillis milliseconds before current time.| Constructor and Description | 
|---|
RecentlyActiveQuorumFunction(int quorumSize,
                            int heartbeatToleranceMillis)  | 
| Modifier and Type | Method and Description | 
|---|---|
boolean | 
apply(Collection<Member> members)
Determines if quorum is present based on the current list of members in the cluster. 
 | 
boolean | 
equals(Object o)  | 
int | 
getHeartbeatToleranceMillis()  | 
int | 
hashCode()  | 
void | 
memberRemoved(MembershipEvent membershipEvent)
Invoked when an existing member leaves the cluster. 
 | 
void | 
onHeartbeat(Member member,
           long timestamp)
Notifies of a received heartbeat. 
 | 
isAlivePerIcmp, memberAdded, memberAttributeChanged, onPingLost, onPingRestored, setHazelcastInstanceclone, finalize, getClass, notify, notifyAll, toString, wait, wait, waitmemberAdded, memberAttributeChangedpublic RecentlyActiveQuorumFunction(int quorumSize,
                                    int heartbeatToleranceMillis)
public boolean apply(Collection<Member> members)
QuorumFunctionapply in interface QuorumFunctionmembers - snapshot of current member listpublic void onHeartbeat(Member member, long timestamp)
HeartbeatAwareQuorumFunction.apply(Collection) so
 the QuorumFunction can update its internal state before deciding on quorum presence.onHeartbeat in interface HeartbeatAwaremember - member from which heartbeat was receivedtimestamp - timestmap on which heartbeat was receivedpublic void memberRemoved(MembershipEvent membershipEvent)
MembershipListenermemberRemoved in interface MembershipListenermemberRemoved in class AbstractPingAwareQuorumFunctionmembershipEvent - membership event when an existing member leaves the clusterpublic int getHeartbeatToleranceMillis()
Copyright © 2020 Hazelcast, Inc.. All Rights Reserved.