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

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

Issue 270783002: [GCM] Add more UMA to GCM (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Patch to land Created 6 years, 7 months 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 | « google_apis/gcm/engine/checkin_request.h ('k') | google_apis/gcm/engine/registration_request.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: google_apis/gcm/engine/checkin_request.cc
diff --git a/google_apis/gcm/engine/checkin_request.cc b/google_apis/gcm/engine/checkin_request.cc
index aa4665565f0075076a02643fdf8a0264bb514743..7b3ff221b7e3d994b834a290dc7128a5f73cefe2 100644
--- a/google_apis/gcm/engine/checkin_request.cc
+++ b/google_apis/gcm/engine/checkin_request.cc
@@ -144,6 +144,7 @@ void CheckinRequest::Start() {
url_fetcher_->SetRequestContext(request_context_getter_);
url_fetcher_->SetUploadData(kRequestContentType, upload_data);
recorder_->RecordCheckinInitiated(request_info_.android_id);
+ request_start_time_ = base::TimeTicks::Now();
url_fetcher_->Start();
}
@@ -219,6 +220,10 @@ void CheckinRequest::OnURLFetchComplete(const net::URLFetcher* source) {
}
RecordCheckinStatusAndReportUMA(SUCCESS, recorder_, false);
+ UMA_HISTOGRAM_COUNTS("GCM.CheckinRetryCount",
+ backoff_entry_.failure_count());
+ UMA_HISTOGRAM_TIMES("GCM.CheckinCompleteTime",
+ base::TimeTicks::Now() - request_start_time_);
callback_.Run(response_proto);
}
« no previous file with comments | « google_apis/gcm/engine/checkin_request.h ('k') | google_apis/gcm/engine/registration_request.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698