diff options
author | asargent@chromium.org <asargent@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2014-01-30 00:57:28 +0000 |
---|---|---|
committer | asargent@chromium.org <asargent@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2014-01-30 00:57:28 +0000 |
commit | 29deece3a54e6909d02a20b8c2712bee922b6297 (patch) | |
tree | 3d300cf73bcc453a4dc44bd64137b73b396bb249 /chrome/browser/extensions/install_verifier.cc | |
parent | 1705bfed7c13a24545a2ba7d81ec4fdbe73309a8 (diff) | |
download | chromium_src-29deece3a54e6909d02a20b8c2712bee922b6297.zip chromium_src-29deece3a54e6909d02a20b8c2712bee922b6297.tar.gz chromium_src-29deece3a54e6909d02a20b8c2712bee922b6297.tar.bz2 |
Change default mode of extension install verification
Right now the default mode is to make requests against the server unless
the experiment group says not to, and that may be contributing to some
unexpected load we're seeing. So this CL changes it to not do that.
It also adds some histograms to help measure the success rate and
sources of requests to the server.
BUG=335379
R=finnur@chromium.org
Review URL: https://codereview.chromium.org/149353002
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@247790 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'chrome/browser/extensions/install_verifier.cc')
-rw-r--r-- | chrome/browser/extensions/install_verifier.cc | 12 |
1 files changed, 11 insertions, 1 deletions
diff --git a/chrome/browser/extensions/install_verifier.cc b/chrome/browser/extensions/install_verifier.cc index 7f06c68..642457d 100644 --- a/chrome/browser/extensions/install_verifier.cc +++ b/chrome/browser/extensions/install_verifier.cc @@ -30,6 +30,11 @@ enum VerifyStatus { NONE = 0, // Do not request install signatures, and do not enforce them. BOOTSTRAP, // Request install signatures, but do not enforce them. ENFORCE, // Request install signatures, and enforce them. + + // This is used in histograms - do not remove or reorder entries above! Also + // the "MAX" item below should always be the last element. + + VERIFY_STATUS_MAX }; #if defined(GOOGLE_CHROME_BUILD) @@ -49,7 +54,7 @@ VerifyStatus GetExperimentStatus() { return ENFORCE; } - VerifyStatus default_status = BOOTSTRAP; + VerifyStatus default_status = NONE; if (group == "Enforce") return ENFORCE; @@ -141,6 +146,11 @@ bool InstallVerifier::NeedsVerification(const Extension& extension) { } void InstallVerifier::Init() { + UMA_HISTOGRAM_ENUMERATION("ExtensionInstallVerifier.ExperimentStatus", + GetExperimentStatus(), VERIFY_STATUS_MAX); + UMA_HISTOGRAM_ENUMERATION("ExtensionInstallVerifier.ActualStatus", + GetStatus(), VERIFY_STATUS_MAX); + const base::DictionaryValue* pref = prefs_->GetInstallSignature(); if (pref) { scoped_ptr<InstallSignature> signature_from_prefs = |