[rabbitmq-discuss] message durability, cluster

Jerry Kuch jkuch at gopivotal.com
Sun Oct 6 20:35:55 BST 2013

On Fri, Oct 4, 2013 at 9:43 AM, Vasiliy Boulytchev <vasiliyb at gmail.com>wrote:

> Folks,
>   Please correct me if I am wrong...  After each message is published to
> an exchange, the client receives a confirmation that the message was
> received.

Not by default.  If you use an AMQP transaction or the RabbitMQ "publisher
confirms" extension, than you can get this sort of notification,
synchronously in the case of the former, and asynchronously in the case of
the latter.

> Does this message get sent by RabbitMQ server after this message has been
> send to all nodes in the cluster?

It depends.  For example if you publish to an exchange with no bound
queues, your message goes nowhere.  Otherwise it will be routed into bound
queues according to its routing key, the exchange type, and the binding
keys used.

By default a queue exists, backed by a single Erlang process, on a single
node in the cluster.  If you're using mirrored queues, then other replicas
of the queue will exist, on other nodes, and in that case the message will
be replicated into the mirrors.  The publish will be informed only if he's
using one of the above mechanisms (transactions or publisher confirms) as
for mirrored queues, the scopes of these mechanisms span all mirrors of the

>  Does this message get sent when the message has been written to disk?

If you published your message with the persistence flag, then the operation
is not considered successfully done until the queue persists the message,
or in the case of mirroring, all mirrors do so.  The confirmation is sent
only when what you asked for is done.

>  Does this message get sent after a shovel policy has been applied?

I'm not sure what you mean by shovel "policy" since in recent Rabbits that
term has a specific meaning.

But shovel works by having an Erlang process within the source broker
consume out of a queue bound to the source exchange and republish via AMQP
to an exchange on a remote broker.  The scope of transaction or confirm
gets you only as far as the hidden queue from which shovel is pulling for
republication and tells the initial publisher nothing about what the shovel
did or didn't do afterward.

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.rabbitmq.com/pipermail/rabbitmq-discuss/attachments/20131006/1d51f0a9/attachment.htm>

More information about the rabbitmq-discuss mailing list