FileDocCategorySizeDatePackage
ChannelSender.javaAPI DocApache Tomcat 6.0.142792Fri Jul 20 04:20:36 BST 2007org.apache.catalina.tribes

ChannelSender

public interface ChannelSender implements Heartbeat
ChannelReceiver Interface
The ChannelSender interface is the data sender component at the bottom layer, the IO layer (for layers see the javadoc for the {@link Channel} interface).
The channel sender must support "silent" members, ie, be able to send a message to a member that is not in the membership, but is part of the destination parameter
author
Filip Hanik
version
$Revision: 467222 $, $Date: 2006-10-24 05:17:11 +0200 (mar., 24 oct. 2006) $

Fields Summary
Constructors Summary
Methods Summary
public voidadd(Member member)
Notify the sender of a member being added to the group.
Optional. This can be an empty implementation, that does nothing

param
member Member

public voidheartbeat()
A channel heartbeat, use this method to clean up resources

public voidremove(Member member)
Notification that a member has been removed or crashed. Can be used to clean up open connections etc

param
member Member

public voidsendMessage(ChannelMessage message, Member[] destination)
Send a message to one or more recipients.

param
message ChannelMessage - the message to be sent
param
destination Member[] - the destinations
throws
ChannelException - if an error happens, the ChannelSender MUST report individual send failures on a per member basis, using ChannelException.addFaultyMember
see
ChannelException#addFaultyMember(Member,java.lang.Exception)

public voidstart()
Start the channel sender

throws
IOException if preprocessing takes place and an error happens

public voidstop()
Stop the channel sender