RESOLVED DUPLICATE of bug 179401 179395
[Service Worker] Termination policy
https://bugs.webkit.org/show_bug.cgi?id=179395
Summary [Service Worker] Termination policy
Joseph Pecoraro
Reported 2017-11-07 14:36:57 PST
[Service Worker] Termination policy Service workers don't always get terminated as one would expect. Steps to Reproduce: 1. Load <https://mdn.github.io/sw-test/> 2. Navigate to <https://webkit.org> => Service Workers <https://mdn.github.io/sw-test/sw.js> is still alive Relatedly, currently just reloading a page with a service worker causes a new service worker to spawn: Steps to Reproduce: 1. Load <https://mdn.github.io/sw-test/> 2. Reload 3 times => Multiple Service Workers exist for <https://mdn.github.io/sw-test/sw.js> Both cases can result in a large list of Service Workers show up as inspector debug targets, and when there are duplicates it is unclear which is the active worker.
Attachments
Radar WebKit Bug Importer
Comment 1 2017-11-07 14:37:15 PST
Joseph Pecoraro
Comment 2 2017-11-07 14:38:33 PST
When a Service Worker has a debugger/inspector attached we should consider not terminating it until the debugger/inspector has disconnected.
Brady Eidson
Comment 3 2017-11-07 16:56:47 PST
Yup, we never terminate. It's an algorithm we need to implement and then use, obviously. I'll be stubbing out in: https://bugs.webkit.org/show_bug.cgi?id=179401
Geoffrey Garen
Comment 4 2017-12-19 15:00:14 PST
*** This bug has been marked as a duplicate of bug 179401 ***
Note You need to log in before you can comment on or make changes to this bug.