In our application, we use RabbitMQ and spring-amqp(1.4.3.RELEASE). We have two Queues there. Both of them have TTL(60000 and 100000) configured. When we start the application, it gives the following errors:
[pool-4-thread-1] ERROR org.springframework.amqp.rabbit.connection.CachingConnectionFactory - Channel shutdown: channel error; protocol method: #method(reply-code=406, reply-text=PRECONDITION_FAILED - inequivalent arg 'x-message-ttl' for queue 'queue1' in vhost '/': received '60000' but current is '100000', class-id=50, method-id=10)
And then an exception is thrown when we try to send message to the queue:
[http-nio-8080-exec-8] ERROR [P181786EJG755SN8I3S74584216UV1] No reply received - perhaps a timeout in the template? org.springframework.remoting.RemoteProxyFailureException: No reply received - perhaps a timeout in the template? at org.springframework.amqp.remoting.client.AmqpClientInterceptor.invoke(AmqpClientInterceptor.java:60) at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:179) at org.springframework.aop.framework.JdkDynamicAopProxy.invoke(JdkDynamicAopProxy.java:207) at com.sun.proxy.$Proxy83.getUserById(Unknown Source)
Search on the internet gave the following result:
http://forum.spring.io/forum/spring-projects/integration/amqp/124865-unexpected-behaviour-with-rabbit-admin And especially, this bug: https://jira.spring.io/browse/AMQP-266
After we have found that bug, we have changed TTL values for both queues to 60000, and Error is not shown anymore. And application is running fine. So, it seems that there is still a bug with TTL.