[bunny-amqp-devel] using bunny with qos

17 views
Skip to first unread message

vishnu

unread,
Mar 17, 2010, 1:25:45 AM3/17/10
to bunny-am...@rubyforge.org

Hi Chris
and how it's needed if subscribers subscribing in ack mode need to use qos if they are likely to call other methods on bunny.

I had a couple of questions though. I realise I didn't quite follow somethings there.
The first is about prefetch count. If I use qos with a prefetch count greater than 1, won't I have the same problem that your example raised? Or is it a matter of picking up a small enough prefetch count that all these messages are recieved by bunny before the subscribe block executes?

The other question was if qos is required if a subscribe block is going to perform a publish? Is there a publish ok message that the server sends back?

thanks
Vishnu

Chris Duncan (Frugal IT)

unread,
Mar 17, 2010, 2:59:57 AM3/17/10
to vishnu, bunny-am...@rubyforge.org
Hi Vishnu.

On 17 Mar 2010, at 05:25, vishnu wrote:


Hi Chris
and how it's needed if subscribers subscribing in ack mode need to use qos if they are likely to call other methods on bunny.

I had a couple of questions though. I realise I didn't quite follow somethings there.
The first is about prefetch count. If I use qos with a prefetch count greater than 1, won't I have the same problem that your example raised? Or is it a matter of picking up a small enough prefetch count that all these messages are recieved by bunny before the subscribe block executes?


If you are not making any synchronous AMQP calls in the block then everything should work with a prefetch count greater than 1. AMQP method calls that return a message are the things that give you a problem because the reply message from the block gets mixed up with the other messages that you are consuming.

The other question was if qos is required if a subscribe block is going to perform a publish? Is there a publish ok message that the server sends back?

Publishing from the block should be OK because it is an asynchronous AMQP method according to the AMQP spec and therefore there is no publish_ok reply message.


thanks
Vishnu


Regards,

Chris

vishnu

unread,
Mar 17, 2010, 5:01:17 AM3/17/10
to bunny-am...@rubyforge.org
aha thanks
Reply all
Reply to author
Forward
0 new messages