Skip to content

Commit

Permalink
Add local histogram to see what UMA pageloads are
Browse files Browse the repository at this point in the history
This adds a histogram that gets a sample each time the
UMA pageload counter is incremented.  The result is that
any time you refresh:
about:histograms/Chrome.UmaPageloadCounter
You'll see how many pageloads have taken place during
the session.  Be warned: Each refresh of that histogram
page will also add 1 to the tally ;-).

If you want to use this patch in a personal build, be
sure to modify browser_main.cc so that metrics->Start()
is called (even if this is not an official build).
Review URL: http://codereview.chromium.org/7792070

git-svn-id: svn://svn.chromium.org/chrome/trunk/src@99289 0039d316-1c4b-4281-b951-d872f2087c98
  • Loading branch information
jar@chromium.org committed Sep 2, 2011
1 parent 0d6ec3a commit dd8d12a
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions chrome/browser/metrics/metrics_service.cc
Original file line number Diff line number Diff line change
Expand Up @@ -1460,6 +1460,7 @@ void MetricsService::IncrementLongPrefsValue(const char* path) {
}

void MetricsService::LogLoadStarted() {
HISTOGRAM_ENUMERATION("Chrome.UmaPageloadCounter", 1, 2);
IncrementPrefValue(prefs::kStabilityPageLoadCount);
IncrementLongPrefsValue(prefs::kUninstallMetricsPageLoadCount);
// We need to save the prefs, as page load count is a critical stat, and it
Expand Down

0 comments on commit dd8d12a

Please sign in to comment.