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

Issue 208843004: Add the beginning of a public Service Worker API. (Closed)

Created:
6 years, 9 months ago by Jeffrey Yasskin
Modified:
6 years, 7 months ago
Reviewers:
kinuko, alecflett, jam
CC:
chromium-reviews, jsbell+serviceworker_chromium.org, tzik, serviceworker-reviews, nhiroki, joi+watch-content_chromium.org, darin-cc_chromium.org, horo+watch_chromium.org, kinuko+watch, alecflett+watch_chromium.org, scheib
Visibility:
Public.

Description

Add the beginning of a public Service Worker API. This supports registration and unregistration from the UI thread. BUG=355131 Committed: https://src.chromium.org/viewvc/chrome?view=rev&revision=260338

Patch Set 1 #

Patch Set 2 : Add a test and fix a bug. #

Patch Set 3 : Fix two compilations #

Patch Set 4 : Fix gypi files #

Total comments: 2

Patch Set 5 : Fix #include guard name #

Total comments: 8

Patch Set 6 : Fix kinuko's comments. #

Total comments: 12

Patch Set 7 : Use a separate enum for public error codes, and document the public functions. #

Patch Set 8 : Remove an unused include #

Patch Set 9 : Switch to a bool 'success' result. #

Unified diffs Side-by-side diffs Delta from patch set Stats (+244 lines, -48 lines) Patch
M chrome/browser/browsing_data/browsing_data_remover_unittest.cc View 1 2 3 4 5 1 chunk +1 line, -2 lines 0 comments Download
M content/browser/service_worker/service_worker_browsertest.cc View 1 2 3 4 5 6 7 8 4 chunks +109 lines, -1 line 0 comments Download
D content/browser/service_worker/service_worker_context.h View 1 chunk +0 lines, -28 lines 0 comments Download
M content/browser/service_worker/service_worker_context_unittest.cc View 1 2 1 chunk +1 line, -1 line 0 comments Download
M content/browser/service_worker/service_worker_context_wrapper.h View 1 2 3 4 5 6 2 chunks +14 lines, -1 line 0 comments Download
M content/browser/service_worker/service_worker_context_wrapper.cc View 1 2 3 4 5 6 7 8 1 chunk +69 lines, -1 line 0 comments Download
M content/browser/service_worker/service_worker_internals_ui.cc View 2 chunks +4 lines, -2 lines 0 comments Download
M content/content_browser.gypi View 1 2 3 4 5 2 chunks +1 line, -1 line 0 comments Download
A + content/public/browser/service_worker_context.h View 1 2 3 4 5 6 7 8 1 chunk +43 lines, -9 lines 0 comments Download
M content/public/browser/storage_partition.h View 2 chunks +2 lines, -2 lines 0 comments Download

Messages

Total messages: 29 (0 generated)
Jeffrey Yasskin
jam will need to look at this to approve the new public API, but I'd ...
6 years, 9 months ago (2014-03-22 01:47:19 UTC) #1
alecflett
lgtm This looks nice and clean! https://codereview.chromium.org/208843004/diff/60001/content/public/common/service_worker_status_code.h File content/public/common/service_worker_status_code.h (right): https://codereview.chromium.org/208843004/diff/60001/content/public/common/service_worker_status_code.h#newcode5 content/public/common/service_worker_status_code.h:5: #ifndef CONTENT_COMMON_SERVICE_WORKER_SERVICE_WORKER_STATUS_CODE_H_ Make ...
6 years, 9 months ago (2014-03-25 20:50:38 UTC) #2
Jeffrey Yasskin
John, your turn! Are you happy with this as a public content API? Two questions ...
6 years, 9 months ago (2014-03-25 21:13:09 UTC) #3
jam
It's hard for me to review this (and answer the questions below) without knowing how ...
6 years, 9 months ago (2014-03-25 22:59:29 UTC) #4
Jeffrey Yasskin
Ah, sorry. I'm working on this to support http://crbug.com/344048 (which this CL's bug blocks indirectly), ...
6 years, 9 months ago (2014-03-25 23:04:24 UTC) #5
alecflett
On 2014/03/25 23:04:24, Jeffrey Yasskin wrote: > Ah, sorry. I'm working on this to support ...
6 years, 9 months ago (2014-03-25 23:30:31 UTC) #6
jam
On 2014/03/25 23:04:24, Jeffrey Yasskin wrote: > Ah, sorry. I'm working on this to support ...
6 years, 9 months ago (2014-03-25 23:41:23 UTC) #7
alecflett
On 2014/03/25 23:41:23, jam wrote: > > devtools is implemented in content, so it seems ...
6 years, 9 months ago (2014-03-25 23:53:14 UTC) #8
Jeffrey Yasskin
On Tue, Mar 25, 2014 at 4:41 PM, <jam@chromium.org> wrote: > On 2014/03/25 23:04:24, Jeffrey ...
6 years, 9 months ago (2014-03-25 23:54:23 UTC) #9
kinuko
Drive-by, mostly nits/minor comments only. For having UI thread restriction on public ServiceWorkerContext interface I ...
6 years, 9 months ago (2014-03-26 05:01:34 UTC) #10
jam
On 2014/03/25 23:53:14, alecflett wrote: > On 2014/03/25 23:41:23, jam wrote: > > > > ...
6 years, 9 months ago (2014-03-26 16:50:45 UTC) #11
jam
On 2014/03/25 23:54:23, Jeffrey Yasskin wrote: > On Tue, Mar 25, 2014 at 4:41 PM, ...
6 years, 9 months ago (2014-03-26 16:52:08 UTC) #12
alecflett
On 2014/03/26 16:50:45, jam wrote: > On 2014/03/25 23:53:14, alecflett wrote: > > On 2014/03/25 ...
6 years, 9 months ago (2014-03-26 17:35:25 UTC) #13
Jeffrey Yasskin
On Wed, Mar 26, 2014 at 9:52 AM, <jam@chromium.org> wrote: > On 2014/03/25 23:54:23, Jeffrey ...
6 years, 9 months ago (2014-03-26 18:03:37 UTC) #14
Jeffrey Yasskin
Thanks for looking over this, Kinuko. https://codereview.chromium.org/208843004/diff/170001/content/browser/service_worker/service_worker_browsertest.cc File content/browser/service_worker/service_worker_browsertest.cc (right): https://codereview.chromium.org/208843004/diff/170001/content/browser/service_worker/service_worker_browsertest.cc#newcode435 content/browser/service_worker/service_worker_browsertest.cc:435: class ServiceWorkerBlackBoxBrowserTest : ...
6 years, 9 months ago (2014-03-26 19:58:51 UTC) #15
jam
On 2014/03/26 18:03:37, Jeffrey Yasskin wrote: > On Wed, Mar 26, 2014 at 9:52 AM, ...
6 years, 9 months ago (2014-03-26 22:58:39 UTC) #16
Jeffrey Yasskin
I haven't uploaded a new patch yet, but assume anything I haven't replied to will ...
6 years, 9 months ago (2014-03-27 02:51:59 UTC) #17
jam
https://codereview.chromium.org/208843004/diff/320001/content/public/common/service_worker_status_code.h File content/public/common/service_worker_status_code.h (right): https://codereview.chromium.org/208843004/diff/320001/content/public/common/service_worker_status_code.h#newcode13 content/public/common/service_worker_status_code.h:13: enum ServiceWorkerStatusCode { On 2014/03/27 02:51:59, Jeffrey Yasskin wrote: ...
6 years, 9 months ago (2014-03-27 17:06:26 UTC) #18
michaeln
> ServiceWorker folks: does that sound possible, for a script that should already > exist ...
6 years, 9 months ago (2014-03-27 19:46:58 UTC) #19
Jeffrey Yasskin
https://codereview.chromium.org/208843004/diff/320001/content/public/browser/service_worker_context.h File content/public/browser/service_worker_context.h (right): https://codereview.chromium.org/208843004/diff/320001/content/public/browser/service_worker_context.h#newcode25 content/public/browser/service_worker_context.h:25: virtual void RegisterServiceWorker(const Scope& pattern, On 2014/03/26 22:58:39, jam ...
6 years, 9 months ago (2014-03-27 20:33:05 UTC) #20
jam
https://codereview.chromium.org/208843004/diff/320001/content/public/common/service_worker_status_code.h File content/public/common/service_worker_status_code.h (right): https://codereview.chromium.org/208843004/diff/320001/content/public/common/service_worker_status_code.h#newcode13 content/public/common/service_worker_status_code.h:13: enum ServiceWorkerStatusCode { On 2014/03/27 20:33:06, Jeffrey Yasskin wrote: ...
6 years, 9 months ago (2014-03-27 22:48:25 UTC) #21
Jeffrey Yasskin
On 2014/03/27 22:48:25, jam wrote: > https://codereview.chromium.org/208843004/diff/320001/content/public/common/service_worker_status_code.h > File content/public/common/service_worker_status_code.h (right): > > https://codereview.chromium.org/208843004/diff/320001/content/public/common/service_worker_status_code.h#newcode13 > ...
6 years, 9 months ago (2014-03-28 00:33:19 UTC) #22
jam
lgtm for files outside of service_worker directory https://codereview.chromium.org/208843004/diff/320001/content/public/browser/service_worker_context.h File content/public/browser/service_worker_context.h (right): https://codereview.chromium.org/208843004/diff/320001/content/public/browser/service_worker_context.h#newcode21 content/public/browser/service_worker_context.h:21: typedef GURL ...
6 years, 9 months ago (2014-03-28 18:08:06 UTC) #23
Jeffrey Yasskin
On Fri, Mar 28, 2014 at 11:08 AM, <jam@chromium.org> wrote: > lgtm for files outside ...
6 years, 9 months ago (2014-03-28 20:33:31 UTC) #24
jam
On 2014/03/28 20:33:31, Jeffrey Yasskin wrote: > On Fri, Mar 28, 2014 at 11:08 AM, ...
6 years, 9 months ago (2014-03-28 20:37:17 UTC) #25
Jeffrey Yasskin
Alec suggests that we'll iterate on the API if it's not perfect today, and that ...
6 years, 9 months ago (2014-03-28 23:40:23 UTC) #26
Jeffrey Yasskin
The CQ bit was checked by jyasskin@chromium.org
6 years, 9 months ago (2014-03-28 23:40:29 UTC) #27
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-status.appspot.com/cq/jyasskin@chromium.org/208843004/420001
6 years, 9 months ago (2014-03-28 23:42:14 UTC) #28
commit-bot: I haz the power
6 years, 9 months ago (2014-03-29 01:42:07 UTC) #29
Message was sent while issue was closed.
Change committed as 260338

Powered by Google App Engine
This is Rietveld 408576698