FileDocCategorySizeDatePackage
PooledMultiSender.javaAPI DocApache Tomcat 6.0.142591Fri Jul 20 04:20:34 BST 2007org.apache.catalina.tribes.transport.bio

PooledMultiSender

public class PooledMultiSender extends org.apache.catalina.tribes.transport.PooledSender

Title:

Description:

Company:

author
not attributable
version
1.0

Fields Summary
Constructors Summary
public PooledMultiSender()

    
Methods Summary
public org.apache.catalina.tribes.transport.DataSendergetNewDataSender()
getNewDataSender

return
DataSender
todo
Implement this org.apache.catalina.tribes.transport.PooledSender method

        MultipointBioSender sender = new MultipointBioSender();
        sender.transferProperties(this,sender);
        return sender;
    
public voidsendMessage(org.apache.catalina.tribes.Member[] destination, org.apache.catalina.tribes.ChannelMessage msg)

        MultiPointSender sender = null;
        try {
            sender = (MultiPointSender)getSender();
            if (sender == null) {
                ChannelException cx = new ChannelException("Unable to retrieve a data sender, time out error.");
                for (int i = 0; i < destination.length; i++) cx.addFaultyMember(destination[i], new NullPointerException("Unable to retrieve a sender from the sender pool"));
                throw cx;
            } else {
                sender.sendMessage(destination, msg);
            }
            sender.keepalive();
        }finally {
            if ( sender != null ) returnSender(sender);
        }