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

Unified Diff: components/metrics/net/net_metrics_log_uploader.cc

Issue 1330443002: Report data usage UMA for Chrome services (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@NewArchServices
Patch Set: Fix calling Init function in sync_client.cc Created 5 years, 3 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 | « components/metrics/net/DEPS ('k') | components/omnibox.gypi » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: components/metrics/net/net_metrics_log_uploader.cc
diff --git a/components/metrics/net/net_metrics_log_uploader.cc b/components/metrics/net/net_metrics_log_uploader.cc
index 3ccdf5cb0d3ec9bcf3775a13411f9b747901cae4..0ded667b78783bc71a0deb3ec851db8a53faf4cc 100644
--- a/components/metrics/net/net_metrics_log_uploader.cc
+++ b/components/metrics/net/net_metrics_log_uploader.cc
@@ -5,6 +5,7 @@
#include "components/metrics/net/net_metrics_log_uploader.h"
#include "base/metrics/histogram_macros.h"
+#include "components/data_use_measurement/core/data_use_user_data.h"
#include "net/base/load_flags.h"
#include "net/base/network_change_notifier.h"
#include "net/url_request/url_fetcher.h"
@@ -41,6 +42,8 @@ void NetMetricsLogUploader::UploadLog(const std::string& compressed_log_data,
const std::string& log_hash) {
current_fetch_ =
net::URLFetcher::Create(GURL(server_url_), net::URLFetcher::POST, this);
+ data_use_measurement::DataUseUserData::AttachToFetcher(
+ current_fetch_.get(), data_use_measurement::DataUseUserData::UMA);
current_fetch_->SetRequestContext(request_context_getter_);
current_fetch_->SetUploadData(mime_type_, compressed_log_data);
« no previous file with comments | « components/metrics/net/DEPS ('k') | components/omnibox.gypi » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698