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

Issue 1140853002: ServiceWorker: Use SimpleCache for the script cache (Closed)

Created:
5 years, 7 months ago by nhiroki
Modified:
5 years, 7 months ago
Reviewers:
kinuko, michaeln
CC:
chromium-reviews, jsbell+serviceworker_chromium.org, tzik, serviceworker-reviews, jam, darin-cc_chromium.org, jkarlin+watch_chromium.org, horo+watch_chromium.org, kinuko+serviceworker, kinuko+watch, gavinp
Base URL:
https://chromium.googlesource.com/chromium/src.git@master
Target Ref:
refs/pending/heads/master
Project:
chromium
Visibility:
Public.

Description

ServiceWorker: Use SimpleCache for the script cache This CL migrates the backend of ServiceWorkerDiskCache from Default to SimpleCache on all platforms. If old DiskCache images exist, (1) DiskCache backend fails to open an pre-existing data due to incompatible format (in both Default->SimpleCache and SimpleCache->Default cases), (2) ServiceWorkerStorage wipes out all cached scripts and registrations via DeleteAndStartOver, and (3) navigation falls back to network. BUG=487482 TEST=manual (use DiskCache and SimpleCache alternately and make sure the system can recover) Committed: https://crrev.com/a00e5be5a06e626de1b62cbfc7c350bef08647ea Cr-Commit-Position: refs/heads/master@{#330274}

Patch Set 1 #

Patch Set 2 : Avoid using BackendType enum (see https://codereview.chromium.org/332833004/#msg2) #

Patch Set 3 : fix build failure on android #

Total comments: 4

Patch Set 4 : fix for review comments #

Total comments: 4

Patch Set 5 : use delegated ctor #

Patch Set 6 : [PLEASE REVIEW PS5] FOR TRY #

Patch Set 7 : rebase #

Unified diffs Side-by-side diffs Delta from patch set Stats (+24 lines, -8 lines) Patch
M content/browser/appcache/appcache_disk_cache.h View 1 2 3 4 5 6 2 chunks +4 lines, -0 lines 0 comments Download
M content/browser/appcache/appcache_disk_cache.cc View 1 2 3 4 5 6 3 chunks +14 lines, -8 lines 0 comments Download
M content/browser/service_worker/service_worker_disk_cache.h View 1 1 chunk +2 lines, -0 lines 0 comments Download
M content/browser/service_worker/service_worker_disk_cache.cc View 1 2 3 1 chunk +4 lines, -0 lines 0 comments Download

Messages

Total messages: 28 (10 generated)
nhiroki
PTAL, thanks!
5 years, 7 months ago (2015-05-13 06:41:25 UTC) #5
nhiroki
(+gavinp@ to CC)
5 years, 7 months ago (2015-05-13 06:42:35 UTC) #6
kinuko
Looks good, but looks like I should defer this to michaeln.
5 years, 7 months ago (2015-05-13 07:19:37 UTC) #7
nhiroki
Hmmm... ServiceWorkerBrowserTest is failing in AppCacheDiskCache on win bots. I'm now investigating...
5 years, 7 months ago (2015-05-13 09:03:23 UTC) #8
nhiroki
On 2015/05/13 09:03:23, nhiroki wrote: > Hmmm... ServiceWorkerBrowserTest is failing in AppCacheDiskCache on win bots. ...
5 years, 7 months ago (2015-05-13 09:42:15 UTC) #9
nhiroki
On 2015/05/13 09:42:15, nhiroki wrote: > On 2015/05/13 09:03:23, nhiroki wrote: > > Hmmm... ServiceWorkerBrowserTest ...
5 years, 7 months ago (2015-05-13 11:33:31 UTC) #10
michaeln
once the other cl is worked out, this one lgtm https://codereview.chromium.org/1140853002/diff/80001/content/browser/appcache/appcache_disk_cache.cc File content/browser/appcache/appcache_disk_cache.cc (right): https://codereview.chromium.org/1140853002/diff/80001/content/browser/appcache/appcache_disk_cache.cc#newcode182 ...
5 years, 7 months ago (2015-05-14 23:35:27 UTC) #14
nhiroki
Thank you! https://codereview.chromium.org/1140853002/diff/80001/content/browser/appcache/appcache_disk_cache.cc File content/browser/appcache/appcache_disk_cache.cc (right): https://codereview.chromium.org/1140853002/diff/80001/content/browser/appcache/appcache_disk_cache.cc#newcode182 content/browser/appcache/appcache_disk_cache.cc:182: use_simple_cache_ = true; On 2015/05/14 23:35:26, michaeln ...
5 years, 7 months ago (2015-05-15 02:12:52 UTC) #16
kinuko
lgtm + a few nits https://codereview.chromium.org/1140853002/diff/170001/content/browser/appcache/appcache_disk_cache.cc File content/browser/appcache/appcache_disk_cache.cc (right): https://codereview.chromium.org/1140853002/diff/170001/content/browser/appcache/appcache_disk_cache.cc#newcode181 content/browser/appcache/appcache_disk_cache.cc:181: : use_simple_cache_(true) nit: we ...
5 years, 7 months ago (2015-05-15 02:28:48 UTC) #17
nhiroki
Thanks! Updated. https://codereview.chromium.org/1140853002/diff/170001/content/browser/appcache/appcache_disk_cache.cc File content/browser/appcache/appcache_disk_cache.cc (right): https://codereview.chromium.org/1140853002/diff/170001/content/browser/appcache/appcache_disk_cache.cc#newcode181 content/browser/appcache/appcache_disk_cache.cc:181: : use_simple_cache_(true) On 2015/05/15 02:28:48, kinuko wrote: ...
5 years, 7 months ago (2015-05-15 03:02:47 UTC) #18
michaeln
What's the plan for existing data, Migrate or DeleteAndStartOver? Probably should have a plan of ...
5 years, 7 months ago (2015-05-15 23:54:24 UTC) #19
michaeln
On 2015/05/15 23:54:24, michaeln wrote: > What's the plan for existing data, Migrate or DeleteAndStartOver? ...
5 years, 7 months ago (2015-05-15 23:58:44 UTC) #20
nhiroki
On 2015/05/15 23:58:44, michaeln wrote: > On 2015/05/15 23:54:24, michaeln wrote: > > What's the ...
5 years, 7 months ago (2015-05-16 00:52:24 UTC) #21
michaeln
> Right. When navigation happens... > > (1) InitWithDiskBackend fails to open an pre-existing data ...
5 years, 7 months ago (2015-05-16 01:03:56 UTC) #22
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/1140853002/230001
5 years, 7 months ago (2015-05-16 01:25:08 UTC) #25
commit-bot: I haz the power
Committed patchset #7 (id:230001)
5 years, 7 months ago (2015-05-16 03:12:54 UTC) #26
commit-bot: I haz the power
Patchset 7 (id:??) landed as https://crrev.com/a00e5be5a06e626de1b62cbfc7c350bef08647ea Cr-Commit-Position: refs/heads/master@{#330274}
5 years, 7 months ago (2015-05-18 11:31:15 UTC) #27
nhiroki
5 years, 7 months ago (2015-05-19 09:47:13 UTC) #28
Message was sent while issue was closed.
A revert of this CL (patchset #7 id:230001) has been created in
https://codereview.chromium.org/1142193002/ by nhiroki@chromium.org.

The reason for reverting is: We'll reland this CL with DiskCache migration
code..

Powered by Google App Engine
This is Rietveld 408576698