Closed
Bug 1264182
Opened 9 years ago
Closed 7 years ago
remove URL.createObjectURL from ServiceWorker
Categories
(Core :: DOM: Service Workers, defect, P2)
Core
DOM: Service Workers
Tracking
()
RESOLVED
FIXED
mozilla63
Tracking | Status | |
---|---|---|
firefox63 | --- | fixed |
People
(Reporter: bkelly, Assigned: ytausky)
References
(Blocks 1 open bug)
Details
(Keywords: dev-doc-complete, site-compat, Whiteboard: btpp-fixlater[wptsync upstream])
Attachments
(1 file)
We decided to remove createObjectURL from ServiceWorker context since blob URLs have lifecycle problems on service workers and Response objects have better semantics.
https://github.com/slightlyoff/ServiceWorker/issues/688
Updated•9 years ago
|
Whiteboard: btpp-fixlater
Updated•8 years ago
|
Keywords: dev-doc-needed
Updated•8 years ago
|
Keywords: site-compat
Updated•7 years ago
|
Priority: -- → P2
Updated•7 years ago
|
Assignee: nobody → ytausky
Status: NEW → ASSIGNED
Assignee | ||
Comment 1•7 years ago
|
||
The appropriate lifetime for URLs created with URL.createObjectURL turned
out to be tricky to define, so it was decided to hide it from service
workers altogether. (https://github.com/slightlyoff/ServiceWorker/issues/688)
This commit implements this change and adds a web platform test to verify it.
It also exposes the MediaSource variant of URL.createObjectURL in DedicatedWorker
and SharedWorker contexts in order to comply with the WebIDL spec (see
https://github.com/w3c/media-source/issues/168#issuecomment-410269436).
Comment 2•7 years ago
|
||
Comment on attachment 8997470 [details]
Bug 1264182: Hide URL.createObjectURL from ServiceWorker
Blake Kaplan (:mrbkap) has approved the revision.
https://phabricator.services.mozilla.com/D2728
Attachment #8997470 -
Flags: review+
Comment 3•7 years ago
|
||
Comment on attachment 8997470 [details]
Bug 1264182: Hide URL.createObjectURL from ServiceWorker
Andrew Sutherland [:asuth] has approved the revision.
https://phabricator.services.mozilla.com/D2728
Attachment #8997470 -
Flags: review+
Pushed by bugmail@asutherland.org:
https://hg.mozilla.org/integration/autoland/rev/40d4999db319
Hide URL.createObjectURL from ServiceWorker r=mrbkap,asuth
Created web-platform-tests PR https://github.com/web-platform-tests/wpt/pull/12339 for changes under testing/web-platform/tests
Whiteboard: btpp-fixlater → btpp-fixlater[wptsync upstream]
Upstream web-platform-tests status checks passed, PR will merge once commit reaches central.
Comment 7•7 years ago
|
||
bugherder |
Status: ASSIGNED → RESOLVED
Closed: 7 years ago
status-firefox63:
--- → fixed
Resolution: --- → FIXED
Target Milestone: --- → mozilla63
Upstream PR merged
Comment 9•7 years ago
|
||
Posted the site compatibility note: https://www.fxsitecompat.com/en-CA/docs/2018/url-createobjecturl-is-no-longer-available-in-service-workers/
Comment 10•6 years ago
|
||
Doc updates:
The createObjectURL() page already had this information; updated revokeObjectURL() and added a note to Firefox 63 for developers.
I've also submitted PR #2707 on BCD to note these changes in the compatibility database.
Keywords: dev-doc-needed → dev-doc-complete
Updated•6 years ago
|
status-firefox48:
affected → ---
Comment 11•6 years ago
|
||
Aha, I’ve just found URL.createObjectURL in my own service worker. Fortunately this particular app is no longer maintained, but I’m wondering if this change may break similar code. Will monitor reports.
https://github.com/bzdeck/bzdeck/blob/master/webroot/static/scripts/workers/service-worker.js
You need to log in
before you can comment on or make changes to this bug.
Description
•