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

Unified Diff: components/metrics/net/network_metrics_provider.h

Issue 1796983002: Log aggregated abort metrics when histograms are uploaded (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: isherman@ review Created 4 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
« no previous file with comments | « no previous file | components/metrics/net/network_metrics_provider.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: components/metrics/net/network_metrics_provider.h
diff --git a/components/metrics/net/network_metrics_provider.h b/components/metrics/net/network_metrics_provider.h
index e1f02ddf3647bcc8668145829949b889e51cbd45..5dbb5593b2491b0e358b6eeb1b3f72551b5c277a 100644
--- a/components/metrics/net/network_metrics_provider.h
+++ b/components/metrics/net/network_metrics_provider.h
@@ -8,6 +8,7 @@
#include "base/macros.h"
#include "base/memory/scoped_ptr.h"
#include "base/memory/weak_ptr.h"
+#include "base/metrics/histogram_base.h"
#include "components/metrics/metrics_provider.h"
#include "components/metrics/net/wifi_access_point_info_provider.h"
#include "components/metrics/proto/system_profile.pb.h"
@@ -52,6 +53,9 @@ class NetworkMetricsProvider
const WifiAccessPointInfoProvider::WifiAccessPointInfo& info,
SystemProfileProto::Network* network_proto);
+ // Logs metrics that are functions of other metrics being uploaded.
+ void LogAggregatedMetrics();
+
// Task runner used for blocking file I/O.
base::TaskRunner* io_task_runner_;
@@ -69,6 +73,11 @@ class NetworkMetricsProvider
// Helper object for retrieving connected wifi access point information.
scoped_ptr<WifiAccessPointInfoProvider> wifi_access_point_info_provider_;
+ // These metrics track histogram totals for the Net.ErrorCodesForMainFrame3
+ // histogram. They are used to compute deltas at upload time.
+ base::HistogramBase::Count total_aborts_;
+ base::HistogramBase::Count total_codes_;
+
base::WeakPtrFactory<NetworkMetricsProvider> weak_ptr_factory_;
DISALLOW_COPY_AND_ASSIGN(NetworkMetricsProvider);
« no previous file with comments | « no previous file | components/metrics/net/network_metrics_provider.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698