Re: [w3c/ServiceWorker] Improve Activate with Try Activate (#1065)

jungkees commented on this pull request.



> @@ -2742,10 +2752,7 @@ spec: webappsec-referrer-policy; urlPrefix: https://w3c.github.io/webappsec-refe
 
       1. If |registration|'s <a>waiting worker</a> is null, abort these steps.
       1. Let |redundantWorker| be null.
-      1. If |registration|'s <a>active worker</a> is not null, then:
-          1. Set |redundantWorker| to |registration|'s <a>active worker</a>.
-          1. Wait for |redundantWorker| to finish handling any in-progress requests.
-          1. <a lt="Terminate Service Worker">Terminate</a> |redundantWorker|.

I thought it would be not needed when Try Activate successfully called Activate. But you're right. It'd be safer to call Terminate Service Worker before get it redundant. In the follow-up commit, I addressed this point and also moved steps for invoking Update Worker State for the redundant works up, which both Chromium and Gecko do.

-- 
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
https://github.com/w3c/ServiceWorker/pull/1065

Received on Wednesday, 8 February 2017 06:51:08 UTC