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

Issue 1373373002: Create component to expose network usage stats to consumers. (Closed)

Created:
5 years, 2 months ago by sclittle
Modified:
5 years, 2 months ago
CC:
blundell+watchlist_chromium.org, cbentzel+watch_chromium.org, chromium-reviews, droger+watchlist_chromium.org, sdefresne+watchlist_chromium.org
Base URL:
https://chromium.googlesource.com/chromium/src.git@master
Target Ref:
refs/pending/heads/master
Project:
chromium
Visibility:
Public.

Description

Create component to expose network usage stats to consumers. Creates the new component "data_usage" that contains a DataUseAggregator. A global DataUseAggregator is owned by the IOThread. The ChromeNetworkDelegate reports data usage to the DataUseAggregator, which in turn aggregates it and reports to any registered observers. TBR=brettw@chromium.org BUG=518051 Committed: https://crrev.com/ae932be8cc8c618ae9ffefe720879c5ed82c38a5 Cr-Commit-Position: refs/heads/master@{#353137}

Patch Set 1 : Rough implementation for sanity check #

Total comments: 32

Patch Set 2 : Polished and added tests #

Total comments: 17

Patch Set 3 : Addressed comments #

Total comments: 8

Patch Set 4 : Addressed nits #

Unified diffs Side-by-side diffs Delta from patch set Stats (+599 lines, -29 lines) Patch
M chrome/browser/BUILD.gn View 1 2 3 1 chunk +1 line, -0 lines 0 comments Download
M chrome/browser/DEPS View 1 2 1 chunk +1 line, -0 lines 0 comments Download
M chrome/browser/io_thread.h View 2 chunks +7 lines, -0 lines 0 comments Download
M chrome/browser/io_thread.cc View 1 2 3 chunks +7 lines, -0 lines 0 comments Download
M chrome/browser/net/chrome_network_delegate.h View 6 chunks +15 lines, -5 lines 0 comments Download
M chrome/browser/net/chrome_network_delegate.cc View 1 4 chunks +35 lines, -2 lines 0 comments Download
M chrome/browser/net/chrome_network_delegate_unittest.cc View 1 2 7 chunks +84 lines, -5 lines 0 comments Download
M chrome/browser/profiles/profile_io_data.cc View 1 chunk +2 lines, -0 lines 0 comments Download
M chrome/chrome_browser.gypi View 1 2 3 1 chunk +1 line, -0 lines 0 comments Download
M components/OWNERS View 1 2 3 1 chunk +3 lines, -0 lines 0 comments Download
M components/components.gyp View 1 chunk +1 line, -0 lines 0 comments Download
M components/components_tests.gyp View 1 2 3 3 chunks +5 lines, -0 lines 0 comments Download
A + components/data_usage.gypi View 1 1 chunk +8 lines, -11 lines 0 comments Download
A + components/data_usage/OWNERS View 1 0 chunks +-1 lines, --1 lines 0 comments Download
A + components/data_usage/PRESUBMIT.py View 1 2 3 1 chunk +1 line, -1 line 0 comments Download
A + components/data_usage/core/BUILD.gn View 1 2 chunks +11 lines, -7 lines 0 comments Download
A + components/data_usage/core/DEPS View 1 0 chunks +-1 lines, --1 lines 0 comments Download
A components/data_usage/core/data_use.h View 1 2 1 chunk +40 lines, -0 lines 0 comments Download
A components/data_usage/core/data_use.cc View 1 2 1 chunk +24 lines, -0 lines 0 comments Download
A components/data_usage/core/data_use_aggregator.h View 1 2 1 chunk +64 lines, -0 lines 0 comments Download
A components/data_usage/core/data_use_aggregator.cc View 1 2 3 1 chunk +57 lines, -0 lines 0 comments Download
A components/data_usage/core/data_use_aggregator_unittest.cc View 1 2 3 1 chunk +234 lines, -0 lines 0 comments Download

Messages

Total messages: 33 (7 generated)
sclittle
PTAL for sanity check. I'll add tests and clean it up in a later patch ...
5 years, 2 months ago (2015-09-29 22:15:39 UTC) #4
sdefresne
https://codereview.chromium.org/1373373002/diff/40001/components/data_usage/core/DEPS File components/data_usage/core/DEPS (right): https://codereview.chromium.org/1373373002/diff/40001/components/data_usage/core/DEPS#newcode2 components/data_usage/core/DEPS:2: "+base", nit, drive-by: every component can depends on base, ...
5 years, 2 months ago (2015-09-30 08:52:50 UTC) #5
tbansal1
https://codereview.chromium.org/1373373002/diff/40001/chrome/browser/io_thread.cc File chrome/browser/io_thread.cc (right): https://codereview.chromium.org/1373373002/diff/40001/chrome/browser/io_thread.cc#newcode582 chrome/browser/io_thread.cc:582: chrome_network_delegate->set_data_use_aggregator( May be move this after tracking_profile4 (right now ...
5 years, 2 months ago (2015-10-01 20:30:43 UTC) #6
bengr
https://codereview.chromium.org/1373373002/diff/40001/components/data_usage/OWNERS File components/data_usage/OWNERS (right): https://codereview.chromium.org/1373373002/diff/40001/components/data_usage/OWNERS#newcode3 components/data_usage/OWNERS:3: tbansal@chromium.org tbansal should be an owner, but he should ...
5 years, 2 months ago (2015-10-02 19:32:22 UTC) #7
sclittle
https://codereview.chromium.org/1373373002/diff/40001/chrome/browser/io_thread.cc File chrome/browser/io_thread.cc (right): https://codereview.chromium.org/1373373002/diff/40001/chrome/browser/io_thread.cc#newcode582 chrome/browser/io_thread.cc:582: chrome_network_delegate->set_data_use_aggregator( On 2015/10/01 20:30:43, tbansal1 wrote: > May be ...
5 years, 2 months ago (2015-10-03 03:27:53 UTC) #9
sclittle
bengr, tbansal: * mmenke: chrome/browser/* blundell: components/* brettw: '+url' in DEPS Thanks in advance!
5 years, 2 months ago (2015-10-03 03:28:52 UTC) #11
blundell
On 2015/10/03 03:28:52, sclittle wrote: > bengr, tbansal: * > mmenke: chrome/browser/* > blundell: components/* ...
5 years, 2 months ago (2015-10-05 07:39:44 UTC) #12
mmenke
On 2015/10/05 07:39:44, blundell wrote: > On 2015/10/03 03:28:52, sclittle wrote: > > bengr, tbansal: ...
5 years, 2 months ago (2015-10-05 15:01:34 UTC) #13
mmenke
On 2015/10/05 15:01:34, mmenke wrote: > On 2015/10/05 07:39:44, blundell wrote: > > On 2015/10/03 ...
5 years, 2 months ago (2015-10-05 15:43:16 UTC) #14
sclittle
On 2015/10/05 15:43:16, mmenke wrote: > On 2015/10/05 15:01:34, mmenke wrote: > > > > ...
5 years, 2 months ago (2015-10-05 21:46:04 UTC) #15
sclittle
On 2015/10/05 07:39:44, blundell wrote: > On 2015/10/03 03:28:52, sclittle wrote: > > bengr, tbansal: ...
5 years, 2 months ago (2015-10-05 21:51:28 UTC) #16
mmenke
On 2015/10/05 21:46:04, sclittle wrote: > On 2015/10/05 15:43:16, mmenke wrote: > > On 2015/10/05 ...
5 years, 2 months ago (2015-10-05 22:17:46 UTC) #17
tbansal1
On 2015/10/05 22:17:46, mmenke wrote: > On 2015/10/05 21:46:04, sclittle wrote: > > On 2015/10/05 ...
5 years, 2 months ago (2015-10-05 22:19:00 UTC) #18
mmenke
On 2015/10/05 22:19:00, tbansal1 wrote: > On 2015/10/05 22:17:46, mmenke wrote: > > On 2015/10/05 ...
5 years, 2 months ago (2015-10-05 23:22:14 UTC) #19
sclittle
On 2015/10/05 23:22:14, mmenke wrote: > On 2015/10/05 22:19:00, tbansal1 wrote: > > On 2015/10/05 ...
5 years, 2 months ago (2015-10-06 01:17:00 UTC) #20
bengr
https://codereview.chromium.org/1373373002/diff/80001/chrome/browser/io_thread.cc File chrome/browser/io_thread.cc (right): https://codereview.chromium.org/1373373002/diff/80001/chrome/browser/io_thread.cc#newcode584 chrome/browser/io_thread.cc:584: true /* is_data_usage_off_the_record */); Why the underscores? https://codereview.chromium.org/1373373002/diff/80001/chrome/browser/net/chrome_network_delegate.cc File ...
5 years, 2 months ago (2015-10-06 19:30:28 UTC) #21
tbansal1
https://codereview.chromium.org/1373373002/diff/80001/components/data_usage/core/data_use.h File components/data_usage/core/data_use.h (right): https://codereview.chromium.org/1373373002/diff/80001/components/data_usage/core/data_use.h#newcode20 components/data_usage/core/data_use.h:20: int tab_id, On 2015/10/06 19:30:28, bengr wrote: > Perhaps ...
5 years, 2 months ago (2015-10-06 20:13:15 UTC) #22
sclittle
https://codereview.chromium.org/1373373002/diff/80001/chrome/browser/io_thread.cc File chrome/browser/io_thread.cc (right): https://codereview.chromium.org/1373373002/diff/80001/chrome/browser/io_thread.cc#newcode584 chrome/browser/io_thread.cc:584: true /* is_data_usage_off_the_record */); On 2015/10/06 19:30:27, bengr wrote: ...
5 years, 2 months ago (2015-10-07 01:07:56 UTC) #23
mmenke
On 2015/10/06 01:17:00, sclittle wrote: > On 2015/10/05 23:22:14, mmenke wrote: > > On 2015/10/05 ...
5 years, 2 months ago (2015-10-07 19:38:35 UTC) #24
bengr
lgtm
5 years, 2 months ago (2015-10-07 20:54:26 UTC) #25
tbansal1
lgtm nits. https://codereview.chromium.org/1373373002/diff/80001/chrome/browser/io_thread.cc File chrome/browser/io_thread.cc (right): https://codereview.chromium.org/1373373002/diff/80001/chrome/browser/io_thread.cc#newcode584 chrome/browser/io_thread.cc:584: true /* is_data_usage_off_the_record */); On 2015/10/07 01:07:55, ...
5 years, 2 months ago (2015-10-08 04:22:44 UTC) #26
blundell
On 2015/10/05 21:51:28, sclittle wrote: > On 2015/10/05 07:39:44, blundell wrote: > > On 2015/10/03 ...
5 years, 2 months ago (2015-10-08 07:17:30 UTC) #27
sclittle
https://codereview.chromium.org/1373373002/diff/80001/chrome/browser/io_thread.cc File chrome/browser/io_thread.cc (right): https://codereview.chromium.org/1373373002/diff/80001/chrome/browser/io_thread.cc#newcode584 chrome/browser/io_thread.cc:584: true /* is_data_usage_off_the_record */); On 2015/10/08 04:22:44, tbansal1 wrote: ...
5 years, 2 months ago (2015-10-08 19:44:13 UTC) #28
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/1373373002/120001 View timeline at https://chromium-cq-status.appspot.com/patch-timeline/1373373002/120001
5 years, 2 months ago (2015-10-08 19:51:01 UTC) #31
commit-bot: I haz the power
Committed patchset #4 (id:120001)
5 years, 2 months ago (2015-10-08 20:53:59 UTC) #32
commit-bot: I haz the power
5 years, 2 months ago (2015-10-08 20:54:52 UTC) #33
Message was sent while issue was closed.
Patchset 4 (id:??) landed as
https://crrev.com/ae932be8cc8c618ae9ffefe720879c5ed82c38a5
Cr-Commit-Position: refs/heads/master@{#353137}

Powered by Google App Engine
This is Rietveld 408576698