Bug 231045

Summary: Add SPI to launch a service service worker in a WKWebView and expose service worker to injected bundle
Product: WebKit Reporter: Chris Dumez <cdumez>
Component: WebKit2Assignee: Chris Dumez <cdumez>
Status: RESOLVED FIXED    
Severity: Normal CC: achristensen, beidson, benjamin, berto, cgarcia, cmarcelo, esprehn+autocc, ews-watchlist, ggaren, gustavo, japhet, kangil.han, kkinnunen, timothy, webkit-bug-importer, youennf
Priority: P2 Keywords: InRadar
Version: WebKit Nightly Build   
Hardware: Unspecified   
OS: Unspecified   
Bug Depends on: 230649    
Bug Blocks:    
Attachments:
Description Flags
WIP Patch
ews-feeder: commit-queue-
WIP Patch
ews-feeder: commit-queue-
WIP Patch
none
Patch
none
Patch
none
Patch none

Description Chris Dumez 2021-09-30 16:28:04 PDT
Add SPI to launch a service service worker in a WKWebView and expose service worker to injected bundle.
Comment 1 Chris Dumez 2021-09-30 16:28:34 PDT
Created attachment 439791 [details]
WIP Patch
Comment 2 EWS Watchlist 2021-09-30 16:29:51 PDT
Thanks for the patch. If this patch contains new public API please make sure it follows the guidelines for new WebKit2 GTK+ API. See https://trac.webkit.org/wiki/WebKitGTK/AddingNewWebKit2API
Comment 3 Radar WebKit Bug Importer 2021-09-30 16:44:34 PDT
<rdar://problem/83744069>
Comment 4 Chris Dumez 2021-09-30 16:46:16 PDT
Created attachment 439796 [details]
WIP Patch
Comment 5 Chris Dumez 2021-10-01 07:40:57 PDT
Created attachment 439858 [details]
WIP Patch
Comment 6 Chris Dumez 2021-10-01 08:08:22 PDT
Created attachment 439862 [details]
Patch
Comment 7 Timothy Hatcher 2021-10-01 11:35:57 PDT
Comment on attachment 439862 [details]
Patch

View in context: https://bugs.webkit.org/attachment.cgi?id=439862&action=review

> Source/WebCore/page/Page.cpp:3694
> +    // FIXME: We currently do not support non-normal worlds in service workers.

This will be fine for our needs.

> Source/WebKit/WebProcess/InjectedBundle/API/c/WKBundlePageLoaderClient.h:658
> +    WKBundlePageServiceWorkerGlobalObjectIsAvailableForFrameCallback         serviceWorkerGlobalObjectIsAvailableForFrame;

One space off in the alignment of serviceWorkerGlobalObjectIsAvailableForFrame.
Comment 8 Chris Dumez 2021-10-01 13:48:58 PDT
Created attachment 439904 [details]
Patch
Comment 9 Geoffrey Garen 2021-10-04 12:40:26 PDT
Comment on attachment 439904 [details]
Patch

r=me
Comment 10 EWS 2021-10-04 12:42:48 PDT
Tools/Scripts/svn-apply failed to apply attachment 439904 [details] to trunk.
Please resolve the conflicts and upload a new patch.
Comment 11 Chris Dumez 2021-10-04 13:33:37 PDT
Created attachment 440099 [details]
Patch
Comment 12 EWS 2021-10-04 16:15:34 PDT
Committed r283522 (242489@main): <https://commits.webkit.org/242489@main>

All reviewed patches have been landed. Closing bug and clearing flags on attachment 440099 [details].