activemq-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From hodgesz <>
Subject Problem with NIO protocol
Date Sat, 21 May 2011 14:48:05 GMT

We are currently using ActiveMQ 5.4.2 with Spring/Tomcat clients.  We have
this configured as standalone two node JDBC master/slave.  Right now we are
only testing with one Spring/Tomcat client and the master ActiveMQ node. 
When changing my broker URL on the clients to use the NIO protocol instead
of TCP we are seeing the following exceptiom in the ActiveMQ logs.   

2011-05-18 21:50:44,950 | INFO  | Transport failed:
Wire format negotiation timeout: peer did not send his wire format. | | Async Exception

It is very likely I don't have something configured right since I am faily
new to ActiveMQ.  That said I have tried to follow examples from the
ActiveMQ in Action book I just purchased. 

The following is my transportConnectors element in the activemq.xml 

   <transportConnector name="tcp" uri="tcp://x.x.x.x:61616"/>
   <transportConnector name="nio" uri="nio://x.x.x.x:61618"/>

On the client when my broker URL is
tcp:// it loads fine
without any errors.  If I change the broker URL to
nio:// I see the errors. 

A quick search on the web I came across a few JIRAs and the FAQ URL

The FAQ says this error is one of following three things. 

1. You're connecting to the port not used by ActiveMQ TCP transport 
  Make sure to check that you're connecting to the appropriate host:port 
2. You're using log4j JMS appender and doesn't filter out ActiveMQ log
  Be sure to read How do I use log4j JMS appender with ActiveMQ and more
importantly to never send ActiveMQ log messages to JMS appender 
3. Your broker is probably under heavy load (or network connection is
unreliable), so connection setup cannot be completed in a reasonable time 

As far as I can tell my case doesn't fall in either of those three
categories.  I am pretty sure I have configured the host and port correctly
in that the TCP protocol works fine.  It's just when using NIO that I see
the issue.  I am not using the log4j JMS appender, there is no load
currently and the network connection is fine since I can telnet to both
ports from the client. 

The only thing I can think of is I configured NIO incorrectly on the server
or client but from all the examples I have seen it looks consistent. 

Any help on this would be greatly appreciated. 



View this message in context:
Sent from the ActiveMQ - User mailing list archive at

View raw message