Bug 89450
Summary: | webkit2 appcache should be implemented in UIProcess | ||
---|---|---|---|
Product: | WebKit | Reporter: | Jussi Kukkonen (jku) <jussi.kukkonen> |
Component: | WebKit2 | Assignee: | Nobody <webkit-unassigned> |
Status: | RESOLVED INVALID | ||
Severity: | Normal | CC: | ap |
Priority: | P2 | ||
Version: | 528+ (Nightly build) | ||
Hardware: | Unspecified | ||
OS: | Unspecified |
Jussi Kukkonen (jku)
the appcache implementation in webkit2 should live in the UI process. Quoting
Now the callpath for e.g. deleteAllEntries is:
* app calls deleteAllEntries in WebProcess
* Call goes through IPC to UIProcess
* UIProcess calls deleteAllEntries in all WebProcesses (relaunching if necessary)
This is already wasteful and when the method has actual payload, the complexity grows even further.
I'll see if I can manage to implement this change...
Attachments | ||
---|---|---|
Add attachment proposed patch, testcase, etc. |
Jussi Kukkonen (jku)
> the appcache implementation in webkit2 should live in the UI process. Quoting
This was supposed to say:
the appcache implementation in webkit2 should live in the UI process. Quoting WebApplicationCacheManagerProxy.ccp:
// FIXME (Multi-WebProcess): The application cache shouldn't be stored in the web process.
Jussi Kukkonen (jku)
Right after filing I realised why this is implemented as it is: the actual appcache implementation is inside WebCore... I still think the bug is valid, but fixing it might not be trivial.
Jussi Kukkonen (jku)
(In reply to comment #0)
> Now the callpath for e.g. deleteAllEntries is:
> * app calls deleteAllEntries in WebProcess
> * Call goes through IPC to UIProcess
> * UIProcess calls deleteAllEntries in all WebProcesses (relaunching if necessary)
This is not actually true: when something inside a webprocess wants to do this, it just calls deleteEntries in that particular WebProcess... The path with WebContext->sendToAllProcessesRelaunchingThemIfNecessary() is only called when the UIProcess wants to do this. So not crazy like I thought :)
Maybe it makes sense to just create a WebApplicationCacheManager instance in the UIProcess as well? Apparently the SQLite DB doesn't mind (as it's already coping with a WebApplicationCacheManager per webprocess)
Alexey Proskuryakov
UIProcess should have as little code as possible, because it is not sandboxed. Moving application cache to that process is certainly not appropriate.