Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(278)

Issue 2100433003: [CacheStorage] Temporarily preserve recently opened caches from CacheStorageDispatcherHost (Closed)

Created:
4 years, 6 months ago by jkarlin
Modified:
4 years, 5 months ago
Reviewers:
nhiroki
CC:
chromium-reviews, darin-cc_chromium.org, jam, jkarlin+watch_chromium.org
Base URL:
https://chromium.googlesource.com/chromium/src.git@master
Target Ref:
refs/pending/heads/master
Project:
chromium
Visibility:
Public.

Description

[CacheStorage] Temporarily preserved recently opened caches from CacheStorageDispatcherHost Currently when a cache is opened it is preserved for 30 seconds by content::CacheStorage so that, in case the cache is accessed again soon it doesn't have to be reopened. This happened in https://codereview.chromium.org/1470073003/. We don't want to preserve every opened cache. Particularly, we don't want to preserve caches opened by the QuotaManager when it's determining the size of all of the caches. We only want to preserve caches opened on behalf of documents. This CL moves the preservation logic to the CacheStorageDispatcherHost, where open calls from the document are made. That way open calls from other clients don't trigger preservation. The CL also lowers the time that the cache is held open to 5 seconds from 30 as that should be more than enough time between cache actions on most pages. BUG=623159 Committed: https://crrev.com/848127113da87ca062b139a6ab1de1b16a6df1d4 Cr-Commit-Position: refs/heads/master@{#402798}

Patch Set 1 #

Patch Set 2 : Fixes #

Patch Set 3 : Fix #

Total comments: 2

Patch Set 4 : Remove weak ptr #

Total comments: 2

Patch Set 5 : Simplified #

Unified diffs Side-by-side diffs Delta from patch set Stats (+38 lines, -197 lines) Patch
M content/browser/cache_storage/cache_storage.h View 3 chunks +0 lines, -14 lines 0 comments Download
M content/browser/cache_storage/cache_storage.cc View 3 chunks +0 lines, -33 lines 0 comments Download
M content/browser/cache_storage/cache_storage_dispatcher_host.cc View 1 2 3 4 4 chunks +15 lines, -2 lines 0 comments Download
M content/browser/cache_storage/cache_storage_manager_unittest.cc View 1 2 chunks +23 lines, -1 line 0 comments Download
D content/browser/cache_storage/cache_storage_unittest.cc View 1 chunk +0 lines, -146 lines 0 comments Download
M content/content_tests.gypi View 1 chunk +0 lines, -1 line 0 comments Download

Messages

Total messages: 17 (7 generated)
jkarlin
nhiroki@ PTAL at everything, thank you!
4 years, 6 months ago (2016-06-24 20:13:52 UTC) #2
nhiroki
Looks good overall. https://codereview.chromium.org/2100433003/diff/40001/content/browser/cache_storage/cache_storage_dispatcher_host.h File content/browser/cache_storage/cache_storage_dispatcher_host.h (right): https://codereview.chromium.org/2100433003/diff/40001/content/browser/cache_storage/cache_storage_dispatcher_host.h#newcode183 content/browser/cache_storage/cache_storage_dispatcher_host.h:183: base::WeakPtrFactory<CacheStorageDispatcherHost> weak_ptr_factory_; Is this usage of ...
4 years, 5 months ago (2016-06-28 06:22:34 UTC) #5
jkarlin
Thanks! PTAL. https://codereview.chromium.org/2100433003/diff/40001/content/browser/cache_storage/cache_storage_dispatcher_host.h File content/browser/cache_storage/cache_storage_dispatcher_host.h (right): https://codereview.chromium.org/2100433003/diff/40001/content/browser/cache_storage/cache_storage_dispatcher_host.h#newcode183 content/browser/cache_storage/cache_storage_dispatcher_host.h:183: base::WeakPtrFactory<CacheStorageDispatcherHost> weak_ptr_factory_; On 2016/06/28 06:22:34, nhiroki (slow) ...
4 years, 5 months ago (2016-06-28 11:20:14 UTC) #6
nhiroki
https://codereview.chromium.org/2100433003/diff/60001/content/browser/cache_storage/cache_storage_dispatcher_host.cc File content/browser/cache_storage/cache_storage_dispatcher_host.cc (right): https://codereview.chromium.org/2100433003/diff/60001/content/browser/cache_storage/cache_storage_dispatcher_host.cc#newcode368 content/browser/cache_storage/cache_storage_dispatcher_host.cc:368: this, cache_handle->value()), This may extend the lifetime of MessageFilter. ...
4 years, 5 months ago (2016-06-29 09:15:39 UTC) #7
jkarlin
Thanks, PTAL. https://codereview.chromium.org/2100433003/diff/60001/content/browser/cache_storage/cache_storage_dispatcher_host.cc File content/browser/cache_storage/cache_storage_dispatcher_host.cc (right): https://codereview.chromium.org/2100433003/diff/60001/content/browser/cache_storage/cache_storage_dispatcher_host.cc#newcode368 content/browser/cache_storage/cache_storage_dispatcher_host.cc:368: this, cache_handle->value()), On 2016/06/29 09:15:39, nhiroki (slow) ...
4 years, 5 months ago (2016-06-29 12:52:53 UTC) #9
nhiroki
On 2016/06/29 12:52:53, jkarlin wrote: > Thanks, PTAL. > > https://codereview.chromium.org/2100433003/diff/60001/content/browser/cache_storage/cache_storage_dispatcher_host.cc > File content/browser/cache_storage/cache_storage_dispatcher_host.cc (right): ...
4 years, 5 months ago (2016-06-29 14:05:12 UTC) #10
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/v2/patch-status/codereview.chromium.org/2100433003/100001
4 years, 5 months ago (2016-06-29 14:14:00 UTC) #12
commit-bot: I haz the power
Committed patchset #5 (id:100001)
4 years, 5 months ago (2016-06-29 14:17:39 UTC) #14
commit-bot: I haz the power
CQ bit was unchecked.
4 years, 5 months ago (2016-06-29 14:17:48 UTC) #15
commit-bot: I haz the power
4 years, 5 months ago (2016-06-29 14:19:14 UTC) #17
Message was sent while issue was closed.
Patchset 5 (id:??) landed as
https://crrev.com/848127113da87ca062b139a6ab1de1b16a6df1d4
Cr-Commit-Position: refs/heads/master@{#402798}

Powered by Google App Engine
This is Rietveld 408576698