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

Unified Diff: components/data_reduction_proxy/browser/data_reduction_proxy_params.cc

Issue 388663002: Added data reduction proxy holdback experiment (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: rebase Created 6 years, 5 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_params.cc
diff --git a/components/data_reduction_proxy/browser/data_reduction_proxy_params.cc b/components/data_reduction_proxy/browser/data_reduction_proxy_params.cc
index 64b2ec1040c4cc533310f3826651f2c22525cdbd..7bba0edf1c66a1f8c210ea0f7212547769bbcd58 100644
--- a/components/data_reduction_proxy/browser/data_reduction_proxy_params.cc
+++ b/components/data_reduction_proxy/browser/data_reduction_proxy_params.cc
@@ -52,11 +52,17 @@ bool DataReductionProxyParams::IsIncludedInCriticalPathBypassFieldTrial() {
"DataCompressionProxyCriticalBypass") == kEnabled;
}
+bool DataReductionProxyParams::IsIncludedInHoldbackFieldTrial() {
+ return FieldTrialList::FindFullName(
+ "DataCompressionProxyHoldback") == kEnabled;
+}
+
DataReductionProxyParams::DataReductionProxyParams(int flags)
: allowed_((flags & kAllowed) == kAllowed),
fallback_allowed_((flags & kFallbackAllowed) == kFallbackAllowed),
alt_allowed_((flags & kAlternativeAllowed) == kAlternativeAllowed),
promo_allowed_((flags & kPromoAllowed) == kPromoAllowed),
+ holdback_((flags & kHoldback) == kHoldback),
configured_on_command_line_(false) {
bool result = Init(allowed_, fallback_allowed_, alt_allowed_);
DCHECK(result);
@@ -92,6 +98,7 @@ DataReductionProxyParams::DataReductionProxyParams(int flags,
fallback_allowed_((flags & kFallbackAllowed) == kFallbackAllowed),
alt_allowed_((flags & kAlternativeAllowed) == kAlternativeAllowed),
promo_allowed_((flags & kPromoAllowed) == kPromoAllowed),
+ holdback_((flags & kHoldback) == kHoldback),
configured_on_command_line_(false) {
if (should_call_init) {
bool result = Init(allowed_, fallback_allowed_, alt_allowed_);

Powered by Google App Engine
This is Rietveld 408576698