[rabbitmq-discuss] RabbitMQ server closing connection every few minutes
David Tinker
david.tinker at gmail.com
Tue May 22 07:34:13 BST 2012
Hi
We have a Java application using RabbitMQ that keeps getting its
connection closed by the server every few minutes. On the client side
we see this:
2012-05-22 05:30:05,337 [AMQP Connection 127.0.0.1:5671] ERROR
pork.RabbitService - Connection to Rabbit Exchange shutting down:
com.rabbitmq.client.ShutdownSignalException: connection error; reason:
java.net.SocketException: Connection reset
Reason: java.net.SocketException: Connection reset
On the server side we get this:
=INFO REPORT==== 22-May-2012::05:25:20 ===
accepting AMQP connection <0.32660.612> (127.0.0.1:45458 -> 127.0.0.1:5671)
=ERROR REPORT==== 22-May-2012::05:30:05 ===
closing AMQP connection <0.32660.612> (127.0.0.1:45458 -> 127.0.0.1:5671):
{timeout,running}
It happens more frequently when the system is busy (500-1000
messages/s) than when it is cruising (50 messages/s). The application
and RabbitMQ are on the same box so I don't think its a
networking/firewall problem.
The application only uses one connection and one channel. Messages are
received using Connection.basicConsume(..) and acked or nacked
sometime later on different threads. It can sometimes be several
minutes before a message is acked or nacked. We are using
Connection.basicQos(10000) to limit the number of outstanding messages
but its not often that reaches 10000 and the error happens anytime.
There is defensive code to make sure messages are not acked/nacked
more than once.
Anyone have any ideas? Is there any way to get more information on the
server or client side regarding the error?
RabbitMQ 2.8.1 on Gentoo Linux 64bit
Erlang R15B (erts-5.9) [source] [64-bit]
amqp-client-2.8.2 (also tried amqp-client-2.7.1)
java version "1.6.0_31"
Java(TM) SE Runtime Environment (build 1.6.0_31-b04)
Java HotSpot(TM) 64-Bit Server VM (build 20.6-b01, mixed mode)
Thanks
David
More information about the rabbitmq-discuss
mailing list