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

Unified Diff: components/data_reduction_proxy/core/browser/data_reduction_proxy_metrics.h

Issue 2249903004: Adding a DataSavingsRecorder interface (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: bengr comments Created 4 years, 4 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/core/browser/data_reduction_proxy_metrics.h
diff --git a/components/data_reduction_proxy/core/browser/data_reduction_proxy_metrics.h b/components/data_reduction_proxy/core/browser/data_reduction_proxy_metrics.h
index fb91fd35e0146fc1695ca8b9f7e2b1fd02b73c58..26f40fb9780b20380a460894282323d0590d78b6 100644
--- a/components/data_reduction_proxy/core/browser/data_reduction_proxy_metrics.h
+++ b/components/data_reduction_proxy/core/browser/data_reduction_proxy_metrics.h
@@ -2,21 +2,20 @@
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
#ifndef COMPONENTS_DATA_REDUCTION_PROXY_CORE_BROWSER_DATA_REDUCTION_PROXY_METRICS_H_
#define COMPONENTS_DATA_REDUCTION_PROXY_CORE_BROWSER_DATA_REDUCTION_PROXY_METRICS_H_
#include <stdint.h>
#include <vector>
-
namespace net {
class ProxyConfig;
class URLRequest;
}
class PrefService;
namespace data_reduction_proxy {
typedef std::vector<long long> ContentLengthList;
@@ -31,27 +30,27 @@ const unsigned int kNumDaysInHistory = 60;
// The number of days of bandwidth usage statistics that are presented.
const unsigned int kNumDaysInHistorySummary = 30;
static_assert(kNumDaysInHistorySummary <= kNumDaysInHistory,
"kNumDaysInHistorySummary should be no larger than "
"kNumDaysInHistory");
enum DataReductionProxyRequestType {
VIA_DATA_REDUCTION_PROXY, // A request served by the data reduction proxy.
-
// Below are reasons why a request is not served by the enabled data reduction
// proxy. Off-the-record profile data is not counted in all cases.
- HTTPS, // An https request.
+ HTTPS, // An https request.
SHORT_BYPASS, // The client is bypassed by the proxy for a short time.
- LONG_BYPASS, // The client is bypassed by the proxy for a long time (due
- // to country bypass policy, for example).
+ LONG_BYPASS, // The client is bypassed by the proxy for a long time (due
+ // to country bypass policy, for example).
+ UPDATE, // An update to already counted request data.
UNKNOWN_TYPE, // Any other reason not listed above.
};
// Returns DataReductionProxyRequestType for |request|.
DataReductionProxyRequestType GetDataReductionProxyRequestType(
const net::URLRequest& request,
const net::ProxyConfig& data_reduction_proxy_config,
const DataReductionProxyConfig& config);
// Returns |received_content_length| as adjusted original content length if

Powered by Google App Engine
This is Rietveld 408576698