Closed Bug 1479841 Opened 6 years ago Closed 6 years ago

Start replacing uses of Pledge with MozPromise in MediaManager (cleanup)

Categories

(Core :: WebRTC: Audio/Video, enhancement, P2)

enhancement

Tracking

()

RESOLVED FIXED
mozilla64
Tracking Status
firefox64 --- fixed

People

(Reporter: jib, Assigned: achronop)

References

Details

Attachments

(4 files, 4 obsolete files)

46 bytes, text/x-phabricator-request
jib
: review+
Details | Review
46 bytes, text/x-phabricator-request
jib
: review+
Details | Review
46 bytes, text/x-phabricator-request
jib
: review+
Details | Review
46 bytes, text/x-phabricator-request
jib
: review+
Details | Review
As mentioned in bug 934425 comment 44:
> So... the reason EnumerateDevicesImpl() still returns a Pledge, and hasn't yet been converted to
> MozPromise, is that EnumerateDevicesImpl() does quite a lot of work in the master process and
> waits for an IPC response. Pledge was written to allow clean tear-down of the content process
> even with outstanding IPC responses, and neither resolve nor reject in that case, by design.

It should still be doable to convert this to use MozPromise, if we stash outstanding MozPromise requests and call Disconnect() on them in OnNavigation. 

We should write and land a test first, to make sure we don't accidentally alter this behavior. Filed as bug 1479840.

We might also want to take advantage of MozPromise IPDL support bug 1313200 at the same time.
See Also: → 934425
Comment on attachment 9010197 [details]
Bug 1479841 - Use promise base ipdl api and remove unnecessary IPC response. r?jib

Jan-Ivar Bruaroey [:jib] (needinfo? me) has approved the revision.
Attachment #9010197 - Flags: review+
Attachment #9011022 - Attachment is obsolete: true
Attachment #9011021 - Attachment is obsolete: true
Attachment #9011020 - Attachment is obsolete: true
Attachment #9011019 - Attachment is obsolete: true
Comment on attachment 9010198 [details]
Bug 1479841 - Apply ipdl changes to MediaChild and use the promise to return the key. r?jib

Jan-Ivar Bruaroey [:jib] (needinfo? me) has approved the revision.
Attachment #9010198 - Flags: review+
Comment on attachment 9010199 [details]
Bug 1479841 - Apply ipdl changes to MediaParent and pass back the key through the resolver. r?jib

Jan-Ivar Bruaroey [:jib] (needinfo? me) has approved the revision.
Attachment #9010199 - Flags: review+
Comment on attachment 9010200 [details]
Bug 1479841 - Use promises instead of pledges through out audio device enumeration code path. r?jib

Jan-Ivar Bruaroey [:jib] (needinfo? me) has approved the revision.
Attachment #9010200 - Flags: review+
Attachment #9011022 - Attachment is obsolete: false
Attachment #9011021 - Attachment is obsolete: false
Attachment #9011020 - Attachment is obsolete: false
Attachment #9011019 - Attachment is obsolete: false
Attachment #9011019 - Attachment is obsolete: true
Attachment #9011020 - Attachment is obsolete: true
Attachment #9011021 - Attachment is obsolete: true
Attachment #9011022 - Attachment is obsolete: true
Pushed by achronopoulos@mozilla.com:
https://hg.mozilla.org/integration/autoland/rev/79eec88b1315
Use promise base ipdl api and remove unnecessary IPC response. r=jib
https://hg.mozilla.org/integration/autoland/rev/5ad68af3960a
Apply ipdl changes to MediaChild and use the promise to return the key. r=jib
https://hg.mozilla.org/integration/autoland/rev/eb7d4eac27b5
Apply ipdl changes to MediaParent and pass back the key through the resolver. r=jib
https://hg.mozilla.org/integration/autoland/rev/69b1d1c5e010
Use promises instead of pledges through out audio device enumeration code path. r=jib
Summary: Replace all uses of Pledge with MozPromise in MediaManager (cleanup) → Start replacing uses of Pledge with MozPromise in MediaManager (cleanup)
Regressions: 1767893
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: