[shared storage] Support cross-origin worklet #44596
Merged
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
For the sharedStorage.createWorklet() API, relax the same-origin
restriction to additionally allow cross-origin script, in which case
a cross-origin worklet will be created.
How:
behavior (i.e. it should end up using a process as if an iframe is
created with the script URL). It leverages the process allocation
and management logic from service workers and re-use SiteInstanceImpl::CreateForServiceWorker(). To keep this
CL focused, the refactoring will occur in a separate CL, as it
will involve refactoring other downstream components like
'UnmatchedServiceWorkerProcessTracker'.
Explainer: WICG/shared-storage#130
Spec: WICG/shared-storage#131
Design doc:
https://docs.google.com/document/d/1QTaaroCMeFVZVghI6JkUcDvmDQEacjvpyTfk6mpvQhA/edit?usp=sharing
Bug: 325302836
Change-Id: I11c1fc87bc76f4400c54d9fa809349d1d1781247
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/5296843
Reviewed-by: Alex Moshchuk <[email protected]>
Commit-Queue: Yao Xiao <[email protected]>
Cr-Commit-Position: refs/heads/main@{#1265583}