You are viewing an old version of this page. View the current version.

Compare with Current View Page History

Version 1 Next »

Producer flow control is necessary to stop clients from overwhelming a broker if messages are not being consumed fast enough, this is filed in Jira as QPID-942. To implement this, the following changes are necessary:

Client:
send() needs to become potentially blocking, if the producer has been flow controlled then send() should not return until the message has been delivered to the broker

Broker:
When a message has been enqueued, the broker should check if the producer is publishing to a queue which has violated it's policy, if so then the producer will be flow controlled. When a consumer has had a message delivered, if the queue is no longer violating it's policy then producers will be unflow controlled. This check will occur after enqueing so as not to slow down the broker.

Queues and exchanges will have policies attached to them (queues will inherit from their exchange if they do not have one), which will specify the point at which producers should be flow controlled in terms of queue count or queue depth. These policies will be manageable over JMX, so they can be applied or removed without having to restart the broker.

The management console will also gain a "stop all producers" connect option to enable immediate throttling of runaway producers.

  • No labels