GNOME Bugzilla – Bug 797012
webrtcbin: New add-turn-server API
Last modified: 2018-09-19 14:20:30 UTC
It is possible and often desirable to pass multiple ICE relays to libnice agents, the "turn-server" property, while convenient to use from the command line, does not allow that. This adds a new action signal, "add-turn-server" to address that.
Created attachment 373429 [details] [review] webrtcbin: New add-turn-server API
Review of attachment 373429 [details] [review]: Looks ok to me. You may want to add "forget-turn-servers" or "remote-turn-server" for completeness.
Created attachment 373486 [details] [review] webrtcice: do not run host resolution from applictation thread g_resolver_lookup_by_name is a blocking call, and should not be run when the user sets or adds a turn-server.
(In reply to Olivier Crête from comment #2) > Review of attachment 373429 [details] [review] [review]: > > Looks ok to me. You may want to add "forget-turn-servers" or > "remote-turn-server" for completeness. Yes indeed, though I don't yet see a use case for those, we can IMHO add these later. I've attached another commit which should go in at the same time I think, performing host resolution on the webrtcbin's task thread, as opposed to from the application thread, as it is a synchronous call that may block for a long time.
Review of attachment 373486 [details] [review]: Looks ok, but I can't help but think it would be easier to do that inside libnice itself, I've just never gotten around to add asynchronous-ness to that bit of libnice.
(In reply to Mathieu Duponchelle from comment #4) > Yes indeed, though I don't yet see a use case for those, we can IMHO add > these later. The use-case is to switch TURN servers without disconnecting the call. I guess it's a pretty specialized use-case, when you have a long running call and you want to manage a fleet of TURN servers. I guess WebRTC doesn't support that yet.
Attachment 373429 [details] pushed as 1d6160d - webrtcbin: New add-turn-server API Attachment 373486 [details] pushed as 45fe050 - webrtcice: do not run host resolution from applictation thread
Thanks, hadn't noticed the accepted-commit-nows . Regarding the removal signals, I agree that could prove useful in the future, but switching the TURN server during the call will probably not be trivial, and it's out of scope for me right now :)