[rabbitmq-discuss] auto-delete exchange kills connections on consumer close?

Keith Irwin keith at zentrope.com
Tue Dec 6 06:00:41 GMT 2011


I'm using RabbitMQ (2.7.0 all around + java with Clojure) to send small 
little status messages around here and there. It works great for that. 
Because I don't care if these messages get dropped if, say, RabbitMQ goes 
down, or if some client messes up here or there, I want to keep everything 
temporary. When all the clients are stopped, I'm thinking, RabbitMQ should 
be back to its default state.

So, when I use exchangeDeclare, I set auto-delete for the exchange to true. 
Here are my expectations:

 - When there are no more clients consuming or publishing to that 
particular exchange, it'll disappear.

What ACTUALLY happens is that when the first user of that exchange is 
closed (by calling close on a channel), the exchange is deleted, and all 
other users of that exchange get disconnected.

Is this a bug?

Should you always set autoDelete to false if there is ever going to be more 
than one client using an exchange? And isn't there always going to be 
another client using that exchange given there's no point in using an MQ 
system otherwise?

Please, set me straight! ;)


-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.rabbitmq.com/pipermail/rabbitmq-discuss/attachments/20111205/57a57701/attachment.htm>

More information about the rabbitmq-discuss mailing list