public class ClientGmsImpl extends GmsImpl
Join
(called by clients who want to join a certain group, and
ViewChange
which is called by the coordinator that was contacted by this client, to
tell the client what its initial membership is.GmsImpl.Request
Modifier and Type | Field and Description |
---|---|
protected Promise<JoinRsp> |
join_promise |
Constructor and Description |
---|
ClientGmsImpl(GMS g) |
Modifier and Type | Method and Description |
---|---|
protected boolean |
firstOfAllClients(Address joiner,
Responses rsps)
Handles the case where no coord responses were received.
|
void |
handleJoinResponse(JoinRsp join_rsp) |
void |
init() |
protected boolean |
installViewIfValidJoinRsp(Promise<JoinRsp> join_promise,
boolean block_for_rsp) |
protected boolean |
isJoinResponseValid(JoinRsp rsp) |
void |
join(Address address,
boolean useFlushIfPresent) |
protected void |
joinInternal(Address mbr,
boolean joinWithStateTransfer,
boolean useFlushIfPresent)
Joins this process to a group.
|
void |
joinWithStateTransfer(Address local_addr,
boolean useFlushIfPresent) |
void |
leave(Address mbr) |
protected static java.lang.String |
print(java.util.List<PingData> rsps) |
protected static java.lang.String |
print(Responses rsps) |
handleDigestResponse, handleLeaveResponse, handleMembershipChange, handleMergeCancelled, handleMergeRequest, handleMergeResponse, handleMergeView, handleViewChange, merge, sendMergeRejectedResponse, start, stop, suspect, unsuspect, wrongMethod
public ClientGmsImpl(GMS g)
public void init() throws java.lang.Exception
public void join(Address address, boolean useFlushIfPresent)
public void joinWithStateTransfer(Address local_addr, boolean useFlushIfPresent)
joinWithStateTransfer
in class GmsImpl
protected void joinInternal(Address mbr, boolean joinWithStateTransfer, boolean useFlushIfPresent)
If successful, impl is changed to an instance of ParticipantGmsImpl. Otherwise, we continue trying to send join() messages to the coordinator, until we succeed (or there is no member in the group. In this case, we create our own singleton group).
When GMS.disable_initial_coord is set to true, then we won't become coordinator on receiving an initial membership of 0, but instead will retry (forever) until we get an initial membership of > 0.
mbr
- Our own address (assigned through SET_LOCAL_ADDRESS)public void handleJoinResponse(JoinRsp join_rsp)
handleJoinResponse
in class GmsImpl
protected boolean installViewIfValidJoinRsp(Promise<JoinRsp> join_promise, boolean block_for_rsp)
protected boolean firstOfAllClients(Address joiner, Responses rsps)
protected boolean isJoinResponseValid(JoinRsp rsp)
protected static java.lang.String print(java.util.List<PingData> rsps)
protected static java.lang.String print(Responses rsps)
Copyright © 1998-2020 Red Hat. All Rights Reserved.