Class CoordGmsImpl
java.lang.Object
org.jgroups.protocols.pbcast.GmsImpl
org.jgroups.protocols.pbcast.CoordGmsImpl
Coordinator role of the Group MemberShip (GMS) protocol. Accepts JOIN and LEAVE requests and emits view changes
accordingly.
- Author:
- Bela Ban
-
Nested Class Summary
Nested classes/interfaces inherited from class GmsImpl
GmsImpl.Request -
Field Summary
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidhandleDigestResponse(Address sender, Digest digest) voidvoidhandleJoinResponse(JoinRsp join_rsp) voidvoidhandleMembershipChange(Collection<GmsImpl.Request> requests) voidhandleMergeCancelled(ViewId merge_id) voidhandleMergeRequest(Address sender, ViewId merge_id) Get the view and digest and send back both (MergeData) in the form of a MERGE_RSP to the sender.voidhandleMergeResponse(MergeData data, ViewId merge_id) voidhandleMergeView(MergeData data, ViewId merge_id) If merge_id is not equal to this.merge_id then discard.voidhandleViewChange(View new_view, Digest digest) Called by the GMS when a VIEW is received.voidinit()voidvoidvoidThe coordinator itself wants to leave the groupvoidInvoked upon receiving a MERGE event from the MERGE layer.voidstop()voidvoidMethods inherited from class GmsImpl
handleUpEvent, iWouldBeCoordinator, sendMergeRejectedResponse, start, wrongMethod
-
Constructor Details
-
CoordGmsImpl
-
-
Method Details
-
init
-
join
-
joinWithStateTransfer
- Specified by:
joinWithStateTransferin classGmsImpl
-
leave
-
handleJoinResponse
- Specified by:
handleJoinResponsein classGmsImpl
-
handleLeaveResponse
public void handleLeaveResponse()- Specified by:
handleLeaveResponsein classGmsImpl
-
suspect
-
unsuspect
-
merge
-
handleMergeRequest
Get the view and digest and send back both (MergeData) in the form of a MERGE_RSP to the sender. If a merge is already in progress, send back a MergeData with the merge_rejected field set to true.- Overrides:
handleMergeRequestin classGmsImpl
-
handleMergeResponse
- Overrides:
handleMergeResponsein classGmsImpl
-
handleDigestResponse
- Overrides:
handleDigestResponsein classGmsImpl
-
handleMergeView
If merge_id is not equal to this.merge_id then discard. Else cast the view/digest to all members of this group.- Overrides:
handleMergeViewin classGmsImpl
-
handleMergeCancelled
- Overrides:
handleMergeCancelledin classGmsImpl
-
handleMembershipChange
- Specified by:
handleMembershipChangein classGmsImpl
-
handleViewChange
Called by the GMS when a VIEW is received.- Specified by:
handleViewChangein classGmsImpl- Parameters:
new_view- The view to be installeddigest- If view is a MergeView, digest contains the seqno digest of all members and has to be set by GMS
-
handleExit
public void handleExit()- Overrides:
handleExitin classGmsImpl
-
stop
-