[rabbitmq-discuss] Help defining appropriate queue model

Fabio Margarido fabiomargarido at gmail.com
Wed Mar 2 16:57:14 GMT 2011


Hi Alexis.

On Wed, Mar 2, 2011 at 13:36, Alexis Richardson <alexis at rabbitmq.com> wrote:
> In the link I sent, you publish once per update, independent of the
> number of consumers.

OK.

>
>> The scenarios I can't quite grasp yet are:
>>
>> * The producer publishes the message before any consumers are running;
>
> Do you want a new consumer to see all old updates, or just the latest
> update that occurred before the new consumer connects to the broker?

I want the consumers to see just the latest update. But I figured that
as the queue is exclusive and so gets created only the moment it
starts running, it wouldn't get the message that was published prior
to that. If that's not the case, then I guess it should work.

>> * The consumer receives the message, dies and reboots, consumes the
>> same message once more.
>
> You can set things up so that the message gets requeued, but not 'in order'.

Order shouldn't matter, as I'm only interested in that latest update.

> I'd tentatively suggest that you may be talking more about a cache
> than message queue.

It is a kind of cache. I guess it could be done a number of different
ways, like setting up an NFS share and storing the config in a file or
maybe set something up in the application servers. But I figured that
since I already have the RabbitMQ infrastructure up and running for my
other (more orthodox) messaging needs, I might as well take advantage
of it for this case rather than having to maintain another service.
Thanks.


More information about the rabbitmq-discuss mailing list