client-sdk-flutter icon indicating copy to clipboard operation
client-sdk-flutter copied to clipboard

Automatically disconnect from the room when exit/close the app.

Open cloudwebrtc opened this issue 3 years ago • 2 comments

when you exit the app, it should automatically disconnect from the room. Otherwise, the participant would look "stuck" to the other participants for 15+ s

cloudwebrtc avatar Aug 15 '22 09:08 cloudwebrtc

We also experienced it and after it stuck, for about 5 minutes I can't connect with that participant to any room. That's what you meant by "stuck"?

janoskranczler avatar Oct 19 '22 08:10 janoskranczler

Hey @janoskranczler, this is actually a different issue. This happens when the application developer doesn't manually call Room.disconnect.

When that happens, the SFU would not know the user has intended to leave the room. During which time, the user will still be visible in the room to other participants. It will be removed after server times out the connection, which takes about 15-20s.

davidzhao avatar Oct 21 '22 16:10 davidzhao

I used this flutter_window_close to intercept the app close event, and call room.disconnect() before confirming the close;

cloudwebrtc avatar Dec 05 '22 01:12 cloudwebrtc

i think it should be sdk user to take care of this. currently it make app not closable;

https://github.com/livekit/client-sdk-flutter/issues/407

wanjm avatar Nov 28 '23 09:11 wanjm