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

Unified Diff: google_apis/gcm/gcm_client.h

Issue 202083005: Add activity recording capability to gcm internals page. User can refresh, start/stop recording, an… (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Address all code reviews. Created 6 years, 9 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
Index: google_apis/gcm/gcm_client.h
diff --git a/google_apis/gcm/gcm_client.h b/google_apis/gcm/gcm_client.h
index 0d687120947473d26b8218209dbb45b7b065e63b..6875d8b05b1e19cd81b4760dc693503bc711c427 100644
--- a/google_apis/gcm/gcm_client.h
+++ b/google_apis/gcm/gcm_client.h
@@ -11,6 +11,7 @@
#include "base/basictypes.h"
#include "google_apis/gcm/base/gcm_export.h"
+#include "google_apis/gcm/gcm_stats_recorder.h"
template <class T> class scoped_refptr;
@@ -94,11 +95,17 @@ class GCM_EXPORT GCMClient {
GCMStatistics();
~GCMStatistics();
+ bool is_recording;
bool gcm_client_created;
std::string gcm_client_state;
bool connection_client_created;
std::string connection_state;
uint64 android_id;
+ std::string app_ids_cached;
jianli 2014/03/21 18:25:27 These are indeed ids of apps that call register to
juyik 2014/03/26 04:06:03 Done.
+ int send_queue_size;
+ int unacked_queue_size;
+
+ std::vector<GCMStatsRecorder::SendingActivity> sending;
};
// A delegate interface that allows the GCMClient instance to interact with
@@ -208,6 +215,12 @@ class GCM_EXPORT GCMClient {
const std::string& receiver_id,
const OutgoingMessage& message) = 0;
+ // Enables or disables internal activity recording.
+ virtual void SetRecording(bool recording) = 0;
+
+ // Clear all recorded GCM activity logs.
+ virtual void ClearActivityLogs() = 0;
+
// Gets internal states and statistics.
virtual GCMStatistics GetStatistics() const = 0;
};

Powered by Google App Engine
This is Rietveld 408576698