Hi,


I want to understand how publisher confirms [1] work internally and
asynchronously. The async publisher example [2] _deliveries is a list of
message number which were published and when they are confirmed, these
numbers are removed from _deliveries.


What happens when a durable message is published with publisher confirms
and the producer is stopped, i.e. we don't know if a confirm was received.
In such a case if the message reaches the broker but the broker fails to
send confirms back, is the message dropped? When I stop the consumer I wait
to receive any leftover confirms and I see that even after say 60s the
_deliveries is not empty. How may I make sure messages which were sent
confirm asynchronously and if I should wait for sometime before closing the
channel how may I determine the wait time period?


How does confirms work internally at the broker level, as in the latest
RabbitMQ server.


[1] http://www.rabbitmq.com/confirms.html
[2]
https://pika.readthedocs.org/en/latest/examples/asynchronous_publisher_example.html


Regards.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.rabbitmq.com/pipermail/rabbitmq-discuss/attachments/20130627/bae83ee6/attachment.htm>

Search Discussions

  • Emile Joubert at Jun 27, 2013 at 9:39 am
    Hi,


    On 26/06/13 23:57, Rohit Yadav wrote:

    What happens when a durable message is published with publisher confirms
    and the producer is stopped, i.e. we don't know if a confirm was
    received. In such a case if the message reaches the broker but the
    broker fails to send confirms back, is the message dropped?

    No, messages that have reached the broker won't get dropped because a
    publisher stops. Messages may still be dropped for unrelated reasons
    (e.g. TTL exceeded).

    When I stop the consumer I wait to receive any leftover confirms and
    I see that even after say 60s the _deliveries is not empty.

    I'm uncertain what your expectation is. The presence of a consumer won't
    necessarily have much affect on publisher confirms. If the publisher
    channel has closed then that could be a reason why no further
    confirmations are received.

    How may I make sure messages which were sent confirm asynchronously
    and if I should wait for sometime before closing the channel how may
    I determine the wait time period?

    It is not possible to place an upper bound on the waiting time.






    -Emile
  • Simon MacMullen at Jun 27, 2013 at 9:49 am

    On 27/06/13 10:39, Emile Joubert wrote:
    It is not possible to place an upper bound on the waiting time.

    But just to reassure the OP, it should in general be quite low - in
    practice I would expect less than one second inside the broker.


    Cheers, Simon


    --
    Simon MacMullen
    RabbitMQ, Pivotal
  • Simon MacMullen at Jun 27, 2013 at 9:39 am

    On 26/06/13 23:57, Rohit Yadav wrote:
    What happens when a durable message is published with publisher confirms
    and the producer is stopped, i.e. we don't know if a confirm was
    received. In such a case if the message reaches the broker but the
    broker fails to send confirms back, is the message dropped?

    No.

    When I stop
    the consumer I wait to receive any leftover confirms and I see that even
    after say 60s the _deliveries is not empty. How may I make sure messages
    which were sent confirm asynchronously and if I should wait for sometime
    before closing the channel how may I determine the wait time period?

    You should get confirms back quickly. The confirm is *not* an indication
    that the message has been consumed, it means the broker has taken
    responsibility for the message.

    How does confirms work internally at the broker level, as in the latest
    RabbitMQ server.

    See http://www.rabbitmq.com/confirms.html#when


    Cheers, Simon


    --
    Simon MacMullen
    RabbitMQ, Pivotal

Related Discussions

Discussion Navigation
viewthread | post
Discussion Overview
grouprabbitmq-discuss @
categoriesrabbitmq
postedJun 26, '13 at 10:57p
activeJun 27, '13 at 9:49a
posts4
users3
websiterabbitmq.com
irc#rabbitmq

People

Translate

site design / logo © 2017 Grokbase