<html><head><style type='text/css'>p { margin: 0; }</style></head><body><div style='font-family: Times New Roman; font-size: 12pt; color: #000000'>I've been seriously considering adding this functionality to the Riak-backed custom exchange. It was something I thought I would add first time through but didn't.<br><br>You'd have to use a custom exchange. Not sure if that's an issue in your scenario or not.<br><span><br><span name="x"></span><br>Thanks!<br><br>Jon Brisbin<br>http//jbrisbin.com<br><span name="x"></span><br></span><br><hr id="zwchr"><blockquote style="border-left: 2px solid rgb(16, 16, 255); margin-left: 5px; padding-left: 5px; color: rgb(0, 0, 0); font-weight: normal; font-style: normal; text-decoration: none; font-family: Helvetica,Arial,sans-serif; font-size: 12pt;"><b>From: </b>"Simone Busoli" &lt;Simone.Busoli@ferrari.com&gt;<br><b>To: </b>rabbitmq-discuss@lists.rabbitmq.com<br><b>Sent: </b>Wednesday, June 1, 2011 5:52:24 AM<br><b>Subject: </b>[rabbitmq-discuss] How to handle full exchange history delivery<br><br>



<style><!--
/* Font Definitions */
@font-face
        {font-family:Calibri;
        panose-1:2 15 5 2 2 2 4 3 2 4;}
/* Style Definitions */
p.MsoNormal, li.MsoNormal, div.MsoNormal
        {margin:0in;
        margin-bottom:.0001pt;
        font-size:11.0pt;
        font-family:"Calibri","sans-serif";
        mso-fareast-language:EN-US;}
a:link, span.MsoHyperlink
        {mso-style-priority:99;
        color:blue;
        text-decoration:underline;}
a:visited, span.MsoHyperlinkFollowed
        {mso-style-priority:99;
        color:purple;
        text-decoration:underline;}
span.EmailStyle17
        {mso-style-type:personal-compose;
        font-family:"Calibri","sans-serif";
        color:windowtext;}
.MsoChpDefault
        {mso-style-type:export-only;
        font-family:"Calibri","sans-serif";
        mso-fareast-language:EN-US;}
@page WordSection1
        {size:8.5in 11.0in;
        margin:1.0in 1.0in 1.0in 1.0in;}
div.WordSection1
        {page:WordSection1;}
--></style><!--[if gte mso 9]><xml>
<o:shapedefaults v:ext="edit" spidmax="1026" />
</xml><![endif]--><!--[if gte mso 9]><xml>
<o:shapelayout v:ext="edit">
<o:idmap v:ext="edit" data="1" />
</o:shapelayout></xml><![endif]-->

<div class="WordSection1">
<p class="MsoNormal">Hi,</p>
<p class="MsoNormal">&nbsp;</p>
<p class="MsoNormal"><span lang="EN-US">I am trying to achieve a scenario in which messages are published from some data source into a RabbitMQ exchange and clients should be able to receive the full history of messages flown through that exchange, regardless
 of the exact moment in time when they connect.</span></p>
<p class="MsoNormal"><span lang="EN-US">&nbsp;</span></p>
<p class="MsoNormal"><span lang="EN-US">I’ve been thinking to solve it by setting up a proxy which subscribes to the exchange where messages are published using its own queue, keeps an internal storage of the messages and accepts requests from clients.
</span></p>
<p class="MsoNormal"><span lang="EN-US">When a request from a client arrives it just replays the full message history to the client by publishing the messages to the client queue (supplied in the ReplyTo field),
<b>then</b> binds the client queue to the messages exchange, so that the client from this moment onwards starts receiving the “live” messages, and is pretty much unaware of what’s happened; it simply just receives the whole history.</span></p>
<p class="MsoNormal"><span lang="EN-US">&nbsp;</span></p>
<p class="MsoNormal"><span lang="EN-US">Now I am under the impression that there’s a fundamental flaw in this reasoning, since the proxy cannot know when the message history has completed and he can switch the client to the live stream, because while it is
 replaying historical messages to the client other live messages might be arriving on the proxy’s queue, thus getting into an endless loop.</span></p>
<p class="MsoNormal"><span lang="EN-US">&nbsp;</span></p>
<p class="MsoNormal"><span lang="EN-US">I’m probably missing something obvious, any advice about how others would approach this scenario is appreciated.</span></p>
<p class="MsoNormal"><span lang="EN-US">&nbsp;</span></p>
<p class="MsoNormal"><span lang="EN-US">Simone</span></p>
</div>
<!--[object_id=#ferrari.com#]--><p><font size="1">_________________________________________________________________________________________________________________<br>Questo messaggio e da intendersi esclusivamente ad uso del destinatario e puo contenere informazioni che sono di natura privilegiata, confidenziale<br>o non divulgabile secondo le leggi vigenti. Se il lettore del presente messaggio non e il destinatario designato, o il dipendente/agente responsabile<br>per la consegna del messaggio al destinatario designato, si informa che ogni disseminazione, distribuzione o copiatura di questa comunicazione e <br>strettamente proibita anche ai sensi del decreto legislativo 196/03 . Se avete ricevuto questo messaggio per errore, vi preghiamo di notificarcelo<br>immediatamente a mezzo e-mail di risposta e successivamente di procedere alla cancellazione di questa e-mail e relativi allegati dal vostro sistema.<br>_________________________________________________________________________________________________________________<br>This message is intended only for the use of the addressee and may contain information that is privileged, confidential and exempt from <br>disclosure under applicable law. If the reader of this message is not the intended recipient, or the employee or agent responsible for delivering the <br>message to the intended recipient, you are hereby notified that any dissemination, distribution or copying of this communication is strictly <br>prohibited. If you have received this e-mail in error, please notify us immediately by return e-mail and delete this e-mail and all attachments from <br>your system.<br>_________________________________________________________________________________________________________________<br></font></p><br>_______________________________________________<br>rabbitmq-discuss mailing list<br>rabbitmq-discuss@lists.rabbitmq.com<br>https://lists.rabbitmq.com/cgi-bin/mailman/listinfo/rabbitmq-discuss<br></blockquote><br></div></body></html>