How to change http-bind to websocket for mobile?

hi, i changed http bosh (http-bind) to wss websoket in config file of react app. its working fine for web. i can start call over websocket but its not working for react-native mobile app. Should i change anywhere in react-native code?. Please guide me. Thanks

@saghul @damencho can you guys please help and reply ? Thanks

We are not ready to enable it on mobile yet.

1 Like

Thank you for response. So does it mean if we use websockets instead of http-bind it will not work on react native mobile application ?

Just enable both. Web will use one, mobile the other.

1 Like

Ok, I will try that. Thank you for quick response.

@Ghafar_Tanveer, @Amjad-finfirst Can you tell us a little about your use-case? We may be interested in exploring something similar.

Quanto é utilizado de dados móveis em uma hora de reunião?

is there any progress about enabling websocket for mobile :slight_smile:

No progress yet.

@saghul any progress on this?

Nope, sorry.

According to the changelogs, version 21.4.0 has support for websocket ( Added support for XMPP WebSocket connections (behind a flag)). However, at my nginx config, when I disable BOSH connections, iOS clients are unable to connect to the room. Is there anything I am missing

You need to enable the config flag that allows it: jitsi-meet/config.js at 483bc45d5962e46071c91af20d31c8ab341b53d9 · jitsi/jitsi-meet · GitHub

Set that to 100 and you’re off to the races.

1 Like

Thanks, @saghul !
I did this and mobile iOS wasn’t able to connect. However, I had disabled BOSH to make sure websocket would be used. Should I enable BOSH again on nginx as it is somehow still used along websocket for mobile connection?

Try reinstalling the app, we are quite aggressive caching the config file.

@saghul How Can we enable WebSocket for all the mobile users?

in the config, it says only 10% of the users so.
// Enables XMPP WebSocket (as opposed to BOSH) for the given amount of users.
// mobileXmppWsThreshold: 10 // enable XMPP WebSockets on mobile for 10% of the users

You can but, we have some more work to do to properly detect disconnections, so I wouldn’t recommend doing it.