| Index: chrome/browser/metrics/metrics_service.h
|
| ===================================================================
|
| --- chrome/browser/metrics/metrics_service.h (revision 272759)
|
| +++ chrome/browser/metrics/metrics_service.h (working copy)
|
| @@ -32,7 +32,6 @@
|
| #include "components/metrics/metrics_provider.h"
|
| #include "components/metrics/metrics_service_observer.h"
|
| #include "components/variations/active_field_trials.h"
|
| -#include "net/url_request/url_fetcher_delegate.h"
|
|
|
| class GoogleUpdateMetricsProviderWin;
|
| class MetricsReportingScheduler;
|
| @@ -54,6 +53,7 @@
|
| }
|
|
|
| namespace metrics {
|
| +class MetricsLogUploader;
|
| class MetricsServiceClient;
|
| class MetricsStateManager;
|
| }
|
| @@ -88,8 +88,7 @@
|
|
|
| class MetricsService
|
| : public base::HistogramFlattener,
|
| - public chrome_browser_metrics::TrackingSynchronizerObserver,
|
| - public net::URLFetcherDelegate {
|
| + public chrome_browser_metrics::TrackingSynchronizerObserver {
|
| public:
|
| // The execution phase of the browser.
|
| enum ExecutionPhase {
|
| @@ -357,15 +356,9 @@
|
| // Uploads the currently staged log (which must be non-null).
|
| void SendStagedLog();
|
|
|
| - // Prepared the staged log to be passed to the server. Upon return,
|
| - // current_fetch_ should be reset with its upload data set to a compressed
|
| - // copy of the staged log.
|
| - void PrepareFetchWithStagedLog();
|
| + // Called after transmission completes (either successfully or with failure).
|
| + void OnLogUploadComplete(int response_code);
|
|
|
| - // Implementation of net::URLFetcherDelegate. Called after transmission
|
| - // completes (either successfully or with failure).
|
| - virtual void OnURLFetchComplete(const net::URLFetcher* source) OVERRIDE;
|
| -
|
| // Reads, increments and then sets the specified integer preference.
|
| void IncrementPrefValue(const char* path);
|
|
|
| @@ -457,9 +450,12 @@
|
| // initial stability log may be sent before this.
|
| scoped_ptr<MetricsLog> initial_metrics_log_;
|
|
|
| - // The outstanding transmission appears as a URL Fetch operation.
|
| - scoped_ptr<net::URLFetcher> current_fetch_;
|
| + // Instance of the helper class for uploading logs.
|
| + scoped_ptr<metrics::MetricsLogUploader> log_uploader_;
|
|
|
| + // Whether there is a current log upload in progress.
|
| + bool log_upload_in_progress_;
|
| +
|
| // Whether the MetricsService object has received any notifications since
|
| // the last time a transmission was sent.
|
| bool idle_since_last_transmission_;
|
|
|