On 18 April 2015 at 00:12:57, Denis Abramov (
da...@columbia.edu) wrote:
> (1) So I am a little confused about what the point of clustering
> is as opposed to just keeping rabbit1,rabbit2 and rabbit3 as
> separate machines. Is the entire point of clustering that the
> exchanges are shared within the cluster?
vhosts, users, exchanges, bindings, queues, policies, and so on.
Queues can be mirrored (their content is replicated). Statistics database
collects metrics from the entire cluster and displays them in a single place.
> (2) I think I know the answer to this (the very last question) but
> just throwing it out there... So let's say the Consumer is subscribed
> to a queue or exchange. What would happen if the rabbitmq broker
> that the user is connected to goes down. Is the consumer dead?
> or once I connect to another host in the cluster all my subscriptions
> will be resumed automatically? or do I need to keep track of all
> subscriptions and re-subscribe again if a failure occurs?
Consumers only consume from queues.
Your client needs to be able to re-connect. If you use automatic recovery offered by the .NET client, your topology
will be re-declared and consumers will be re-added. Again, the .NET client currently will attempt reconnecting
to the same host, so a load balancer or round-robin DNS is necessary for it to connect to a different machine.
The automatic recovery process is documented:
http://www.rabbitmq.com/dotnet-api-guide.html#connection-recovery
You can also roll your own, although most of the time it's not necessary: the procedure we have has
been battle tested in multiple clients for a few years by now.