Closed Bug 1415630 Opened 7 years ago Closed 7 years ago

PerformanceResourceTiming.fetchStart should mark when FetchEvent is fired on an intercepted channel for now

Categories

(Core :: DOM: Service Workers, enhancement)

enhancement
Not set
normal

Tracking

()

RESOLVED FIXED
mozilla58
Tracking Status
firefox58 --- fixed

People

(Reporter: bkelly, Assigned: bkelly)

References

(Blocks 2 open bugs)

Details

Attachments

(1 file)

When I implemented PerformanceResourceTiming.workerStart I made fetchStart be equal to its value for lack of a better definition. Talking with Matt Falkenhagen from google we believe it makes sense to probably make fetchStart mark when the FetchEvent is fired on the worker thread. This is not clearly defined in the spec unfortunately, but it would be worth aligning here for now. We really need the performance WG spec to align with fetch spec to unambiguously define these values.
Blocks: 1191943
Comment on attachment 8926660 [details] [diff] [review] Make PerformanceResourceTiming.fetchStart match the time we dispatch the FetchEvent when SW interception occurs. r=baku Review of attachment 8926660 [details] [diff] [review]: ----------------------------------------------------------------- This patch shifts the value we use for fetchStart when a service worker is involved. Instead of making fetchStart == workerStart, we make fetchStart == requestStart which we are treating as the time FetchEvent is dispatched. I tested this manually. I can't write a WPT that checks this since we have no way to force the service worker to stop in order to observe the time for worker starting up.
Attachment #8926660 - Flags: review?(amarchesini)
Attachment #8926660 - Flags: review?(amarchesini) → review+
Pushed by bkelly@mozilla.com: https://hg.mozilla.org/integration/mozilla-inbound/rev/b5969c9b92fb Make PerformanceResourceTiming.fetchStart match the time we dispatch the FetchEvent when SW interception occurs. r=baku
Status: ASSIGNED → RESOLVED
Closed: 7 years ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla58
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: