next up previous contents
Next: Getting the local and Up: Channels Previous: Creating a channel

Connecting to a channel

When a client wants to join a group, it connects to a channel giving the name of the group to be joined:

        public void Connect(Object group_address) throws ChannelClosed;

To preserve genericity, the group address is typed as an object, However, channel implementations would typically require more specific group addresses. In the case of JChannel, the group address must be a string, naming the group to be joined. All channels that are connected to the same group (same name) form a group. Messages multicast on any channel in the group will be received by all members (including the one who sent it3.2).

The method returns as soon as other members have been found, and the group has been joined. If the channel is in the closed state (see fig. 3.2), an exception will be thrown. If there are no other members, i.e. no other client has connected to a group with this name, then a new (conceptual) group is created and the member joined. The first member of a group becomes its coordinator, i.e. the member who receives join and leave requests. A coordinator is in charge of multicasting new views whenever the membership changes.


next up previous contents
Next: Getting the local and Up: Channels Previous: Creating a channel

1999-08-19