| java.lang.Object org.jgroups.protocols.pbcast.GmsImpl org.jgroups.protocols.pbcast.ClientGmsImpl
ClientGmsImpl | public class ClientGmsImpl extends GmsImpl (Code) | | Client part of GMS. Whenever a new member wants to join a group, it starts in the CLIENT role.
No multicasts to the group will be received and processed until the member has been joined and
turned into a SERVER (either coordinator or participant, mostly just participant). This class
only implements 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.
author: Bela Ban version: $Revision: 1.34.2.2 $ |
ClientGmsImpl | public ClientGmsImpl(GMS g)(Code) | | |
becomeSingletonMember | void becomeSingletonMember(Address mbr)(Code) | | |
findInitialMembers | void findInitialMembers()(Code) | | Pings initial members. Removes self before returning vector of initial members.
Uses IP multicast or gossiping, depending on parameters.
|
handleJoinResponse | public void handleJoinResponse(JoinRsp join_rsp)(Code) | | |
handleLeaveResponse | public void handleLeaveResponse()(Code) | | |
handleUpEvent | public boolean handleUpEvent(Event evt)(Code) | | Returns immediately. Clients don't handle suspect() requests
|
handleViewChange | public synchronized void handleViewChange(View new_view, Digest digest)(Code) | | Does nothing. Discards all views while still client.
|
join | public void join(Address mbr)(Code) | | Joins this process to a group. Determines the coordinator and sends a unicast
handleJoin() message to it. The coordinator returns a JoinRsp and then broadcasts the new view, which
contains a message digest and the current membership (including the joiner). The joiner is then
supposed to install the new view and the digest and starts accepting mcast messages. Previous
mcast messages were discarded (this is done in PBCAST).
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.
Parameters: mbr - Our own address (assigned through SET_LOCAL_ADDRESS) |
|
|