Migrating from BOSH to WebSockets pros/cons

Dear Community,

I am compiling a list of pros/cons of migrating from using BOSH to using WebSockets for communication between the client and Prosody, in a self-hosted environment.

If you have used WebSockets to replace BOSH in your self-hosted environments, have you noticed benefits? Did you have issues while migrating? Is it worth migrating?

I noticed that https://meet.jit.si/config.js is configured to use Websockets with wss://meet.jit.si/xmpp-websocket, I am curious to hear from the Jitsi developers too.

Thank you very much in advance.

Bosh creates a new connection every now and then, while websockets create it once and use it. This brings less stress on the server when there are thousands of concurrent connections.

Thanks very much for the quick reply @damencho. Did you notice also performance improvements in the client side?

Yes, we have seen bosh to be spotty on slow networks, while websockets seems more stable and with the stream resumption it reconnects more gracefully in case of bad network continuing the previous session.

1 Like

Excellent thank you very much for the insightful comments @damencho