commit | 2c47ce6a617cc70b5bf50245e4b0de5638e9e849 | [log] [tgz] |
---|---|---|
author | Matt Falkenhagen <falken@chromium.org> | Mon Jul 23 10:21:07 2018 |
committer | Commit Bot <commit-bot@chromium.org> | Mon Jul 23 10:21:07 2018 |
tree | 3d98ec5743ccbb5d3358fc00972bfb4acf71eef3 | |
parent | c512937e6b6f6ec01384fbb210401aac0c7f1467 [diff] |
service worker: Clarify SetAllowAssociation(). This is one of the tricky parts of service worker code, and its role has changed after various changes over the years. There is no longer such thing as a "new registration" associating with a provider host. Association happens only during: 1) main resource requests in ServiceWorkerControlleeRequestHandler 2) claim() in ServiceWorkerRegistration. There is no need for ServiceWorkerControlleeRequestHandler to defend against itself. So claim() is the only thing to defend against. So the whole point of it is to stop claim() from claiming provider hosts that are still undergoing their main resource request. This should be the same thing as |is_execution_ready_|. But unfortunately there is still edge cases/trickiness around shared workers and about:blank iframes. Add some comments and revisit after NetS13nServiceWorker. Change-Id: I508f13c52fc30aa40776e17d4966ff05c0c57e14 Bug: 866353 Reviewed-on: https://chromium-review.googlesource.com/1146414 Commit-Queue: Matt Falkenhagen <falken@chromium.org> Reviewed-by: Kenichi Ishibashi <bashi@chromium.org> Reviewed-by: Makoto Shimazu <shimazu@chromium.org> Cr-Commit-Position: refs/heads/master@{#577134}
Chromium is an open-source browser project that aims to build a safer, faster, and more stable way for all users to experience the web.
The project's web site is https://www.chromium.org.
Documentation in the source is rooted in docs/README.md.
Learn how to Get Around the Chromium Source Code Directory Structure .