[rabbitmq-discuss] rabbitmqctl stop_app start_app loses all messages
Farshad Meshkinpour
fmeshkinpour at fonality.com
Mon Jul 23 19:20:31 BST 2012
Hi Matthias,
Thanks for quick response. My scenarios is a bit different. Here is what I
have tried which causes that all messages to be deleted.
1) start two nodes (A&B)
2) declare a durable mirrored queue, mirrored on all nodes
3) publish messages that get routed to the queue
* -- messages are on both A & B*
4) shut down node A
*5) startup node A*
* -- messages are deleted on A*
* -- messages are unsynchronized on B
*6) shut down node B
7) start up node B
*-- messages are deleted on B*
Yes, the message are published persistently.
Thanks,
On Mon, Jul 23, 2012 at 11:08 AM, Matthias Radestock
<matthias at rabbitmq.com>wrote:
> Farshad,
>
> please keep the list on 'cc'...
>
>
> On 23/07/12 18:18, Farshad Meshkinpour wrote:
>
>> Thanks for your response. I read this document and I am still a bit
>> puzzled. The document says:
>>
>> If the mirrored-queue was declared /durable/ then, if its last
>>
>> remaining node is shutdown, durable messages in the queue will
>> survive the restart of that node.
>>
>> But I noticed if stop and start the second node in the cluster (last
>> node), the messages do not survive.
>>
>
> So you are doing the following?
>
> 1) start two nodes (A&B)
> 2) declare a durable mirrored queue, mirrored on all nodes
> 3) publish messages that get routed to the queue
> 4) shut down node A
> 5) shut down node B
> 6) start up node B
>
> ?
>
> That should not lose any messages provided the messages are published as
> *persistent*. See the 'Message durability' section in
> http://www.rabbitmq.com/**tutorials/tutorial-two-python.**html<http://www.rabbitmq.com/tutorials/tutorial-two-python.html>.
> Are you doing that?
>
>
> It seems that there needs to be some wait time before
>> stopping/starting of last node. Otherwise, the last node does not
>> know that it is the last node. Is it correct? If so, what is this
>> time period.
>>
>
> Publishing is async, so in general a client doesn't know when the
> server has taken responsibility for a message. The time it takes for
> that to happen is typically very short though, unless the server is
> heavily loaded. Publisher confirms - http://www.rabbitmq.com/**
> extensions.html#confirms<http://www.rabbitmq.com/extensions.html#confirms>- notify the publishing client when messages have been accepted by the
> server.
>
> Regards,
>
> Matthias.
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.rabbitmq.com/pipermail/rabbitmq-discuss/attachments/20120723/07fd22cb/attachment.htm>
More information about the rabbitmq-discuss
mailing list