[rabbitmq-discuss] Using Pika Python client library with BlockingConnections and publisher-confirms - Does it work?

Gavin M. Roy gmr at myyearbook.com
Mon Feb 6 18:47:14 GMT 2012

There are multiple ways, the best from my perspective is Publisher confirms: http://www.rabbitmq.com/extensions.html#confirms

Using Pika, you'll have to grab the master branch at github as 0.9.5 does not support them and 0.9.6 is not released yet (though I am making progress in adding the test coverage I'd like to have there prior to releasing it)

Here's the method to enable it:


In short:


When a message is delivered, you'll now get a callback frame/message to the delivery_confirmation_callback method (whatever you replace that with).

In doing this you'll need to keep track of what you published, sequence wise on the channel to use to validate the delivery tag in the Basic.Ack frame.

Hope this helps,


On Monday, February 6, 2012 at 1:29 PM, Matt Pietrek wrote:

> Thanks Ask and Marek for your replies.
> Let me circle back to the original issue. Our system just needs a reliable way of knowing that once we've published a message, that it's safely in the broker. The exact mechanics aren't particularly important.
> Obviously transactions will work, but they slow things down to the point where we're doubting the system performance will meet our needs. I'm happy to experiment with publisher-confirms, but it seems that given our simple, synchronous pattern, aren't easy to incorporate without contorting the code. Perhaps I'm wrong, and if so, feel free to correct me.
> What's your take here? What's the best path forward?
> In a related question, can either of you offer some insights on the planned futures of Pika / Puka / Kombu in terms of being client libraries we should rely on for commercial app development?
> Obviously if there were an official RabbitMQ Python client library, we'd choose that. In the absence of that, we're trying to evaluate the viability of Pika/Puka/Kombu, and whatever else is out there. However, it's hard to get a sense for what is "the future" and what may not be a good choice 3 years from now.
> Thanks again,
> Matt
> _______________________________________________
> rabbitmq-discuss mailing list
> rabbitmq-discuss at lists.rabbitmq.com (mailto:rabbitmq-discuss at lists.rabbitmq.com)
> https://lists.rabbitmq.com/cgi-bin/mailman/listinfo/rabbitmq-discuss

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.rabbitmq.com/pipermail/rabbitmq-discuss/attachments/20120206/4c08c90a/attachment.htm>

More information about the rabbitmq-discuss mailing list