| 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 22d47ed1172fd7eaea84c1a383791b9f33d24ccb..85dd909182b7a75a2a0be64629d3fb8756f2a3aa 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
|
| @@ -5,7 +5,9 @@
|
| #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 "base/time/time.h"
|
| +#include <vector>
|
| +
|
| +#include "base/basictypes.h"
|
|
|
| namespace net {
|
| class ProxyConfig;
|
| @@ -16,8 +18,22 @@ class PrefService;
|
|
|
| namespace data_reduction_proxy {
|
|
|
| +typedef std::vector<long long> ContentLengthList;
|
| +
|
| class DataReductionProxyConfig;
|
| -class DataReductionProxyCompressionStats;
|
| +
|
| +// A bypass delay more than this is treated as a long delay.
|
| +const int kLongBypassDelayInSeconds = 30 * 60;
|
| +
|
| +// The number of days of bandwidth usage statistics that are tracked.
|
| +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.
|
| @@ -45,16 +61,6 @@ int64 GetAdjustedOriginalContentLength(
|
| int64 original_content_length,
|
| int64 received_content_length);
|
|
|
| -// This is only exposed for testing. It is normally called by
|
| -// UpdateContentLengthPrefs.
|
| -void UpdateContentLengthPrefsForDataReductionProxy(
|
| - int received_content_length,
|
| - int original_content_length,
|
| - bool with_data_reduction_proxy_enabled,
|
| - DataReductionProxyRequestType request_type,
|
| - base::Time now,
|
| - DataReductionProxyCompressionStats* compression_stats);
|
| -
|
| } // namespace data_reduction_proxy
|
|
|
| #endif // COMPONENTS_DATA_REDUCTION_PROXY_CORE_BROWSER_DATA_REDUCTION_PROXY_METRICS_H_
|
|
|