Chromium Code Reviews| Index: chrome/browser/prefs/pref_metrics_service.cc |
| diff --git a/chrome/browser/prefs/pref_metrics_service.cc b/chrome/browser/prefs/pref_metrics_service.cc |
| index 8b6f389f961c1d5cf0a3c24a9865c05651e721a3..9510b6ef070a2fc0f9af031f71bdbb1d5f8abd2c 100644 |
| --- a/chrome/browser/prefs/pref_metrics_service.cc |
| +++ b/chrome/browser/prefs/pref_metrics_service.cc |
| @@ -1,4 +1,4 @@ |
| -// Copyright 2013 The Chromium Authors. All rights reserved. |
| +// Copyright 2014 The Chromium Authors. All rights reserved. |
| // Use of this source code is governed by a BSD-style license that can be |
| // found in the LICENSE file. |
| @@ -22,6 +22,7 @@ |
| #include "chrome/common/chrome_switches.h" |
| #include "chrome/common/pref_names.h" |
| #include "components/browser_context_keyed_service/browser_context_dependency_manager.h" |
| +#include "components/rappor/rappor_service.h" |
| #include "crypto/hmac.h" |
| #include "net/base/registry_controlled_domains/registry_controlled_domain.h" |
| @@ -29,6 +30,16 @@ namespace { |
| const int kSessionStartupPrefValueMax = SessionStartupPref::kPrefValueMax; |
| +const rappor::RapporParameters kHomePageRapporParameters = { |
|
Alexei Svitkine (slow)
2014/02/03 22:34:18
As I said in a previous comment, I don't think we
Steven Holte
2014/02/03 23:58:06
Done. These parameters now live in components/rap
|
| + "Settings.HomePage" /* Metric name */, |
| + 16 /* Bloom filter size bytes */, |
| + 2 /* Bloom filter hash count */, |
| + rappor::PROBABILITY_75 /* Fake data probability */, |
| + rappor::PROBABILITY_50 /* Fake one probability */, |
| + rappor::PROBABILITY_75 /* One coin probability */, |
| + rappor::PROBABILITY_50 /* Zero coin probability */ |
| +}; |
| + |
| } // namespace |
| PrefMetricsService::PrefMetricsService(Profile* profile) |
| @@ -78,6 +89,10 @@ void PrefMetricsService::RecordLaunchPrefs() { |
| "Settings.HomePageEngineType", |
| TemplateURLPrepopulateData::GetEngineType(homepage_url), |
| SEARCH_ENGINE_MAX); |
| + g_browser_process->rappor_service()->RecordSample( |
| + kHomePageRapporParameters, |
| + net::registry_controlled_domains::GetDomainAndRegistry(homepage_url, |
| + net::registry_controlled_domains::INCLUDE_PRIVATE_REGISTRIES)); |
| } |
| } |