This content has been marked as final.
Show 1 reply
-
1. Re: Detect state of connection when using failover transport
garytully Sep 7, 2011 6:09 AM (in response to kriswhite)Register a org.apache.activemq.transport.TransportListener via org.apache.activemq.ActiveMQConnection#addTransportListener and track the state between calls to transportInterupted() and transportResumed()
or
narrow your ActiveMQConnection generic transport to a FailoverTransport and check the status directly, pseudo code:
activeMqConnection.getTransportChannel().narrow(FailoverTransport.class).isConnected()