Commit c8589ce7 authored by Robert Sesek's avatar Robert Sesek Committed by Commit Bot

crash_keys: Convert "third-party-modules-*" to the new API.

Bug: 598854
Change-Id: Ice5b1a0166c841393966b91b3ff464421aa1b619
Reviewed-on: https://chromium-review.googlesource.com/794351Reviewed-by: default avatarFinnur Thorarinsson <finnur@chromium.org>
Commit-Queue: Robert Sesek <rsesek@chromium.org>
Cr-Commit-Position: refs/heads/master@{#520581}
parent e736b2ae
......@@ -61,9 +61,6 @@ constexpr char kHungRendererReason[] = "hung-reason";
constexpr char kInputEventFilterSendFailure[] =
"input-event-filter-send-failure";
constexpr char kThirdPartyModulesLoaded[] = "third-party-modules-loaded";
constexpr char kThirdPartyModulesNotLoaded[] = "third-party-modules-not-loaded";
constexpr char kIsEnterpriseManaged[] = "is-enterprise-managed";
constexpr char kViewCount[] = "view-count";
......@@ -114,8 +111,6 @@ size_t RegisterCrashKeysHelper() {
{gpu::crash_keys::kGPUGLContextIsVirtual, kSmallSize},
// browser/:
{kThirdPartyModulesLoaded, kSmallSize},
{kThirdPartyModulesNotLoaded, kSmallSize},
{kIsEnterpriseManaged, kSmallSize},
// content/:
......
......@@ -19,7 +19,6 @@
#include "base/bind.h"
#include "base/command_line.h"
#include "base/debug/crash_logging.h"
#include "base/debug/leak_annotations.h"
#include "base/environment.h"
#include "base/file_version_info.h"
......@@ -40,8 +39,8 @@
#include "chrome/browser/conflicts/enumerate_shell_extensions_win.h"
#include "chrome/browser/net/service_providers_win.h"
#include "chrome/common/chrome_constants.h"
#include "chrome/common/crash_keys.h"
#include "chrome/grit/generated_resources.h"
#include "components/crash/core/common/crash_key.h"
#include "crypto/sha2.h"
#include "ui/base/l10n/l10n_util.h"
......@@ -432,10 +431,13 @@ void ModuleEnumerator::ReportThirdPartyMetrics() {
// Indicate the presence of third party modules in crash data. This allows
// comparing how much third party modules affect crash rates compared to
// the regular user distribution.
base::debug::SetCrashKeyValue(crash_keys::kThirdPartyModulesLoaded,
base::SizeTToString(third_party_loaded));
base::debug::SetCrashKeyValue(crash_keys::kThirdPartyModulesNotLoaded,
base::SizeTToString(third_party_not_loaded));
static crash_reporter::CrashKeyString<32> third_party_loaded_key(
"third-party-modules-loaded");
third_party_loaded_key.Set(base::SizeTToString(third_party_loaded));
static crash_reporter::CrashKeyString<32> third_party_not_loaded_key(
"third-party-modules-not-loaded");
third_party_not_loaded_key.Set(base::SizeTToString(third_party_not_loaded));
// Report back some metrics regarding third party modules and certificates.
UMA_HISTOGRAM_CUSTOM_COUNTS("ThirdPartyModules.Certificates.Total",
......
......@@ -42,9 +42,6 @@ const char kHungRendererOutstandingEventType[] = "hung-outstanding-event-type";
const char kHungRendererLastEventType[] = "hung-last-event-type";
const char kHungRendererReason[] = "hung-reason";
const char kThirdPartyModulesLoaded[] = "third-party-modules-loaded";
const char kThirdPartyModulesNotLoaded[] = "third-party-modules-not-loaded";
const char kIsEnterpriseManaged[] = "is-enterprise-managed";
// Registry values used to determine Chrome's update channel; see
......@@ -144,8 +141,6 @@ size_t RegisterChromeCrashKeys() {
{kHungRendererOutstandingEventType, kSmallSize},
{kHungRendererLastEventType, kSmallSize},
{kHungRendererReason, kSmallSize},
{kThirdPartyModulesLoaded, kSmallSize},
{kThirdPartyModulesNotLoaded, kSmallSize},
{kIsEnterpriseManaged, kSmallSize},
#endif
{kInputEventFilterSendFailure, kSmallSize},
......
......@@ -81,10 +81,6 @@ extern const char kHungRendererOutstandingEventType[];
extern const char kHungRendererLastEventType[];
extern const char kHungRendererReason[];
// Third-party module crash keys are sent only on Windows.
extern const char kThirdPartyModulesLoaded[];
extern const char kThirdPartyModulesNotLoaded[];
// Whether the machine is enterprise managed (only sent on Windows).
extern const char kIsEnterpriseManaged[];
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment