How does ejabberd clustering work conceptually

ejabberdxmpp

I am a complete newbie to XMPP and ejabberd. I would be very thankful if some expert could tell me, how the ejabberd "clustering" works. I searched a lot, but could not find any specs about this.

Does it simply replicate all it's data via http (so it doesn't matter where a client connects)?
Or will it be done via DNS RR?

Best Answer

It uses the clustering capabilities of Erlang : - The ability to message any process on a any node in the erlang cluster - it also uses mnesia, erlang's distributed database for storing the routing table, which contains the JID <-> client process id mapping.

When a message enters ejabberd, it looks up the recipient JID in this table, and sends it to the PID it finds. This process can be anywhere in the cluster, erlang takes care of routing it.

Related Topic