Aidan Skinner wrote:
I wrote up a quick sketch of what I'm planning on implementing for
flow controlling producers to protect the broker from out of control
producers / dead clients causing massive build up. Comments on this
would be welcome, as I'm going to have to start hacking on it RSN.
http://cwiki.apache.org/confluence/display/qpid/Producer+flow+control
A few random questions/comments...
Why throw an exception by default? I'd think you would want a
configurable timeout, i.e. by default you block for n seconds, and when
the time is up throw an exception.
What should the client expect when an exception is thrown, did the
message go through or not?
Why stop the producer *after* putting the message on the queue? Is it
really that expensive to check whether the queue is too large *before*
putting the message on? In general this seems backwards, e.g. if a
client were to publish a single message to a queue that is full, and
then move on to other unfull queues, you could end up blocking the
client for no reason.
Are the limits going to be byte based, message based, or both?
How do you intend to block the producer?
--Rafael