Index: sync/engine/net/server_connection_manager.h |
diff --git a/sync/engine/net/server_connection_manager.h b/sync/engine/net/server_connection_manager.h |
index 917d5b427c699a4ad29bf52095cc90eda68a9767..76609f984136f8ead5ffd383a3e81a6ec09b1e05 100644 |
--- a/sync/engine/net/server_connection_manager.h |
+++ b/sync/engine/net/server_connection_manager.h |
@@ -225,10 +225,12 @@ class SYNC_EXPORT_PRIVATE ServerConnectionManager { |
} |
// Returns true if the auth token is succesfully set and false otherwise. |
- bool set_auth_token(const std::string& auth_token) { |
+ bool set_auth_token(const std::string& auth_token, |
tim (not reviewing)
2013/05/03 00:46:43
This method should be renamed as per style guide (
Nicolas Zea
2013/05/03 01:31:41
Done.
|
+ const base::Time& auth_token_time) { |
DCHECK(thread_checker_.CalledOnValidThread()); |
if (previously_invalidated_token != auth_token) { |
auth_token_.assign(auth_token); |
+ auth_token_time_ = auth_token_time; |
previously_invalidated_token = std::string(); |
return true; |
} |
@@ -299,6 +301,10 @@ class SYNC_EXPORT_PRIVATE ServerConnectionManager { |
// The auth token to use in authenticated requests. |
std::string auth_token_; |
+ // The time at which this auth token was last created/refreshed. |
+ // Used for histogramming. |
+ base::Time auth_token_time_; |
+ |
// The previous auth token that is invalid now. |
std::string previously_invalidated_token; |