I have been working with XMPP related materials, and now what I have learned so far. XMPP and HTTP are two different protocols, but when you try to implement a browser-based XMPP client, XMPP traffic will be piggybacked over HTTP called XMPP-over-BOSH.
I came across Punjab, which seems like a pretty popular XMPP / BOSH connection manager and works with common XMPP servers like ejabberd and OpenFire. These regular XMPP servers such as ejabberd and Openfire seem to have built-in XMPP-over-BOSH support, so Punjab provides added functionality.
Many large sites use Punjab in their implementation of XMPP, but I could not understand why they would use it when you can directly connect the XMPP client in the browser to ejabberd or OpenFire.
Thanks.
source share