Details
-
Bug
-
Status: Closed
-
Major
-
Resolution: Fixed
-
0.24
-
None
Description
The client code worked with qpid-java-client-0.18 and RabbitMQ 2.8.7. Upgraded RabbitMQ 3.1.3. Got error. Upgraded to qpid-java-client-0.24 generated same error.
IoReceiver - localhost/127.0.0.1:5672 2013-09-27 11:55:24,756 DEBUG [qpid.client.protocol.AMQProtocolHandler] (1027355575)Method frame received: [ChannelCloseBodyImpl: replyCode=406, replyText=PRECONDITION_FAILED - invalid expiration '': no_integer, classId=60, methodId=40]
IoReceiver - localhost/127.0.0.1:5672 2013-09-27 11:55:24,756 DEBUG [qpid.client.handler.ChannelCloseMethodHandler] ChannelClose method received
IoReceiver - localhost/127.0.0.1:5672 2013-09-27 11:55:24,757 DEBUG [qpid.client.handler.ChannelCloseMethodHandler] Channel close reply code: 406: In use, reason: PRECONDITION_FAILED - invalid expiration '': no_integer
IoReceiver - localhost/127.0.0.1:5672 2013-09-27 11:55:24,758 DEBUG [qpid.client.handler.ChannelCloseMethodHandler] Channel close received with errorCode 406: In use, and reason PRECONDITION_FAILED - invalid expiration '': no_integer
IoReceiver - localhost/127.0.0.1:5672 2013-09-27 11:55:24,760 DEBUG [apache.qpid.client.AMQConnection] exceptionReceived done by:IoReceiver - localhost/127.0.0.1:5672
org.apache.qpid.AMQChannelClosedException: Error: PRECONDITION_FAILED - invalid expiration '': no_integer [error code 406: In use]
at org.apache.qpid.client.handler.ChannelCloseMethodHandler.methodReceived(ChannelCloseMethodHandler.java:97)
at org.apache.qpid.client.handler.ClientMethodDispatcherImpl.dispatchChannelClose(ClientMethodDispatcherImpl.java:164)
at org.apache.qpid.framing.amqp_0_91.ChannelCloseBodyImpl.execute(ChannelCloseBodyImpl.java:137)
at org.apache.qpid.client.state.AMQStateManager.methodReceived(AMQStateManager.java:114)
at org.apache.qpid.client.protocol.AMQProtocolHandler.methodBodyReceived(AMQProtocolHandler.java:520)
at org.apache.qpid.client.protocol.AMQProtocolSession.methodFrameReceived(AMQProtocolSession.java:462)
at org.apache.qpid.framing.AMQMethodBodyImpl.handle(AMQMethodBodyImpl.java:97)
at org.apache.qpid.client.protocol.AMQProtocolHandler.received(AMQProtocolHandler.java:477)
at org.apache.qpid.client.protocol.AMQProtocolHandler.received(AMQProtocolHandler.java:123)
at org.apache.qpid.transport.network.io.IoReceiver.run(IoReceiver.java:161)
at java.lang.Thread.run(Thread.java:680)
To get this working I patched BasicMessageProducer to default the _disableTimestamps = true. This doesn't fix the problem but it prevents timestamps and TTL getting generated in the AMQP header frame.
Looks like a (long)0 is represented as a '' in the frame. RabbitMQ expects this as a string and it toLong() the string. Obviously, a empty string will not convert to a 0L.
Attachments
Issue Links
- is related to
-
QPID-5223 [Java 0-x Client] add system property to set message expiration header as raw TTL value for users of RabbitMQ
- Closed