This commit is contained in:
Timothy Bish 2013-10-24 10:41:05 -04:00
parent 043a4ad4ff
commit ec97d0aad0
1 changed files with 5 additions and 4 deletions

View File

@ -21,6 +21,7 @@ import static org.junit.Assert.assertFalse;
import static org.junit.Assert.assertNotNull; import static org.junit.Assert.assertNotNull;
import java.lang.reflect.Field; import java.lang.reflect.Field;
import java.util.concurrent.CopyOnWriteArrayList;
import javax.jms.MessageProducer; import javax.jms.MessageProducer;
import javax.jms.TemporaryQueue; import javax.jms.TemporaryQueue;
@ -28,6 +29,7 @@ import javax.jms.TemporaryQueue;
import org.apache.activemq.advisory.AdvisorySupport; import org.apache.activemq.advisory.AdvisorySupport;
import org.apache.activemq.broker.BrokerService; import org.apache.activemq.broker.BrokerService;
import org.apache.activemq.broker.TransportConnection; import org.apache.activemq.broker.TransportConnection;
import org.apache.activemq.broker.TransportConnector;
import org.junit.Test; import org.junit.Test;
/** /**
@ -107,10 +109,9 @@ public class DynamicallyIncludedDestinationsDuplexNetworkTest extends SimpleNetw
} }
public TransportConnection getDuplexBridgeConnectionFromRemote() { public TransportConnection getDuplexBridgeConnectionFromRemote() {
TransportConnection duplexBridgeConnectionFromRemote = TransportConnector transportConnector = remoteBroker.getTransportConnectorByScheme("tcp");
remoteBroker.getTransportConnectorByName("tcp://localhost:" + REMOTE_BROKER_TCP_PORT) CopyOnWriteArrayList<TransportConnection> transportConnections = transportConnector.getConnections();
.getConnections().get(0); TransportConnection duplexBridgeConnectionFromRemote = transportConnections.get(0);
return duplexBridgeConnectionFromRemote; return duplexBridgeConnectionFromRemote;
} }
} }