Note that there are some explanatory texts on larger screens.

plurals
  1. PO
    primarykey
    data
    text
    <p>I haven't seen any clients that do connection pooling for AMQP/RabbitMQ. AMQP handles multiple publishers/consumers in a single process with channels and some clients make that easy to use but don't seem to handle automated failover of nodes using a connection pool. </p> <p>In a cluster there is no need to connect to all nodes in the cluster, consume and publish operations will be correctly routed within the cluster. For consuming trying to manage either single or multiple processes with multiple subscriptions (at least one consume for each connection) has never been the highest priority for me. With multiple processes consuming, each randomly connecting to RabbitMQ, you will be able to maintain availability should one of the RabbitMQ nodes fail.</p> <p>Publishers in long-lived connections are easily able to reconnect if a failure is detected causing less than a second of disruption, small enough in anything I've worked on to not be a problem. </p> <p>From a few years of usage I would say that reconnecting to a new host is the simpler problem during a failover with the difficult problem being managing the state within your application in regards to existing AMQP connections. In practice I've just kept a list of the hosts available and pick the next one for each new connection. Any time the connection closes just pick a new host and try again. It does mean a short time where you cannot publish and may be more difficult if you have to constantly make new connections in PHP. </p> <p>Due to <a href="http://www.rabbitmq.com/memory.html" rel="nofollow">flow control</a> TCP load balancers may be more trouble then they are worth. The TCP back pressure may not make it through the LB causing publishers to publish faster than RabbitMQ can handle. In unscientific tests I've had more issues with RabbitMQ stability when it was behind a load balancer then when clients connected directly. </p>
    singulars
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    plurals
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload