-
Notifications
You must be signed in to change notification settings - Fork 6
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Consider timingInfo handling in static routing API #19
Comments
In current Chromium implementation, if "cache" source is used, the timing is set like: However, we should revisit what information is set there and given as the timing Info. There might be three options: My recommendation is Option B. |
It looks like this impacts the two properties Option B involves adding new properties, right? Do you have a proposal for those? But even if you do option B, we still need to decide what values the existing properties get. Have you thought about what is preferred there? Answering this seems more important, as you can always add new properties later, after gathering more input from partners and the standards community. To me, setting them both to 0 seems reasonable. (Or whatever default value falls out of the processing, if it is not 0.) |
Yes, I have drafted the proposal for Option B. I suggested to add 4 fields there. Since timing is got inside the Handle Fetch algorithm, I suggested to refer the Service Worker timing in the Resource timing. Existing properties are left as-is. Values may set upon the source. For the cache source, since we do not call the Run Service Worker algorithm, workerStart is left 0. The new cache lookup related field will be filled. As you know, I am working on drafting the Service Worker static routing specification (PR that gathers all changes, working branch). The proposal will be adjusted upon its progress. |
Agree. If the router source is |
Even if the ServiceWorker static routing API is used and source that does not run the fetch handler is used, we set the timing info. To avoid unnecessary confusion, let me avoid setting them until the following discussion reaches some agreement: WICG/service-worker-static-routing-api#19 Change-Id: I87bc4bb22b3b72ca62ea9a6c27d29f34e6540dbe Bug: 1523917 Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/5256859 Reviewed-by: Shunya Shishido <[email protected]> Commit-Queue: Yoshisato Yanagisawa <[email protected]> Cr-Commit-Position: refs/heads/main@{#1255459}
There is a github issue to discuss about this in the resource-timing repo. |
I suggest to continue the discussion in w3c/resource-timing#389 instead. |
In https://www.w3.org/TR/service-workers/#handle-fetch, timingInfo is set with start time, fetch event dispatch time appropriately. As the static routing API change the flow of the handle fetch algorithm, we have to define when/what value should be set to timingInfo.
Spec update to the ServiceWorker and WPTs are needed.
The text was updated successfully, but these errors were encountered: