Docjar: A Java Source and Docuemnt Enginecom.*    java.*    javax.*    org.*    all    new    plug-in

Quick Search    Search Deep

org.activemq.transport
Class RemoteNetworkChannel  view RemoteNetworkChannel download RemoteNetworkChannel.java

java.lang.Object
  extended byorg.activemq.transport.NetworkChannel
      extended byorg.activemq.transport.RemoteNetworkChannel
All Implemented Interfaces:
org.activemq.advisories.ConnectionAdvisoryEventListener, org.activemq.broker.ConsumerInfoListener, org.activemq.service.Service, TransportStatusEventListener

public class RemoteNetworkChannel
extends NetworkChannel
implements TransportStatusEventListener

Represents a Boondocks broker's connection with a single remote broker which bridges the two brokers to form a network.

The NetworkChannel contains a JMS connection with the remote broker.

New subscriptions on the local broker are multiplexed into the JMS connection so that messages published on the remote broker can be replayed onto the local broker.

Version:
$Revision: 1.1.1.1 $

Field Summary
private  TransportChannel boondocksChannel
           
private static org.apache.commons.logging.Log log
           
 
Fields inherited from class org.activemq.transport.NetworkChannel
brokerContainer, localConnection, maximumRetries, queueConsumerMap, reconnectSleepTime, remoteBrokerName, remoteClusterName, remoteConnection, remotePassword, remoteUserName, threadPool, topicConsumerMap, uri
 
Constructor Summary
RemoteNetworkChannel(NetworkConnector connector, org.activemq.broker.BrokerContainer brokerContainer, java.lang.String uri)
          Constructor
RemoteNetworkChannel(EDU.oswego.cs.dl.util.concurrent.PooledExecutor tp)
          Default Constructor
 
Method Summary
protected  void initialize()
          remote:// can only make outgoing connections - we assume we can't accept incomming (duck!).
private  void sendBrokerInfo()
           
 void statusChanged(TransportStatusEvent event)
          called when the status of a transport channel changes
 
Methods inherited from class org.activemq.transport.NetworkChannel
getBrokerContainer, getLocalPrefetchPolicy, getMaximumRetries, getReconnectSleepTime, getRemoteBrokerName, getRemotePassword, getRemotePrefetchPolicy, getRemoteUserName, getThreadPool, getUri, isDemandBasedForwarding, onConsumerInfo, onEvent, setBrokerContainer, setDemandBasedForwarding, setLocalPrefetchPolicy, setMaximumRetries, setReconnectSleepTime, setRemoteBrokerName, setRemotePassword, setRemotePrefetchPolicy, setRemoteUserName, setThreadPool, setUri, start, stop, toString
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

log

private static final org.apache.commons.logging.Log log

boondocksChannel

private TransportChannel boondocksChannel
Constructor Detail

RemoteNetworkChannel

public RemoteNetworkChannel(EDU.oswego.cs.dl.util.concurrent.PooledExecutor tp)
Default Constructor


RemoteNetworkChannel

public RemoteNetworkChannel(NetworkConnector connector,
                            org.activemq.broker.BrokerContainer brokerContainer,
                            java.lang.String uri)
Constructor

Method Detail

statusChanged

public void statusChanged(TransportStatusEvent event)
Description copied from interface: TransportStatusEventListener
called when the status of a transport channel changes

Specified by:
statusChanged in interface TransportStatusEventListener
Overrides:
statusChanged in class NetworkChannel

initialize

protected void initialize()
                   throws javax.jms.JMSException
remote:// can only make outgoing connections - we assume we can't accept incomming (duck!). So we initialize the transport channel from this side and create the broker client as well

Overrides:
initialize in class NetworkChannel

sendBrokerInfo

private void sendBrokerInfo()
                     throws javax.jms.JMSException