Return-Path: X-Original-To: apmail-activemq-users-archive@www.apache.org Delivered-To: apmail-activemq-users-archive@www.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id 45E8348D1 for ; Sat, 21 May 2011 14:48:32 +0000 (UTC) Received: (qmail 88406 invoked by uid 500); 21 May 2011 14:48:31 -0000 Delivered-To: apmail-activemq-users-archive@activemq.apache.org Received: (qmail 88381 invoked by uid 500); 21 May 2011 14:48:31 -0000 Mailing-List: contact users-help@activemq.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: users@activemq.apache.org Delivered-To: mailing list users@activemq.apache.org Received: (qmail 88373 invoked by uid 99); 21 May 2011 14:48:31 -0000 Received: from nike.apache.org (HELO nike.apache.org) (192.87.106.230) by apache.org (qpsmtpd/0.29) with ESMTP; Sat, 21 May 2011 14:48:31 +0000 X-ASF-Spam-Status: No, hits=2.0 required=5.0 tests=FREEMAIL_FROM,RFC_ABUSE_POST,SPF_NEUTRAL,T_TO_NO_BRKTS_FREEMAIL,URI_HEX X-Spam-Check-By: apache.org Received-SPF: neutral (nike.apache.org: 216.139.236.26 is neither permitted nor denied by domain of hodgesz@gmail.com) Received: from [216.139.236.26] (HELO sam.nabble.com) (216.139.236.26) by apache.org (qpsmtpd/0.29) with ESMTP; Sat, 21 May 2011 14:48:26 +0000 Received: from joe.nabble.com ([192.168.236.139]) by sam.nabble.com with esmtp (Exim 4.72) (envelope-from ) id 1QNnTJ-0008Uh-8u for users@activemq.apache.org; Sat, 21 May 2011 07:48:05 -0700 Date: Sat, 21 May 2011 07:48:05 -0700 (PDT) From: hodgesz To: users@activemq.apache.org Message-ID: <1305989285267-3540710.post@n4.nabble.com> Subject: Problem with NIO protocol MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit X-Virus-Checked: Checked by ClamAV on apache.org Hi, 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: java.io.IOException: Wire format negotiation timeout: peer did not send his wire format. | org.apache.activemq.broker.TransportConnection.Transport | Async Exception Handler 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 On the client when my broker URL is tcp://ec2-x-x-x-x.us-west-1.compute.amazonaws.com:61616 it loads fine without any errors. If I change the broker URL to nio://ec2-x-x-x-x.us-west-1.compute.amazonaws.com:61618 I see the errors. A quick search on the web I came across a few JIRAs and the FAQ URL http://activemq.apache.org/javaxjmsjmsexception-wire-format-negociation-timeout-peer-did-not-send-his-wire-format.html 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 messages 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. Thanks, Jonathan -- View this message in context: http://activemq.2283324.n4.nabble.com/Problem-with-NIO-protocol-tp3540710p3540710.html Sent from the ActiveMQ - User mailing list archive at Nabble.com.