Bug 205330

Summary: [GTK][WPE] IndexedDB directory set in WebsiteDataManager is ignored
Product: WebKit Reporter: Carlos Garcia Campos <cgarcia>
Component: WebKitGTKAssignee: Nobody <webkit-unassigned>
Status: RESOLVED FIXED    
Severity: Normal CC: achristensen, berto, bugs-noreply, cdumez, ews-watchlist, gustavo, youennf
Priority: P2 Keywords: Gtk, Regression
Version: WebKit Nightly Build   
Hardware: Unspecified   
OS: Unspecified   
Attachments:
Description Flags
Patch youennf: review+

Description Carlos Garcia Campos 2019-12-17 01:50:24 PST
There are two problems here:

 1- WebKitWebsiteDataManager is no longer setting the indexedDB directory to the WEbsiteDatastore configuration. It seems the code was removed by mistake in r249778 when rolling out r249768.
 2- The WebProcessPool is not considering the primary WebsiteDataStore for indexedDB configuration.

This was caught by test /webkit/WebKitWebsiteData/configuration
Comment 1 Carlos Garcia Campos 2019-12-17 01:54:52 PST
Created attachment 385866 [details]
Patch
Comment 2 EWS Watchlist 2019-12-17 01:55:45 PST
Thanks for the patch. If this patch contains new public API please make sure it follows the guidelines for new WebKit2 GTK+ API. See http://trac.webkit.org/wiki/WebKitGTK/AddingNewWebKit2API
Comment 3 Carlos Garcia Campos 2019-12-17 06:12:51 PST
Could a WebKit2 owner check the cross-platform change, please? Youenn?
Comment 4 youenn fablet 2019-12-17 06:21:09 PST
Comment on attachment 385866 [details]
Patch

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

> Source/WebKit/UIProcess/WebProcessPool.cpp:540
>          parameters.defaultDataStoreParameters.indexedDatabaseDirectory = WebKit::WebsiteDataStore::defaultDataStore()->parameters().indexedDatabaseDirectory;

LGTM.
There is some pre-existing inconsistencies in this method with withWebsiteDataStore .
Some other parameters like parameters.defaultDataStoreParameters.networkSessionParameters.networkCacheDirectory also check for withWebsiteDataStore.
Comment 5 Carlos Garcia Campos 2019-12-17 06:27:20 PST
(In reply to youenn fablet from comment #4)
> Comment on attachment 385866 [details]
> Patch
> 
> View in context:
> https://bugs.webkit.org/attachment.cgi?id=385866&action=review
> 
> > Source/WebKit/UIProcess/WebProcessPool.cpp:540
> >          parameters.defaultDataStoreParameters.indexedDatabaseDirectory = WebKit::WebsiteDataStore::defaultDataStore()->parameters().indexedDatabaseDirectory;
> 
> LGTM.

Thanks!

> There is some pre-existing inconsistencies in this method with
> withWebsiteDataStore .
> Some other parameters like
> parameters.defaultDataStoreParameters.networkSessionParameters.
> networkCacheDirectory also check for withWebsiteDataStore.

Yes, I noticed it too, but I wasn't sure what the expected behavior was in the end.
Comment 6 Carlos Garcia Campos 2019-12-17 06:28:32 PST
Committed r253626: <https://trac.webkit.org/changeset/253626>