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

Issue 1108253002: (Reland) Evict Service Worker when reading it from disk cache fails. (Closed)

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

Description

(Reland) Evict Service Worker when reading it from disk cache fails. If reading the SW resources from the disk cache fails, we should evict the worker or else we will keep getting the same failure. This patch unsets the worker from the live registration, and then deletes the registration if the SW was the stored version. This relands the original commit (64e3ffb1c), and fixes a problem where the test terminated before the eviction, which starts on the IO thread, then hops to the database task runner, finishes. Now the test ends by looking up the registration in storage, which hops to the database task runner, so it can only finish once eviction finishes. Original patch: https://codereview.chromium.org/1098083003/ BUG=448003 Committed: https://crrev.com/0e476caf67493d79b6dc40891e7ef8868871983e Cr-Commit-Position: refs/heads/master@{#327260}

Patch Set 1 : original patch #

Patch Set 2 : new patch #

Patch Set 3 : check context #

Total comments: 2

Patch Set 4 : review comments #

Unified diffs Side-by-side diffs Delta from patch set Stats (+239 lines, -38 lines) Patch
M content/browser/service_worker/service_worker_browsertest.cc View 1 2 3 9 chunks +185 lines, -5 lines 0 comments Download
M content/browser/service_worker/service_worker_read_from_cache_job.cc View 1 2 chunks +8 lines, -1 line 0 comments Download
M content/browser/service_worker/service_worker_registration.h View 1 chunk +4 lines, -0 lines 0 comments Download
M content/browser/service_worker/service_worker_registration.cc View 1 2 3 chunks +42 lines, -32 lines 0 comments Download

Messages

Total messages: 10 (3 generated)
falken
PTAL Patchset #1 is the original patch. I think what happened (after discussion with nhiroki@) ...
5 years, 8 months ago (2015-04-28 07:34:15 UTC) #2
kinuko
lgtm These core modules are really tightly coupled, needing to have a lot of fixture ...
5 years, 8 months ago (2015-04-28 08:34:05 UTC) #3
nhiroki
lgtm
5 years, 8 months ago (2015-04-28 08:41:57 UTC) #4
falken
Thanks! https://codereview.chromium.org/1108253002/diff/40001/content/browser/service_worker/service_worker_browsertest.cc File content/browser/service_worker/service_worker_browsertest.cc (right): https://codereview.chromium.org/1108253002/diff/40001/content/browser/service_worker/service_worker_browsertest.cc#newcode590 content/browser/service_worker/service_worker_browsertest.cc:590: DCHECK_CURRENTLY_ON(BrowserThread::IO); On 2015/04/28 08:34:05, kinuko wrote: > nit: ...
5 years, 8 months ago (2015-04-28 09:00:11 UTC) #5
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/1108253002/60001
5 years, 8 months ago (2015-04-28 09:00:53 UTC) #8
commit-bot: I haz the power
Committed patchset #4 (id:60001)
5 years, 7 months ago (2015-04-28 10:43:35 UTC) #9
commit-bot: I haz the power
5 years, 7 months ago (2015-04-28 10:44:32 UTC) #10
Message was sent while issue was closed.
Patchset 4 (id:??) landed as
https://crrev.com/0e476caf67493d79b6dc40891e7ef8868871983e
Cr-Commit-Position: refs/heads/master@{#327260}

Powered by Google App Engine
This is Rietveld 408576698