RESOLVED FIXED 209666
Remove synchronous termination of service workers
https://bugs.webkit.org/show_bug.cgi?id=209666
Summary Remove synchronous termination of service workers
youenn fablet
Reported 2020-03-27 11:06:22 PDT
Remove synchronous termination of service workers
Attachments
Patch (38.08 KB, patch)
2020-03-30 00:57 PDT, youenn fablet
no flags
Patch (39.19 KB, patch)
2020-03-30 05:47 PDT, youenn fablet
no flags
Patch (40.78 KB, patch)
2020-03-30 09:05 PDT, youenn fablet
no flags
Patch for landing (40.95 KB, patch)
2020-04-02 03:02 PDT, youenn fablet
no flags
youenn fablet
Comment 1 2020-03-30 00:57:42 PDT
youenn fablet
Comment 2 2020-03-30 05:47:47 PDT
youenn fablet
Comment 3 2020-03-30 07:08:42 PDT
Chris Dumez
Comment 4 2020-03-30 08:09:46 PDT
Comment on attachment 394908 [details] Patch View in context: https://bugs.webkit.org/attachment.cgi?id=394908&action=review > Source/WebCore/ChangeLog:8 > + Instead of supporting sycnhronous IPC to terminate a service worker, SWServerWorker will asynchronously ask for the service worker to terminate. Typo: sycnhronous > Source/WebCore/workers/service/WorkerSWClientConnection.cpp:161 > + notImplemented(); What's this? > Source/WebCore/workers/service/server/SWServerWorker.cpp:126 > +void SWServerWorker::terminateCompleted() startTermination -> terminationCompleted would be more consistent.
youenn fablet
Comment 5 2020-03-30 08:11:44 PDT
> > Source/WebCore/workers/service/WorkerSWClientConnection.cpp:161 > > + notImplemented(); > > What's this? We are not calling terminate from a worker but only from a document and for testing purposes. Plan is to add support for it should we need to call this for testing from workers.
Chris Dumez
Comment 6 2020-03-30 08:17:44 PDT
(In reply to youenn fablet from comment #5) > > > Source/WebCore/workers/service/WorkerSWClientConnection.cpp:161 > > > + notImplemented(); > > > > What's this? > > We are not calling terminate from a worker but only from a document and for > testing purposes. > Plan is to add support for it should we need to call this for testing from > workers. It looks like something that used to work and no longer does, aka a regression. How hard would it be to keep it working?
youenn fablet
Comment 7 2020-03-30 08:41:54 PDT
(In reply to Chris Dumez from comment #6) > (In reply to youenn fablet from comment #5) > > > > Source/WebCore/workers/service/WorkerSWClientConnection.cpp:161 > > > > + notImplemented(); > > > > > > What's this? > > > > We are not calling terminate from a worker but only from a document and for > > testing purposes. > > Plan is to add support for it should we need to call this for testing from > > workers. > > It looks like something that used to work and no longer does, aka a > regression. How hard would it be to keep it working? We could and it would be fairly simple (although we would add a Vector<callback>) but I do not think this is worth it. Another option is to move this API to ServiceWorkerProvider so that only Documents would do that. I would tend to go this way in that case.
Chris Dumez
Comment 8 2020-03-30 08:44:44 PDT
Comment on attachment 394908 [details] Patch View in context: https://bugs.webkit.org/attachment.cgi?id=394908&action=review >> Source/WebCore/workers/service/WorkerSWClientConnection.cpp:161 >> + notImplemented(); > > What's this? This looks bad. I think we should either make it work or drop this code (assuming it is not currently useful). Going from something that works to something notImplemented() does not seem like the right thing to do.
youenn fablet
Comment 9 2020-03-30 09:05:48 PDT
youenn fablet
Comment 10 2020-04-01 01:54:15 PDT
Ping review.
Chris Dumez
Comment 11 2020-04-01 12:34:28 PDT
Comment on attachment 394924 [details] Patch r=me
EWS
Comment 12 2020-04-02 00:54:20 PDT
Patch 394924 does not build
youenn fablet
Comment 13 2020-04-02 03:02:18 PDT
Created attachment 395256 [details] Patch for landing
EWS
Comment 14 2020-04-02 04:00:59 PDT
Committed r259383: <https://trac.webkit.org/changeset/259383> All reviewed patches have been landed. Closing bug and clearing flags on attachment 395256 [details].
Note You need to log in before you can comment on or make changes to this bug.