We're seeing a similiar problem, and wanted to see if this is the same issue.
We have two web apps in Tomcat 2.2.9 that use JMS connections. We were
using ActiveMQ3.0, things were fine, and now we're testing with ActiveMQ 4.0
(and I tried 4.0.1) and the results are:
the first web app starting a JMS connection works fine. When the second web
app tries to start a JMS connection (after successfully getting a
ConnectionFactory as the first web app did also), it hangs. We shut down
Tomcat, leave the broker running, and turn on Tomcat and the first web app
hangs when it tries to start a JMS connection and same with the second web
app. Here's the error log (at the end I have the successful connection):
2006-06-21 15:25:30,864 [Thread-2] 58 JNDIReferenceFactory.java
DEBUG Getting instance of org.apache.activemq.ActiveMQConnectionFactory
2006-06-21 15:25:30,943 [Thread-2] 101 JMSUtil.java
DEBUG successfully obtained connection factory
2006-06-21 15:25:31,312 [Thread-2] 62 WireFormatNegotiator.java
DEBUG Sending: WireFormatInfo { version=1,
properties={TightEncodingEnabled=true, TcpNoDelayEnabled=true,
SizePrefixDisabled=false, StackTraceEnabled=true,
MaxInactivityDuration=30000, CacheEnabled=true}, magic=[A,c,t,i,v,e,M,Q]}
2006-06-21 15:25:31,318 [Thread-2] 167 JMSUtil.java
DEBUG returning connection: ActiveMQConnection
{id=ID:machinename.com-33231-1150925131041-1:0,clientId=null,started=false}
2006-06-21 15:25:31,312 [ActiveMQ Transport:
tcp://localhost/xxx.x.x.x:61616] 139 TcpTransport.java
DEBUG TCP consumer thread starting
Here is the successful log of this:
2006-06-21 15:14:22,754 [Thread-36] 62 WireFormatNegotiator.java
DEBUG Sending: WireFormatInfo { version=1,
properties={TightEncodingEnabled=true, TcpNoDelayEnabled=true,
SizePrefixDisabled=false, StackTraceEnabled=true,
MaxInactivityDuration=30000, CacheEnabled=true}, magic=[A,c,t,i,v,e,M,Q]}
2006-06-21 15:14:22,796 [ActiveMQ Transport:
tcp://localhost/xxx.x.x.x:61616] 139 TcpTransport.java
DEBUG TCP consumer thread starting
2006-06-21 15:14:22,816 [Thread-36] 167 JMSUtil.java
DEBUG returning connection: ActiveMQConnection
{id=ID:machinename.com-32883-1150924462273-1:0,clientId=null,started=false}
2006-06-21 15:14:22,862 [ActiveMQ Transport:
tcp://localhost/xxx.x.x.x:61616] 85 WireFormatNegotiator.java
DEBUG Received WireFormat: WireFormatInfo { version=1,
properties={StackTraceEnabled=true, TightEncodingEnabled=true,
TcpNoDelayEnabled=true, SizePrefixDisabled=false,
MaxInactivityDuration=30000, CacheEnabled=true}, magic=[A,c,t,i,v,e,M,Q]}
2006-06-21 15:14:22,862 [ActiveMQ Transport:
tcp://localhost/xxx.x.x.x:61616] 92 WireFormatNegotiator.java
DEBUG tcp://localhost/xxx.x.x.x:61616 before negotiation:
OpenWireFormat{version=1, cacheEnabled=false, stackTraceEnabled=false,
tightEncodingEnabled=false, sizePrefixDisabled=false}
--
View this message in context:
http://www.nabble.com/hung-connecting-to-broker-t1717047.html#a4983639
Sent from the ActiveMQ - User forum at Nabble.com.