<div>Hi Matthias,�</div><div><br></div><div>Thanks for quick response. My scenarios is a bit different. �Here is what I have tried which causes that all messages to be deleted.�</div><div><br></div>1) start two nodes (A&amp;B)<br>
2) declare a durable mirrored queue, mirrored on all nodes<br>3) publish messages that get routed to the queue<div>� �<b> -- messages are on both A &amp; B</b><br>4) shut down node A<div><b>5) startup node A</b></div><div>
<b>� � -- messages are deleted on A</b></div><div><b>� � -- messages are unsynchronized on B<br></b>6) shut down node B<br>7) start up node B</div><div>� � <b>-- messages are deleted �on B</b></div><div><br></div><div><br>
</div><div>Yes, the message are published persistently.�</div><div><br></div><div>Thanks,<br><br><div class="gmail_quote">On Mon, Jul 23, 2012 at 11:08 AM, Matthias Radestock <span dir="ltr">&lt;<a href="mailto:matthias@rabbitmq.com" target="_blank">matthias@rabbitmq.com</a>&gt;</span> wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">Farshad,<br>
<br>
please keep the list on &#39;cc&#39;...<div class="im"><br>
<br>
On 23/07/12 18:18, Farshad Meshkinpour wrote:<br>
</div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div class="im">
Thanks for your response. �I read this document and I am still a bit<br>
�puzzled. �The document says:<br>
<br></div>
If the mirrored-queue was declared /durable/ then, if its last<div class="im"><br>
remaining node is shutdown, durable messages in the queue will<br>
survive the restart of that node.<br>
<br>
But I noticed if stop and start the second node in the cluster (last<br>
�node), the messages do not survive.<br>
</div></blockquote>
<br>
So you are doing the following?<br>
<br>
1) start two nodes (A&amp;B)<br>
2) declare a durable mirrored queue, mirrored on all nodes<br>
3) publish messages that get routed to the queue<br>
4) shut down node A<br>
5) shut down node B<br>
6) start up node B<br>
<br>
?<br>
<br>
That should not lose any messages provided the messages are published as<br>
*persistent*. See the &#39;Message durability&#39; section in <a href="http://www.rabbitmq.com/tutorials/tutorial-two-python.html" target="_blank">http://www.rabbitmq.com/<u></u>tutorials/tutorial-two-python.<u></u>html</a>. Are you doing that?<div class="im">
<br>
<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
It seems that there needs to be some wait time before<br>
stopping/starting of last node. �Otherwise, the last node does not<br>
know that it is the last node. � Is it correct? �If so, what is this<br>
time period.<br>
</blockquote>
<br></div>
Publishing is async, so in general a client doesn&#39;t know when the<br>
server has taken responsibility for a message. The time it takes for<br>
that to happen is typically very short though, unless the server is<br>
heavily loaded. Publisher confirms - <a href="http://www.rabbitmq.com/extensions.html#confirms" target="_blank">http://www.rabbitmq.com/<u></u>extensions.html#confirms</a> - notify the publishing client when messages have been accepted by the server.<br>

<br>
Regards,<br>
<br>
Matthias.<br>
</blockquote></div><br></div></div>