-
Notifications
You must be signed in to change notification settings - Fork 750
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Allow empty array for "stun_servers" and "turn_servers" #206
Comments
Old: dictionary RTCIceServer { DOMString url; DOMString? credential; }; New: dictionary RTCIceServer { (DOMString or sequence<DOMString>) urls; DOMString? username = null; DOMString? credential; }; Note: Current Firefox Nightly "28.0a1 (2013-11-18)" Does not support multiple 'urls'
Overall only null and undefined should be counted as a request for default value for any parameter in my opinion. So, I'd go for solution 1. |
Right, my point is "what should be the default value for 'stun_servers' passed to
So, what should be the default value in JsSIP's "stun_servers" and "turn_servers" parameter? |
The default should be null or undefined in my opinion, since an empty array says explicitly that no STUN or TURN should be used. |
Fine with me. But it must be clearly documented in the API that not setting "stun_servers" means "use whichever STUN settings the browser uses by default, if any". |
I don't actually mind having the google server as default - and in my opinion otherwise it should default to an empty array (null or undefined will probably fail and cause an error, not verified). If STUN server defaults to null it would make more sense to make it a required parameter (but then again, it makes more sense to leave it optional and default to [] or google server not to cause an error). So, default to empty array (preferred) or the google server (may work in most circumstances) in my opinion. |
Read the above comments more carefully now. If null or undefined will not cause an error, just passing on whatever value would be fine. |
@ibc, I've tested Chrome 35.0 and FF and Chrome does not use any STUN server when passing a null or undefined parameter to the RTCPeerConnection constructor. FF does use a default STUN server on the other hand. Did you try Chrome? |
@jmillan: Honestly, no idea, I thought so but may be I was wrong or things have changed or whatever.
Yes, passing anything but an array as "iceServers" value causes an error.
Please let's just talk about JsSIP "stun_servers" parameters (to avoid confusion). Which should be its default value if not set (regardless what each browser does if "iceServers" is not set in a PeerConnection)? I vote for empty array (so no STUN servers as the empty array will be passed to the PeerConnection as "iceServers" value). |
vote++ for empty array |
I come back to this after some time. If stun_servers configuration parameter is not set, it should take a default STUN server (google) Unless explicitly said, it should always use a STUN server. That's my rationale. |
I don't like the idea of relying on any server given that the domain may change or whatever, but I'm ok with that. It's harmless. |
IMHO it's a plus if we don't force the developer to set a stun server in order to be able to actually use one, transparently. |
Fine. Can we close this issue? (not sure if it's currently implemented). |
As far as I can see this is still not fixed. Default should be no STUN servers in my opinion. Because I need to use no STUN servers I currently use this patch (only add servers if available): |
Hi guys, all the WebRTC related issues are being closed due to the new approach for JsSIP 0.4 as explained here: Thanks to all for your contribution to the project. |
Proposal 1
Proposal 2
I vote for proposal 2, but I'm fine with proposal 1.
The text was updated successfully, but these errors were encountered: