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

[Bug 25836] add note about addtrack being async

From: <bugzilla@jessica.w3.org>
Date: Tue, 04 Nov 2014 13:54:03 +0000
To: public-webrtc@w3.org
Message-ID: <bug-25836-4991-AxrKqxctdX@http.www.w3.org/Bugs/Public/>

--- Comment #4 from Adam Bergkvist <adam.bergkvist@ericsson.com> ---
(In reply to Harald Alvestrand from comment #2)
> The addtrack operation is synchronous, but it causes things to happen that
> are easier to describe as a queued task (stuff that happens in stable state).
> Exemplar case:
> createOffer().then(offer =>)
> AddTrack(track)
> Will the offer include the added track or not?

What do we want the answer to be?

With addTrack() async the answer is *no*. The task that adds the tracks is
still on the operations queue when the createOffer task is picked up.

With addTrack(), with a return value, we can decide how we want it to be. If a
snapshot of the added tracks is taken when createOffer() is picked up by the JS
scheduler and stored for later processing in the queued operation, the answer
is *no*. If we don't look at the added tracks until the createOffer task is
picked up, then the track will be included and the answer is *yes*.

We need to document this.

You are receiving this mail because:
You are on the CC list for the bug.
You are the assignee for the bug.
Received on Tuesday, 4 November 2014 13:54:07 UTC

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