[rabbitmq-discuss] Two questions: max bindings and handling no consumer present

Matthias Radestock matthias at rabbitmq.com
Wed Aug 1 09:08:56 BST 2012

On 01/08/12 08:23, Tim Watson wrote:
> On 1 Aug 2012, at 04:10, "Bell, Paul M." <pbell at syncsort.com> .
>> I suppose this is where the "mandatory" flag comes in. But I'm
>> wondering if there's a way to query  the broker about its
>> infrastructure, e.g., the existence of a queue/binding that would
>> indicate the presence of the consumer.
> There are ways to query the infrastructure, but these rare generally
> not exposed to client APIs. What client are you using?

Moreover, performing such a "does a consumer exists?" query before 
publishing is racy, since the consumer might well vanish between the 
query and the publishing event.

What are you actually trying to accomplish? Is the idea that in the 
absence of consumers the producer would hang on to the message and retry 
later? In that case you may want to consider alternative routing 
topologies. E.g. perhaps the consumer queues could be declared ahead of 
time. Or you could use an alternate exchange to route messages to 
holding queue where they are then picked up from consumers when they 
join. Or you could do something even more sophisticated and configure 
said holding queue with a message-ttl and set the original exchange as 
the dead-letter exchange of the queue - that way messages will be 
retried periodically automatically.


More information about the rabbitmq-discuss mailing list