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

Issue 2219393004: Adds an observer for the request coordinator. (Closed)

Created:
4 years, 4 months ago by Pete Williamson
Modified:
4 years, 4 months ago
Reviewers:
Dmitry Titov, fgorski
CC:
romax, chromium-reviews, romax+watch_chromium.org, fgorski+watch_chromium.org, dewittj+watch_chromium.org, petewil+watch_chromium.org, chili+watch_chromium.org, dimich+watch_chromium.org
Base URL:
https://chromium.googlesource.com/chromium/src.git@resumeAPI
Target Ref:
refs/pending/heads/master
Project:
chromium
Visibility:
Public.

Description

Adds an observer for the request coordinator. The request coordinator observer follows the standard chrome observer_list pattern, and sends out notifications to registered observers whenever the state of a request changes. Supported notifications are request succeeded, request failed, request became available, or request was paused. BUG=610521 Committed: https://crrev.com/feb1dd8c3f56254d000fa0c46a892c930a06054e Cr-Commit-Position: refs/heads/master@{#412088}

Patch Set 1 #

Total comments: 4

Patch Set 2 : First round of feedback #

Total comments: 22

Patch Set 3 : Second batch of FGorski CR fixes #

Total comments: 10

Patch Set 4 : CR feedback per Dimich - Changed return values #

Total comments: 6

Patch Set 5 : Fix nits. #

Unified diffs Side-by-side diffs Delta from patch set Stats (+483 lines, -146 lines) Patch
M components/offline_pages/background/request_coordinator.h View 1 2 3 6 chunks +50 lines, -2 lines 0 comments Download
M components/offline_pages/background/request_coordinator.cc View 1 2 3 4 9 chunks +63 lines, -24 lines 0 comments Download
M components/offline_pages/background/request_coordinator_unittest.cc View 1 2 3 4 8 chunks +116 lines, -0 lines 0 comments Download
M components/offline_pages/background/request_queue.h View 1 2 3 2 chunks +8 lines, -2 lines 0 comments Download
M components/offline_pages/background/request_queue.cc View 1 2 3 3 chunks +13 lines, -4 lines 0 comments Download
M components/offline_pages/background/request_queue_in_memory_store.h View 1 2 3 1 chunk +9 lines, -6 lines 0 comments Download
M components/offline_pages/background/request_queue_in_memory_store.cc View 1 2 3 1 chunk +22 lines, -11 lines 0 comments Download
M components/offline_pages/background/request_queue_store.h View 1 2 3 2 chunks +9 lines, -4 lines 0 comments Download
M components/offline_pages/background/request_queue_store_sql.h View 1 2 3 2 chunks +5 lines, -4 lines 0 comments Download
M components/offline_pages/background/request_queue_store_sql.cc View 1 2 3 6 chunks +114 lines, -66 lines 0 comments Download
M components/offline_pages/background/request_queue_store_unittest.cc View 1 2 3 6 chunks +31 lines, -6 lines 0 comments Download
M components/offline_pages/background/request_queue_unittest.cc View 1 2 3 9 chunks +43 lines, -17 lines 0 comments Download

Messages

Total messages: 26 (13 generated)
Dmitry Titov
Some initial thoughts: https://codereview.chromium.org/2219393004/diff/1/components/offline_pages/background/request_coordinator.h File components/offline_pages/background/request_coordinator.h (right): https://codereview.chromium.org/2219393004/diff/1/components/offline_pages/background/request_coordinator.h#newcode46 components/offline_pages/background/request_coordinator.h:46: virtual void OnAvailable(RequestInfo info) = 0; ...
4 years, 4 months ago (2016-08-09 20:14:59 UTC) #2
Pete Williamson
Romax, here is a preview of what the observer will look like. https://codereview.chromium.org/2219393004/diff/1/components/offline_pages/background/request_coordinator.h File components/offline_pages/background/request_coordinator.h ...
4 years, 4 months ago (2016-08-10 01:36:23 UTC) #3
fgorski
Initial list. https://codereview.chromium.org/2219393004/diff/20001/components/offline_pages/background/request_coordinator.cc File components/offline_pages/background/request_coordinator.cc (right): https://codereview.chromium.org/2219393004/diff/20001/components/offline_pages/background/request_coordinator.cc#newcode134 components/offline_pages/background/request_coordinator.cc:134: SendNotifyChangeForRequestIdList(request_ids); I think that should be happening ...
4 years, 4 months ago (2016-08-10 21:30:45 UTC) #5
Pete Williamson
https://codereview.chromium.org/2219393004/diff/20001/components/offline_pages/background/request_coordinator.cc File components/offline_pages/background/request_coordinator.cc (right): https://codereview.chromium.org/2219393004/diff/20001/components/offline_pages/background/request_coordinator.cc#newcode134 components/offline_pages/background/request_coordinator.cc:134: SendNotifyChangeForRequestIdList(request_ids); On 2016/08/10 21:30:44, fgorski wrote: > I think ...
4 years, 4 months ago (2016-08-11 00:08:37 UTC) #6
Dmitry Titov
https://codereview.chromium.org/2219393004/diff/40001/components/offline_pages/background/request_coordinator.cc File components/offline_pages/background/request_coordinator.cc (right): https://codereview.chromium.org/2219393004/diff/40001/components/offline_pages/background/request_coordinator.cc#newcode169 components/offline_pages/background/request_coordinator.cc:169: void RequestCoordinator::UpdateMultipleRequestCallback( UpdateMultipleRequestCallback and SendNotifyChangeForRequestIdList can be merged into ...
4 years, 4 months ago (2016-08-11 03:41:56 UTC) #11
fgorski
lgtm, after you resolve Dmitry's comment about reading before notifying. https://codereview.chromium.org/2219393004/diff/40001/components/offline_pages/background/request_coordinator.h File components/offline_pages/background/request_coordinator.h (right): https://codereview.chromium.org/2219393004/diff/40001/components/offline_pages/background/request_coordinator.h#newcode50 ...
4 years, 4 months ago (2016-08-11 17:03:59 UTC) #12
Pete Williamson
https://codereview.chromium.org/2219393004/diff/40001/components/offline_pages/background/request_coordinator.cc File components/offline_pages/background/request_coordinator.cc (right): https://codereview.chromium.org/2219393004/diff/40001/components/offline_pages/background/request_coordinator.cc#newcode169 components/offline_pages/background/request_coordinator.cc:169: void RequestCoordinator::UpdateMultipleRequestCallback( On 2016/08/11 03:41:55, Dmitry Titov wrote: > ...
4 years, 4 months ago (2016-08-13 03:20:34 UTC) #13
fgorski
just a few nits to look at https://codereview.chromium.org/2219393004/diff/60001/components/offline_pages/background/request_coordinator.cc File components/offline_pages/background/request_coordinator.cc (right): https://codereview.chromium.org/2219393004/diff/60001/components/offline_pages/background/request_coordinator.cc#newcode159 components/offline_pages/background/request_coordinator.cc:159: for (SavePageRequest ...
4 years, 4 months ago (2016-08-15 17:51:44 UTC) #18
Pete Williamson
https://codereview.chromium.org/2219393004/diff/60001/components/offline_pages/background/request_coordinator.cc File components/offline_pages/background/request_coordinator.cc (right): https://codereview.chromium.org/2219393004/diff/60001/components/offline_pages/background/request_coordinator.cc#newcode159 components/offline_pages/background/request_coordinator.cc:159: for (SavePageRequest request : requests) { On 2016/08/15 17:51:44, ...
4 years, 4 months ago (2016-08-15 20:22:52 UTC) #19
Dmitry Titov
lgtm
4 years, 4 months ago (2016-08-15 21:36:57 UTC) #20
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/2219393004/80001
4 years, 4 months ago (2016-08-15 21:39:50 UTC) #23
commit-bot: I haz the power
Committed patchset #5 (id:80001)
4 years, 4 months ago (2016-08-15 23:22:34 UTC) #24
commit-bot: I haz the power
4 years, 4 months ago (2016-08-15 23:25:46 UTC) #26
Message was sent while issue was closed.
Patchset 5 (id:??) landed as
https://crrev.com/feb1dd8c3f56254d000fa0c46a892c930a06054e
Cr-Commit-Position: refs/heads/master@{#412088}

Powered by Google App Engine
This is Rietveld 408576698