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

Unified Diff: google_apis/gcm/engine/connection_event_tracker.cc

Issue 2594373002: Add PendingEvents UMA to ConnectionEventTracker shutdown. (Closed)
Patch Set: Created 4 years ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | tools/metrics/histograms/histograms.xml » ('j') | tools/metrics/histograms/histograms.xml » ('J')
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: google_apis/gcm/engine/connection_event_tracker.cc
diff --git a/google_apis/gcm/engine/connection_event_tracker.cc b/google_apis/gcm/engine/connection_event_tracker.cc
index d8c3313135f23abc256bb807c1b535449a61d483..b76921599a29bc18d1f6ecb1de2e8bc6ed7c8e9f 100644
--- a/google_apis/gcm/engine/connection_event_tracker.cc
+++ b/google_apis/gcm/engine/connection_event_tracker.cc
@@ -4,6 +4,7 @@
#include "google_apis/gcm/engine/connection_event_tracker.h"
+#include "base/metrics/histogram_macros.h"
#include "base/time/time.h"
#include "net/base/network_change_notifier.h"
@@ -19,7 +20,10 @@ namespace gcm {
ConnectionEventTracker::ConnectionEventTracker() = default;
-ConnectionEventTracker::~ConnectionEventTracker() = default;
+ConnectionEventTracker::~ConnectionEventTracker() {
+ UMA_HISTOGRAM_ENUMERATION("GCM.PendingEvents", completed_events_.size(),
Peter Beverloo 2016/12/22 11:24:36 Let's call this PendingConnectionEventsAtShutdown?
harkness 2016/12/23 13:52:56 Done.
+ kMaxClientEvents + 1);
+}
void ConnectionEventTracker::StartConnectionAttempt() {
// TODO(harkness): Can we dcheck here that there is not an in progress
« no previous file with comments | « no previous file | tools/metrics/histograms/histograms.xml » ('j') | tools/metrics/histograms/histograms.xml » ('J')

Powered by Google App Engine
This is Rietveld 408576698