- From: Yoshisato Yanagisawa <notifications@github.com>
- Date: Mon, 26 Jan 2026 22:50:02 -0800
- To: w3c/ServiceWorker <ServiceWorker@noreply.github.com>
- Cc: Subscribed <subscribed@noreply.github.com>
- Message-ID: <w3c/ServiceWorker/pull/1764/review/3709401924@github.com>
@yoshisatoyanagisawa commented on this pull request.
> @@ -3297,7 +3299,55 @@ spec: storage; urlPrefix: https://storage.spec.whatwg.org/
1. Set |routedResponse|'s [=service worker timing info=] be set to |timingInfo|.
1. Set |routedResponse|'s [=service worker timing info=]'s [=service worker timing info/worker final router source=] be set to |result|'s [=race result/used route=].
1. Return |routedResponse|.
- 1. Assert: |source| is "{{RouterSourceEnum/fetch-event}}"
+ 1. Else if |source| is {{RouterSourceEnum/"race-network-and-cache"}}, and |request|'s [=request/method=] is \`<code>GET</code>\` then:
+ 1. If |shouldSoftUpdate| is true, then [=in parallel=] run the [=Soft Update=] algorithm with |registration|.
+ 1. Let |queue| be an empty [=queue=] of [=race result=].
+ 1. Let |raceFetchController| be null.
+ 1. Run the following substeps [=in parallel=]:
+ 1. If |fetchController|'s [=fetch controller/state=] is "<code>terminated</code>" or "<code>aborted</code>", then abort these steps.
+ 1. Set |raceFetchController| to the result of calling [=fetch=] given |request|, with [=fetch/processResponse=] set to the following steps given a [=/response=] |raceNetworkRequestResponse|:
+ 1. Run these steps, but [=abort when=] |fetchController|'s [=fetch controller/state=] is "<code>terminated</code>" or "<code>aborted</code>".
+ 1. Let |raceNetworkResult| be a [=race result=] whose [=race result/routed response=] is |raceNetworkRequestResponse| and [=race result/used route=] is {{RouterSourceEnum/"network"}}.
+ 1. [=queue/Enqueue=] |raceNetworkResult| to |queue|.
+ 1. [=If aborted=] and |raceFetchController| is not null, then [=fetch controller/Abort=] |raceFetchController|.
+ 1. Resolve |preloadResponse| with undefined.
+ 1. Run the following substeps [=in parallel=]:
+ 1. Set |timingInfo|’s [=service worker timing info/worker cache lookup start=] to the [=coarsened shared current time=] given |useHighResPerformanceTimers|.
Since the algorithm run in parallel duplicate with the cache source, having unified algorithm for it can be good.
It is totally fine to be addressed in the follow up PR, though.
--
Reply to this email directly or view it on GitHub:
https://github.com/w3c/ServiceWorker/pull/1764#pullrequestreview-3709401924
You are receiving this because you are subscribed to this thread.
Message ID: <w3c/ServiceWorker/pull/1764/review/3709401924@github.com>
Received on Tuesday, 27 January 2026 06:50:05 UTC