Re: How to handle full exchange history delivery
You'd have to use a custom exchange. Not sure if that's an issue in your scenario or not.
Thanks!
Jon Brisbin
http//jbrisbin.com
From: "Simone Busoli" <Simone.Busoli-sKiPNUh8iG9BDgjK7y7TUQ@public.gmane.org>
To: rabbitmq-discuss <at> lists.rabbitmq.com
Sent: Wednesday, June 1, 2011 5:52:24 AM
Subject: [rabbitmq-discuss] How to handle full exchange history deliveryHi,
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.
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.
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), then 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.
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.
I’m probably missing something obvious, any advice about how others would approach this scenario is appreciated.
Simone
_________________________________________________________________________________________________________________
Questo messaggio e da intendersi esclusivamente ad uso del destinatario e puo contenere informazioni che sono di natura privilegiata, confidenziale
o non divulgabile secondo le leggi vigenti. Se il lettore del presente messaggio non e il destinatario designato, o il dipendente/agente responsabile
per la consegna del messaggio al destinatario designato, si informa che ogni disseminazione, distribuzione o copiatura di questa comunicazione e
strettamente proibita anche ai sensi del decreto legislativo 196/03 . Se avete ricevuto questo messaggio per errore, vi preghiamo di notificarcelo
immediatamente a mezzo e-mail di risposta e successivamente di procedere alla cancellazione di questa e-mail e relativi allegati dal vostro sistema.
_________________________________________________________________________________________________________________
This message is intended only for the use of the addressee and may contain information that is privileged, confidential and exempt from
disclosure under applicable law. If the reader of this message is not the intended recipient, or the employee or agent responsible for delivering the
message to the intended recipient, you are hereby notified that any dissemination, distribution or copying of this communication is strictly
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
your system.
_________________________________________________________________________________________________________________
_______________________________________________
rabbitmq-discuss mailing list
rabbitmq-discuss-ETbvJ2rUIr4qBm01orBoR9BPR1lH4CV8@public.gmane.org
https://lists.rabbitmq.com/cgi-bin/mailman/listinfo/rabbitmq-discuss
<div><div>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><blockquote>From: "Simone Busoli" <Simone.Busoli@...><br>To: rabbitmq-discuss <at> lists.rabbitmq.com<br>Sent: Wednesday, June 1, 2011 5:52:24 AM<br>Subject: [rabbitmq-discuss] How to handle full exchange history delivery<br><br><div class="WordSection1"> <p class="MsoNormal">Hi,</p> <p class="MsoNormal"> </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"> </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), then 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"> </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"> </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"> </span></p> <p class="MsoNormal"><span lang="EN-US">Simone</span></p> </div> <p>_________________________________________________________________________________________________________________<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></p> <br>_______________________________________________<br>rabbitmq-discuss mailing list<br>rabbitmq-discuss@...<br>https://lists.rabbitmq.com/cgi-bin/mailman/listinfo/rabbitmq-discuss<br> </blockquote> <br> </div></div>
RSS Feed