I had a look at this, and unfortunately it looks to be the result of the JMS client making use of a Qpid extension to AMQP which RabbitMQ doesn't support, leading it to close the connection when it is enountered. The particular usage of this extension causing the problem was added to the client in the 0.24 release, so using an older client release should rmeove that issue with the consumer.
That said, if you are using a recent 3.x release of RabbitMQ you will likely then run into a different issue with producers, due to RabbitMQ now interpreting the message 'expiry' header in a different way than Qpid had for some time, instead using it as a ttl value. Coupled with the Qpid client sending an empty value for expiry rather than not setting it, this results in failure when sending messages. See https://issues.apache.org/jira/browse/QPID-5184 for more detail and changes that were commited to try and work around the issue, which you could backport to an older release. I will tro to take a look at removing use of the AMQP extension when connected to RabbitMQ in order to try and restore basic consumer capability, but I'm not likely to get to it until the weekend. Robbie On 7 October 2013 22:28, k.madnani84 <k.madnan...@gmail.com> wrote: > Even using the above format throws me the exception: > Destination Created: 'topic:'/'/amq.topic'; None > java.lang.NullPointerException > > Therefore i tried to use queue and to my surprise i could see the queue got > created in RabbitMQ broker but its not binded to the RabbitMQ Exchange > 'amq.direct' and messages not getting published to it.I get the below error > and its probably at createCOnsumer call > > Destination Created: > direct://amq.direct/myqueue/myqueue?routingkey='myqueue'&durable='true' > javax.jms.JMSException: Error registering consumer: > org.apache.qpid.AMQException: Woken up due to class javax.jms.JMSException > at > org.apache.qpid.client.AMQSession.toJMSException(AMQSession.java:3494) > at > org.apache.qpid.client.AMQSession$4.execute(AMQSession.java:2039) > at > org.apache.qpid.client.AMQSession$4.execute(AMQSession.java:1991) > at > > org.apache.qpid.client.AMQConnectionDelegate_8_0.executeRetrySupport(AMQConnectionDelegate_8_0.java:333) > at > > org.apache.qpid.client.AMQConnection.executeRetrySupport(AMQConnection.java:624) > at > > org.apache.qpid.client.failover.FailoverRetrySupport.execute(FailoverRetrySupport.java:102) > at > org.apache.qpid.client.AMQSession.createConsumerImpl(AMQSession.java:1989) > at > org.apache.qpid.client.AMQSession.createConsumer(AMQSession.java:939) > at org.apache.qpid.example.Hello.runTest(Hello.java:59) > at org.apache.qpid.example.Hello.main(Hello.java:40) > Caused by: org.apache.qpid.AMQException: Woken up due to class > javax.jms.JMSException > at > org.apache.qpid.client.util.BlockingWaiter.block(BlockingWaiter.java:202) > at > > org.apache.qpid.client.protocol.BlockingMethodFrameListener.blockForFrame(BlockingMethodFrameListener.java:122) > at > > org.apache.qpid.client.protocol.AMQProtocolHandler.writeCommandFrameAndWaitForReply(AMQProtocolHandler.java:698) > at > > org.apache.qpid.client.protocol.AMQProtocolHandler.syncWrite(AMQProtocolHandler.java:719) > at > > org.apache.qpid.client.protocol.AMQProtocolHandler.syncWrite(AMQProtocolHandler.java:713) > at > > org.apache.qpid.client.AMQSession_0_8.sendExchangeBound(AMQSession_0_8.java:428) > at > org.apache.qpid.client.AMQSession_0_8.access$100(AMQSession_0_8.java:62) > at > org.apache.qpid.client.AMQSession_0_8$2.execute(AMQSession_0_8.java:410) > at > org.apache.qpid.client.AMQSession_0_8$2.execute(AMQSession_0_8.java:407) > at > > org.apache.qpid.client.failover.FailoverNoopSupport.execute(FailoverNoopSupport.java:67) > at > org.apache.qpid.client.AMQSession_0_8.isBound(AMQSession_0_8.java:405) > at > org.apache.qpid.client.AMQSession.registerConsumer(AMQSession.java:2873) > at org.apache.qpid.client.AMQSession.access$400(AMQSession.java:98) > at > org.apache.qpid.client.AMQSession$4.execute(AMQSession.java:2016) > ... 8 more > Caused by: javax.jms.JMSException: Exception thrown against AMQConnection: > Host: zldv0434.vci.att.com > Port: 5672 > Virtual Host: > Client ID: zldv0434.vci.att.com > Active session count: 1: org.apache.qpid.AMQDisconnectedException: Server > closed connection and reconnection not permitted. > at > > org.apache.qpid.client.AMQConnection.exceptionReceived(AMQConnection.java:1285) > at > > org.apache.qpid.client.protocol.AMQProtocolHandler.closed(AMQProtocolHandler.java:270) > at > org.apache.qpid.transport.network.io.IoReceiver.run(IoReceiver.java:222) > at java.lang.Thread.run(Unknown Source) > Caused by: org.apache.qpid.AMQDisconnectedException: Server closed > connection and reconnection not permitted. > ... 3 more > > Any idea what could fix it?? > > > > > -- > View this message in context: > http://qpid.2158936.n2.nabble.com/Null-Pointer-exception-in-Qpid-Java-CLient-0-24-tp7599126p7599153.html > Sent from the Apache Qpid developers mailing list archive at Nabble.com. > > --------------------------------------------------------------------- > To unsubscribe, e-mail: dev-unsubscr...@qpid.apache.org > For additional commands, e-mail: dev-h...@qpid.apache.org > >