Andrew Stitcher wrote:
On Wed, 2009-12-16 at 09:56 -0500, Alan Conway wrote:
I'm looking at some code that does sender flow control as follows:
- set a queue size limit
- sender catches 'resource-limit-exceeded' exception, sleeps for a bit,
creates a new session & re-tries
The essential problem with this approach is that the queue size is not
directly caused by any single producer. So it's entirely possible in
general for a producer that is producing at a low rate to be entirely
killed by another producer sending messages into the same queue.
The only way that this overall scheme can work fairly is if there is a
1-1 producer-queue mapping. If that is the case then it should work.
Why wouldn't we use flow control as specified by the protocol? It
doesn't help you figure out *who* to flow control, but once you've made
that decision, it provides a much better way to actually flow control an
individual producer.
--Rafael
---------------------------------------------------------------------
Apache Qpid - AMQP Messaging Implementation
Project: http://qpid.apache.org
Use/Interact: mailto:[email protected]