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

Issue 2371883002: Add PLMObserver::FlushMetricsOnAppEnterBackground. (Closed)

Created:
4 years, 2 months ago by Bryan McQuade
Modified:
4 years, 2 months ago
Reviewers:
Charlie Harrison
CC:
chromium-reviews, csharrison+watch_chromium.org, loading-reviews+metrics_chromium.org, RyanSturm
Target Ref:
refs/pending/heads/master
Project:
chromium
Visibility:
Public.

Description

Add PLMObserver::FlushMetricsOnAppEnterBackground. PLMObserver::FlushMetricsOnAppEnterBackground gets invoked when the metrics subsystem is flushing metrics as part of the app entering the background. Observers that buffer metrics information and flush it in the OnComplete callback may want to implement this method, in order to avoid losing data due to the application being killed after being backgrounded. BUG=608360 Committed: https://crrev.com/6e7584a091cbb8078ed4289ffa739281bf170cbb Cr-Commit-Position: refs/heads/master@{#421206}

Patch Set 1 #

Patch Set 2 : change default impl to be a no-op #

Patch Set 3 : clean up comment #

Patch Set 4 : add test #

Total comments: 6

Patch Set 5 : fix comment #

Unified diffs Side-by-side diffs Delta from patch set Stats (+67 lines, -3 lines) Patch
M chrome/browser/page_load_metrics/metrics_web_contents_observer.cc View 2 chunks +15 lines, -0 lines 0 comments Download
M chrome/browser/page_load_metrics/metrics_web_contents_observer_unittest.cc View 1 2 3 3 chunks +16 lines, -1 line 0 comments Download
M chrome/browser/page_load_metrics/page_load_metrics_observer.h View 1 2 3 4 2 chunks +29 lines, -2 lines 0 comments Download
M chrome/browser/page_load_metrics/page_load_metrics_observer.cc View 1 1 chunk +7 lines, -0 lines 0 comments Download

Dependent Patchsets:

Messages

Total messages: 29 (20 generated)
Bryan McQuade
PTAL, thanks!
4 years, 2 months ago (2016-09-26 20:16:05 UTC) #12
Charlie Harrison
Looks good. Do you think the chrome:// patch should augment OnStart and OnCommit to return ...
4 years, 2 months ago (2016-09-26 20:56:39 UTC) #15
Bryan McQuade
On 2016/09/26 at 20:56:39, csharrison wrote: > Looks good. Do you think the chrome:// patch ...
4 years, 2 months ago (2016-09-27 12:36:33 UTC) #16
Charlie Harrison
That's fine by me. This looks good but per my comment I'm interested in if ...
4 years, 2 months ago (2016-09-27 12:50:09 UTC) #17
Charlie Harrison
lgtm % comment nit. As discussed in person, app backgrounding is special and can result ...
4 years, 2 months ago (2016-09-27 13:05:52 UTC) #18
Bryan McQuade
Thanks! I updated the comment to be clearer. https://codereview.chromium.org/2371883002/diff/60001/chrome/browser/page_load_metrics/page_load_metrics_observer.h File chrome/browser/page_load_metrics/page_load_metrics_observer.h (right): https://codereview.chromium.org/2371883002/diff/60001/chrome/browser/page_load_metrics/page_load_metrics_observer.h#newcode137 chrome/browser/page_load_metrics/page_load_metrics_observer.h:137: enum ...
4 years, 2 months ago (2016-09-27 13:17:20 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/2371883002/80001
4 years, 2 months ago (2016-09-27 14:38:02 UTC) #26
commit-bot: I haz the power
Committed patchset #5 (id:80001)
4 years, 2 months ago (2016-09-27 14:43:19 UTC) #27
commit-bot: I haz the power
4 years, 2 months ago (2016-09-27 14:44:46 UTC) #29
Message was sent while issue was closed.
Patchset 5 (id:??) landed as
https://crrev.com/6e7584a091cbb8078ed4289ffa739281bf170cbb
Cr-Commit-Position: refs/heads/master@{#421206}

Powered by Google App Engine
This is Rietveld 408576698