Hi<div>Do you really need only 10 messages in queue? What is real number?</div><div>Can you describe you problem in details?</div><div><br><div>Also you can read more about flow control at</div><div><a href="http://www.rabbitmq.com/memory.html">http://www.rabbitmq.com/memory.html</a></div><div>and</div><div><a href="http://www.rabbitmq.com/amqp-0-9-1-reference.html#channel.flow">http://www.rabbitmq.com/amqp-0-9-1-reference.html#channel.flow</a><br><br>On Monday, July 15, 2013 5:14:40 PM UTC+3, ser...@openbridge.com wrote:<blockquote class="gmail_quote" style="margin: 0;margin-left: 0.8ex;border-left: 1px #ccc solid;padding-left: 1ex;">Hi everybody,<br><br>I tried to put a limit on the queue size using 'x-max-length', but the problem is Messages
will be dropped or dead-lettered from the front of the queue
to make room for new messages once the limit is reached.<br><div> <br>What are the possible ways to not drop the messages? Ideally I would like to throw an Exception if queue is full. <br><br>First I was thinking to check the queue size, and if it's full than stop. But for example if I have 5 producers and queue limit size is set to 10, and I already have 9 messages in the queue, than all 5 producers will check the size, and publish their messages and 4 messages will be lost.<br><br>That's how I declare x-max-length':<br><br>result = channel.queue_declare(queue='<wbr>Test', arguments={ 'x-max-length' : 10})<br></div></blockquote></div></div>