Bug 120514 - [WebKit2]SetCacheModel must be callled when ResourceCachesToClear is AllResourceCaches
Summary: [WebKit2]SetCacheModel must be callled when ResourceCachesToClear is AllResou...
Status: UNCONFIRMED
Alias: None
Product: WebKit
Classification: Unclassified
Component: WebKit2 (show other bugs)
Version: 528+ (Nightly build)
Hardware: Unspecified Unspecified
: P2 Normal
Assignee: Nobody
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2013-08-30 01:08 PDT by Sangho Kim
Modified: 2016-05-24 22:02 PDT (History)
5 users (show)

See Also:


Attachments
patch (1.60 KB, patch)
2013-08-30 01:18 PDT, Sangho Kim
beidson: review-
Details | Formatted Diff | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Sangho Kim 2013-08-30 01:08:29 PDT
WebProcess has clearResourceCaches function.
It deletes Disk cache by using setCacheModel(DocumentViewer)
But I think if ResourceCachesToClear is onlyInMemory, Disk cache should not be deleted.
Comment 1 Sangho Kim 2013-08-30 01:18:38 PDT
Created attachment 210075 [details]
patch

When the argument of clearResourceCaches is only AllResourceCaches, SetCacheModel can be called.
Comment 2 Alexey Proskuryakov 2013-09-03 12:14:32 PDT
This doesn't look right to me - we still need to call setCacheModel to clear memory cache here.
Comment 3 Sangho Kim 2013-09-03 16:55:06 PDT
(In reply to comment #2)
> This doesn't look right to me - we still need to call setCacheModel to clear memory cache here.

If the setCacheModel(CacheModelDocumentViewer) is called, Disk Cache is deleted.
I think Disk Cache should not be deleted when user want to delete only caches in memory.
Comment 4 Alexey Proskuryakov 2013-09-04 09:45:19 PDT
This is not necessarily accurate - for example, Mac implementation doesn't shrink disk cache.
Comment 5 Brady Eidson 2016-05-24 22:02:37 PDT
Comment on attachment 210075 [details]
patch

Assuming that patches for review since 2013 are stale, r-