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

Unified Diff: components/data_reduction_proxy/browser/data_reduction_proxy_usage_stats.h

Issue 568893002: Trigger data reduction proxy unreachable message via on proxy fall back. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 6 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
Index: components/data_reduction_proxy/browser/data_reduction_proxy_usage_stats.h
diff --git a/components/data_reduction_proxy/browser/data_reduction_proxy_usage_stats.h b/components/data_reduction_proxy/browser/data_reduction_proxy_usage_stats.h
index 33fd29e560fa2f533fa044f1c3be60a83537c599..85495cb2efb29f9ebd90012a78eac5e150d3cfcf 100644
--- a/components/data_reduction_proxy/browser/data_reduction_proxy_usage_stats.h
+++ b/components/data_reduction_proxy/browser/data_reduction_proxy_usage_stats.h
@@ -64,8 +64,8 @@ class DataReductionProxyUsageStats
const BooleanPrefMember& data_reduction_proxy_enabled,
const net::ProxyConfig& data_reduction_proxy_config);
- void RecordBypassEventHistograms(const net::ProxyServer& bypassed_proxy,
- int net_error) const;
+ void OnProxyFallback(const net::ProxyServer& bypassed_proxy,
bengr 2014/09/16 18:48:57 Please add a comment that describes what this meth
Not at Google. Contact bengr 2014/09/16 19:34:49 Done.
+ int net_error);
private:
enum BypassedBytesType {
@@ -83,9 +83,6 @@ class DataReductionProxyUsageStats
virtual void OnNetworkChanged(
net::NetworkChangeNotifier::ConnectionType type) OVERRIDE;
- // Counts requests that went through the data reduction proxy and counts
- // requests that were eligible to go through the proxy.
- void IncrementRequestCounts(bool actual);
void ClearRequestCounts();
// Checks if the availability status of the data reduction proxy has changed,
@@ -110,14 +107,12 @@ class DataReductionProxyUsageStats
// unreachable if no successful requests are made through it despite a
// non-zero number of requests being eligible.
- // Count of requests which will be tried to be sent through data reduction
- // proxy. The count is only based on the config and not the bad proxy list.
- // Explicit bypasses are not part of this count. This is the desired behavior
- // since otherwise both counts would be identical.
- unsigned long eligible_num_requests_through_proxy_;
-
// Count of successful requests through data reduction proxy.
- unsigned long actual_num_requests_through_proxy_;
+ unsigned long num_successful_requests_through_proxy_;
+
+ // Count of network errors encountered when connecting to a data reduction
+ // proxy.
+ unsigned long num_proxy_net_errors_;
// Whether or not the data reduction proxy is unavailable.
bool unavailable_;

Powered by Google App Engine
This is Rietveld 408576698