How to load balance users over an ejabberd cluster?
I need to ca开发者_如何学JAVAter for 20,000 connected users in a 4-node ejabberd cluster. How would you distribute incoming connections over multiple ejabberd nodes?
To load balance XMPP TCP/IP traffic, you simply need to but a TCP/IP load balancer. From HAProxy, to Amazon LBS or BIGIP, choose your favorite one.
A way to load balancing without introducing SPOFs is to use multiple SRV records. IF the clients you are providing the service to support it (i.e. they perform DNS queries to _xmpp-client._tcp.yourdomain), then you get load balancing (with "weights" inside the same priority group) and failover too (assigning a lower priority to a failover group).
精彩评论