[rabbitmq-discuss] Question about new pika usage
Gavin M. Roy
gmr at myyearbook.com
Sun Mar 6 02:14:30 GMT 2011
On Saturday, March 5, 2011 at 9:07 PM, Taek Joo Kim wrote:
> Hi, all.
> In pika 0.5.2, I created multiple connections to rabbitmq, then made a
> socket map and passed it to pika.asyncore_loop(). Then I could poll
> multiple sockets. In pika 0.9.x, I saw the source code, but did not
> find the way to do this. The purpose of making multiple connections is
> to subscribe multiple queues.
> I have two questions.
> 1. Is this a proper way to subscribe multiple queues?
Just issue multiple channel.basic_consume commands to different queues with different callback mechanisms with any of the async connection adapters. You do not need multiple connections or channels to consume multiple queues.
With BlockingConnection there will be support for multiple queue consumers in the next release.
> 2. If it is, is there any way to do this in 0.9.x?
Check out the documentation at http://tonyg.github.com/pika, if it's not straight forward on how to get the 2nd queue consumer going, let me know.
-------------- next part --------------
An HTML attachment was scrubbed...
More information about the rabbitmq-discuss