[rabbitmq-discuss] Priority Queue
tonygarnockjones+rabbitmq at gmail.com
Wed Dec 28 18:45:47 GMT 2011
I got most-of-the-way through writing up a blog post describing how to do
this before I found I'd been handily beaten to the punch: Doug Barth's post
a good job of explaining one solid way of achieving basic message
The key insight is to *make sure higher-priority messages never get stuck
behind lower-priority messages*. This manifests in a few ways:
- the creation of multiple queues, avoiding getting stuck behind
low-priority messages in a single queue
- the creation of multiple channels (or even connections!), avoiding
getting stuck behind messages travelling on a single TCP link
- the creation of multiple in-memory queue objects on the client side,
avoiding gettings stuck behind messages in a single in-memory queue object
- careful attention to the approach taken to removing messages from the
in-memory queues: every time a message is needed, check the
highest-priority queue first.
Basically, provide ways for messages to overtake each other as required,
and then always check the fast-path first.
On 28 December 2011 01:58, Dhaneesh Radhakrishnan <dhaneesh at hifx.co.in>wrote:
> We are implementing RabbitMQ queues for an application that has
> to asynchronously handle a number of jobs
> we need to know whether rabbitmq support the priority queue
> Any pointers for more information about it would be highly appreciated.
> Thanks and Regards
> Dhaneesh R
> rabbitmq-discuss mailing list
> rabbitmq-discuss at lists.rabbitmq.com
tonygarnockjones at gmail.com
-------------- next part --------------
An HTML attachment was scrubbed...
More information about the rabbitmq-discuss