W3C home > Mailing lists > Public > public-webrtc@w3.org > February 2014

Re: Panic between createOffer() and setLocalDescription()

From: Thomas Bruun <thomas@appear.in>
Date: Thu, 20 Feb 2014 13:36:19 +0100
Message-ID: <CAAhq9mjmhBSj534dejwF++qDG8to0fuN+vQb+EMSVVWqxO4icg@mail.gmail.com>
To: "piranna@gmail.com" <piranna@gmail.com>
Cc: Harald Alvestrand <harald@alvestrand.no>, public-webrtc <public-webrtc@w3.org>
On Thu, Feb 20, 2014 at 10:44 AM, piranna@gmail.com <piranna@gmail.com> wrote:
> I'm not saying to remove setLocalDescription(), I'm only saying that
> for most use cases is redundant to call to
> createOffer()/createAnswer() and inmediately to setLocalDescription(),
> so I'll change the spec to do the call implicitly and if some changes
> are required, let the user to do the call explicitly, overwritting
> this way the content of the local description with its custom one.
> This will make easier to new comers what's the call flow:
>
> createOffer() -> send()
> onmessage -> setRemoteDescription()
> createAnswer() -> send()
> onmessage -> setRemoteDescription()
>
> Honestly, if you need to call to setLocalDescription() with a modified
> SDP, you are not in "WebRTC 101" anymore... Why complicate it?

Keep in mind that setLocalDescription() today doesn't just set a
variable on the RTCPeerConnection object. For example, it starts ICE
gathering. What you suggest assumes that the developer wishes to start
this process when calling createOffer().

We have identified scenarios where we would want to do something with
the sdp (either edit or inspect it), before we decide if we want to
call setLocalDescription(). If setLocalDescription() is called
implicitly, we need our code to hold of on relaying the offer and ICE
candidates to the remote client in those scenarios.
Received on Thursday, 20 February 2014 16:34:06 UTC

This archive was generated by hypermail 2.3.1 : Monday, 23 October 2017 15:19:38 UTC