[GCM] Reset store on checkin rejection and add checkin state to internals
First, this now handles cases where checkin is rejected for a non-retryable
reason by resetting the GCM store. UMA data shows that this is happening
less than 1% of the time, and likely implies profile corruption. Currently
we do not have any way to recover from this state.
Secondly, to help diagnose other checkin issues, I've also added checkin
information to chrome://gcm-internals. Namely last checkin time and next
scheduled checkin time. Recording is now on by default to make it easier
to record checkin events.
BUG=659373
Review-Url: https://codereview.chromium.org/2450383003
Cr-Commit-Position: refs/heads/master@{#429033}
diff --git a/components/gcm_driver/gcm_client.h b/components/gcm_driver/gcm_client.h
index 3e399c56..b3f6543 100644
--- a/components/gcm_driver/gcm_client.h
+++ b/components/gcm_driver/gcm_client.h
@@ -124,6 +124,8 @@
std::string gcm_client_state;
bool connection_client_created;
std::string connection_state;
+ base::Time last_checkin;
+ base::Time next_checkin;
uint64_t android_id;
std::vector<std::string> registered_app_ids;
int send_queue_size;