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

Issue 1268663003: Service Worker: Make ServiceWorkerRegistration.update() return a promise. (Blink Layout 3/3) (Closed)

Created:
5 years, 4 months ago by jungkees
Modified:
5 years, 4 months ago
CC:
blink-reviews, jsbell, tzik, serviceworker-reviews, dglazkov+blink, kinuko+serviceworker, horo
Base URL:
https://chromium.googlesource.com/chromium/blink.git@master
Target Ref:
refs/heads/master
Project:
blink
Visibility:
Public.

Description

Service Worker: Make ServiceWorkerRegistration.update() return a promise. (Blink Layout 3/3) As per the resolution of f2f, ServiceWorkerRegistration.update() should return a promise that transforms the promise returned by Update algorithm. In this CL, ServiceWorkerContextCore::UpdateServiceWorker method has been overloaded to cover two invocation paths: a scheduled update without a provider_host and a callback (Soft Update in the spec) and a call initiated from the script surface using ServiceWorkerRegistration.update(). Spec: https://slightlyoff.github.io/ServiceWorker/spec/service_worker/#service-worker-registration-update Spec discussion: https://github.com/slightlyoff/ServiceWorker/issues/311 Companion CL (Blink): https://codereview.chromium.org/1260833003/ Companion CL (Chromium): https://codereview.chromium.org/1270513002/ BUG=513655 Committed: https://src.chromium.org/viewvc/blink?view=rev&revision=200300

Patch Set 1 #

Total comments: 2

Patch Set 2 : #

Total comments: 7

Patch Set 3 : Merge test files. #

Patch Set 4 : Nit: correct the file name in comment. #

Patch Set 5 : Remove output set before setcookie. #

Total comments: 7

Patch Set 6 : Simplify the php script structure; remove uncessary catch block. #

Patch Set 7 : Rebase. #

Unified diffs Side-by-side diffs Delta from patch set Stats (+61 lines, -34 lines) Patch
M LayoutTests/http/tests/serviceworker/resources/update-worker.php View 1 2 3 4 5 1 chunk +26 lines, -5 lines 0 comments Download
M LayoutTests/http/tests/serviceworker/update.html View 1 2 3 4 5 1 chunk +34 lines, -17 lines 0 comments Download
M public/platform/modules/serviceworker/WebServiceWorkerRegistration.h View 1 2 3 4 5 6 1 chunk +1 line, -12 lines 0 comments Download

Messages

Total messages: 33 (10 generated)
jungkees
Blink layout test side of the registration.update() change. PTAL.
5 years, 4 months ago (2015-07-30 11:35:24 UTC) #2
jungkees
This CL should include the change described in the step 3 of https://codereview.chromium.org/1267703003/#msg4 after Blink-side ...
5 years, 4 months ago (2015-07-31 05:55:00 UTC) #4
commit-bot: I haz the power
Dry run: CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/1268663003/1 View timeline at https://chromium-cq-status.appspot.com/patch-timeline/1268663003/1
5 years, 4 months ago (2015-08-03 13:26:13 UTC) #6
zino
https://codereview.chromium.org/1268663003/diff/1/LayoutTests/http/tests/serviceworker/update.html File LayoutTests/http/tests/serviceworker/update.html (left): https://codereview.chromium.org/1268663003/diff/1/LayoutTests/http/tests/serviceworker/update.html#oldcode28 LayoutTests/http/tests/serviceworker/update.html:28: return wait_for_update(t, registration); Looks good to me but would ...
5 years, 4 months ago (2015-08-03 13:43:56 UTC) #8
nhiroki
On 2015/07/31 05:55:00, jungkees wrote: > This CL should include the change described in the ...
5 years, 4 months ago (2015-08-03 15:31:53 UTC) #9
jungkees
My opinion about keeping wait_for_update() helper function. Thanks for review. https://codereview.chromium.org/1268663003/diff/1/LayoutTests/http/tests/serviceworker/update.html File LayoutTests/http/tests/serviceworker/update.html (left): https://codereview.chromium.org/1268663003/diff/1/LayoutTests/http/tests/serviceworker/update.html#oldcode28 ...
5 years, 4 months ago (2015-08-05 02:09:31 UTC) #10
zino
On 2015/08/05 02:09:31, jungkees wrote: > My opinion about keeping wait_for_update() helper function. Thanks for ...
5 years, 4 months ago (2015-08-05 06:23:29 UTC) #11
jungkees
zino@, nhiroki@, I haven't update it with a new snapshot including the part that removes ...
5 years, 4 months ago (2015-08-05 07:19:58 UTC) #12
jungkees
nhiroki@, tkent@, I made WebServiceWorkerRegistration.h to the final shape and added a new layout test ...
5 years, 4 months ago (2015-08-06 07:18:47 UTC) #14
nhiroki
https://codereview.chromium.org/1268663003/diff/20001/LayoutTests/http/tests/serviceworker/resources/update-worker-error.php File LayoutTests/http/tests/serviceworker/resources/update-worker-error.php (right): https://codereview.chromium.org/1268663003/diff/20001/LayoutTests/http/tests/serviceworker/resources/update-worker-error.php#newcode1 LayoutTests/http/tests/serviceworker/resources/update-worker-error.php:1: <?php Can you rename this file to "update-error-worker.php"? Using ...
5 years, 4 months ago (2015-08-06 09:57:28 UTC) #15
jungkees
Updated the comments. Thanks for review. https://codereview.chromium.org/1268663003/diff/20001/LayoutTests/http/tests/serviceworker/resources/update-worker-error.php File LayoutTests/http/tests/serviceworker/resources/update-worker-error.php (right): https://codereview.chromium.org/1268663003/diff/20001/LayoutTests/http/tests/serviceworker/resources/update-worker-error.php#newcode1 LayoutTests/http/tests/serviceworker/resources/update-worker-error.php:1: <?php Sure, I'll ...
5 years, 4 months ago (2015-08-06 10:53:12 UTC) #16
jungkees
Uploaded a new snapshot having addressed the comments. PTAL. https://codereview.chromium.org/1268663003/diff/20001/LayoutTests/http/tests/serviceworker/resources/update-worker-error.php File LayoutTests/http/tests/serviceworker/resources/update-worker-error.php (right): https://codereview.chromium.org/1268663003/diff/20001/LayoutTests/http/tests/serviceworker/resources/update-worker-error.php#newcode11 LayoutTests/http/tests/serviceworker/resources/update-worker-error.php:11: ...
5 years, 4 months ago (2015-08-07 05:18:30 UTC) #17
jungkees
Sorry. Just wait. I found ServiceWorkerGlobalScope/update.html is affected by the merged update-worker.php file. I'll upload ...
5 years, 4 months ago (2015-08-07 05:43:28 UTC) #18
jungkees
Please ignore the #18 comment and go on a review. I confused myself with a ...
5 years, 4 months ago (2015-08-07 05:51:01 UTC) #19
jungkees
I found update.html caused a regression in mac and win builds. It turned out that ...
5 years, 4 months ago (2015-08-09 13:50:08 UTC) #20
nhiroki
LGTM with some nits https://codereview.chromium.org/1268663003/diff/80001/LayoutTests/http/tests/serviceworker/resources/update-worker.php File LayoutTests/http/tests/serviceworker/resources/update-worker.php (right): https://codereview.chromium.org/1268663003/diff/80001/LayoutTests/http/tests/serviceworker/resources/update-worker.php#newcode10 LayoutTests/http/tests/serviceworker/resources/update-worker.php:10: header("Pragma: no-cache"); Can you move ...
5 years, 4 months ago (2015-08-10 02:32:42 UTC) #21
jungkees
Addressed the comments. I think I need a review from tkent@ for the WebServiceWorkerRegistration.h change ...
5 years, 4 months ago (2015-08-10 03:20:41 UTC) #22
jungkees
tkent@, this CL is the last step for changing ServiceWorkerRegistration.update() behavior. Could you please take ...
5 years, 4 months ago (2015-08-11 01:46:24 UTC) #23
tkent
lgtm
5 years, 4 months ago (2015-08-11 02:03:44 UTC) #24
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/1268663003/100001 View timeline at https://chromium-cq-status.appspot.com/patch-timeline/1268663003/100001
5 years, 4 months ago (2015-08-11 02:05:35 UTC) #27
commit-bot: I haz the power
Try jobs failed on following builders: android_blink_compile_rel on tryserver.blink (JOB_FAILED, http://build.chromium.org/p/tryserver.blink/builders/android_blink_compile_rel/builds/45586) blink_presubmit on tryserver.blink (JOB_FAILED, ...
5 years, 4 months ago (2015-08-11 02:08:18 UTC) #29
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/1268663003/120001 View timeline at https://chromium-cq-status.appspot.com/patch-timeline/1268663003/120001
5 years, 4 months ago (2015-08-11 04:31:25 UTC) #32
commit-bot: I haz the power
5 years, 4 months ago (2015-08-11 05:48:14 UTC) #33
Message was sent while issue was closed.
Committed patchset #7 (id:120001) as
https://src.chromium.org/viewvc/blink?view=rev&revision=200300

Powered by Google App Engine
This is Rietveld 408576698