Closed Bug 2080222 Opened 1 month ago Closed 1 month ago

[wpt-sync] Sync PR 63424 - BackgroundFetch: stop using Blobs during request lookup

Categories

(Core :: DOM: Service Workers, task, P4)

task

Tracking

()

RESOLVED FIXED
160 Branch
Tracking Status
firefox160 --- fixed

People

(Reporter: wpt-sync, Unassigned)

References

()

Details

(Whiteboard: [wptsync downstream])

Sync web-platform-tests PR 63424 into mozilla-central (this bug is closed when the sync is complete).

PR: https://github.com/web-platform-tests/wpt/pull/63424
Details from upstream follow.

Evan Stade <evanstade@microsoft.com> wrote:

BackgroundFetch: stop using Blobs during request lookup

When retrieving a request body from cache storage, don't wrap it in a
Blob. The Blob is immediately redirected into a DataPipeGetter anyway
when used by the browser for the upload/download. Registration of a
BlobDataItem/BlobDataItemReader with the BlobContext is unnecessary
complexity which uses extra mojo pipes and async steps. If the request
is retrieved by the renderer with Match, the Blob wrapper is again
unnecessary most of the time.

This change doesn't affect the lifetime of data: as with the
BlobDataItem before it, the DataPipeGetter will stop working if the
cache storage entry needs to be deleted.

"GetRequestBlob" symbol names are changed to "GetRequestBody" in many
places.

Also add WPT coverage for BgF uploads. (It seems like ReadableStream
body should be supported, but currently is not, so that's left out of
the test.)

Bypass-Check-License: file rename
Bug: 567175133
Change-Id: Iba326621c2f6930d5d275bb1a95330fb70d69873
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/8444651
Reviewed-by: Tommy Nyquist \<nyquist@chromium.org>
Commit-Queue: Evan Stade \<evanstade@microsoft.com>
Reviewed-by: Rick Byers \<rbyers@chromium.org>
Reviewed-by: Rakina Zata Amni \<rakina@chromium.org>
Reviewed-by: Fergal Daly \<fergal@chromium.org>
Cr-Commit-Position: refs/heads/main@{#1714621}

Component: web-platform-tests → DOM: Service Workers
Product: Testing → Core

CI Results

Ran 9 Firefox configurations based on mozilla-central, and Firefox, Chrome, and Safari on GitHub CI

Total 15 tests

Status Summary

Firefox

OK : 1
FAIL : 8

Chrome

PASS : 1
TIMEOUT: 2
NOTRUN : 6

Safari

OK : 1
FAIL : 8

Links

Gecko CI (Treeherder)
GitHub PR Head
GitHub PR Base

Details

New Tests That Don't Pass

Tests Disabled in Gecko Infrastructure

Pushed by wptsync@mozilla.com: https://github.com/mozilla-firefox/firefox/commit/2ae87f0df44b https://hg.mozilla.org/integration/autoland/rev/b64e65b7e0ea [wpt PR 63424] - BackgroundFetch: stop using Blobs during request lookup, a=testonly
Status: NEW → RESOLVED
Closed: 1 month ago
Resolution: --- → FIXED
Target Milestone: --- → 160 Branch
You need to log in before you can comment on or make changes to this bug.