Re: [w3c/ServiceWorker] A way to immediately unregister a service worker (#614)

I spoke with @slightlyoff offline.

One of the [explicit goals](https://www.w3.org/TR/clear-site-data/#goals) of `Clear-Site-Data` is to ensure:

> Service Workers registered for an origin are terminated and deregistered.

However, from what I can tell, all [the spec calls for](https://www.w3.org/TR/clear-site-data/#clear-dom), with respect to service workers, is calling `unregister` on the service worker, which I don't think will actually terminate the service worker. This unregistering is caused by the `storage` directive.

`Clear-Site-Data` also supports an [`executionContext` directive](https://www.w3.org/TR/clear-site-data/#clear-response), which will [reload all contexts with a `document`](https://www.w3.org/TR/clear-site-data/#abstract-opdef-reload-browsing-contexts). I don't think this helps us either, since reloading does not count as actually unloading the client.

So I'm still unclear on how `Clear-Site-Data` achieves the "terminate" part of the service worker goal.

-- 
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/issues/614#issuecomment-432621606

Received on Wednesday, 24 October 2018 11:40:33 UTC