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

Side by Side Diff: chrome/browser/io_thread.cc

Issue 1973403002: QUIC - Add back to code to experiment with delay_tcp_race. By default, (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 years, 7 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 unified diff | Download patch
« no previous file with comments | « chrome/browser/io_thread.h ('k') | chrome/browser/io_thread_unittest.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "chrome/browser/io_thread.h" 5 #include "chrome/browser/io_thread.h"
6 6
7 #include <utility> 7 #include <utility>
8 #include <vector> 8 #include <vector>
9 9
10 #include "base/base64.h" 10 #include "base/base64.h"
(...skipping 1181 matching lines...) Expand 10 before | Expand all | Expand 10 after
1192 1192
1193 if (params->enable_quic) { 1193 if (params->enable_quic) {
1194 params->quic_always_require_handshake_confirmation = 1194 params->quic_always_require_handshake_confirmation =
1195 ShouldQuicAlwaysRequireHandshakeConfirmation(quic_trial_params); 1195 ShouldQuicAlwaysRequireHandshakeConfirmation(quic_trial_params);
1196 params->quic_disable_connection_pooling = 1196 params->quic_disable_connection_pooling =
1197 ShouldQuicDisableConnectionPooling(quic_trial_params); 1197 ShouldQuicDisableConnectionPooling(quic_trial_params);
1198 int receive_buffer_size = GetQuicSocketReceiveBufferSize(quic_trial_params); 1198 int receive_buffer_size = GetQuicSocketReceiveBufferSize(quic_trial_params);
1199 if (receive_buffer_size != 0) { 1199 if (receive_buffer_size != 0) {
1200 params->quic_socket_receive_buffer_size = receive_buffer_size; 1200 params->quic_socket_receive_buffer_size = receive_buffer_size;
1201 } 1201 }
1202 params->quic_delay_tcp_race = ShouldQuicDelayTcpRace(quic_trial_params);
1202 float load_server_info_timeout_srtt_multiplier = 1203 float load_server_info_timeout_srtt_multiplier =
1203 GetQuicLoadServerInfoTimeoutSrttMultiplier(quic_trial_params); 1204 GetQuicLoadServerInfoTimeoutSrttMultiplier(quic_trial_params);
1204 if (load_server_info_timeout_srtt_multiplier != 0) { 1205 if (load_server_info_timeout_srtt_multiplier != 0) {
1205 params->quic_load_server_info_timeout_srtt_multiplier = 1206 params->quic_load_server_info_timeout_srtt_multiplier =
1206 load_server_info_timeout_srtt_multiplier; 1207 load_server_info_timeout_srtt_multiplier;
1207 } 1208 }
1208 params->quic_enable_connection_racing = 1209 params->quic_enable_connection_racing =
1209 ShouldQuicEnableConnectionRacing(quic_trial_params); 1210 ShouldQuicEnableConnectionRacing(quic_trial_params);
1210 params->quic_enable_non_blocking_io = 1211 params->quic_enable_non_blocking_io =
1211 ShouldQuicEnableNonBlockingIO(quic_trial_params); 1212 ShouldQuicEnableNonBlockingIO(quic_trial_params);
(...skipping 229 matching lines...) Expand 10 before | Expand all | Expand 10 after
1441 int value; 1442 int value;
1442 if (base::StringToInt(GetVariationParam(quic_trial_params, 1443 if (base::StringToInt(GetVariationParam(quic_trial_params,
1443 "receive_buffer_size"), 1444 "receive_buffer_size"),
1444 &value)) { 1445 &value)) {
1445 return value; 1446 return value;
1446 } 1447 }
1447 return 0; 1448 return 0;
1448 } 1449 }
1449 1450
1450 // static 1451 // static
1452 bool IOThread::NetworkSessionConfigurator::ShouldQuicDelayTcpRace(
1453 const VariationParameters& quic_trial_params) {
1454 return base::LowerCaseEqualsASCII(
1455 GetVariationParam(quic_trial_params, "delay_tcp_race"), "true");
1456 }
1457
1458 // static
1451 bool IOThread::NetworkSessionConfigurator::ShouldQuicCloseSessionsOnIpChange( 1459 bool IOThread::NetworkSessionConfigurator::ShouldQuicCloseSessionsOnIpChange(
1452 const VariationParameters& quic_trial_params) { 1460 const VariationParameters& quic_trial_params) {
1453 return base::LowerCaseEqualsASCII( 1461 return base::LowerCaseEqualsASCII(
1454 GetVariationParam(quic_trial_params, "close_sessions_on_ip_change"), 1462 GetVariationParam(quic_trial_params, "close_sessions_on_ip_change"),
1455 "true"); 1463 "true");
1456 } 1464 }
1457 1465
1458 // static 1466 // static
1459 int IOThread::NetworkSessionConfigurator::GetQuicIdleConnectionTimeoutSeconds( 1467 int IOThread::NetworkSessionConfigurator::GetQuicIdleConnectionTimeoutSeconds(
1460 const VariationParameters& quic_trial_params) { 1468 const VariationParameters& quic_trial_params) {
(...skipping 238 matching lines...) Expand 10 before | Expand all | Expand 10 after
1699 // TODO(rtenneti): We should probably use HttpServerPropertiesManager for the 1707 // TODO(rtenneti): We should probably use HttpServerPropertiesManager for the
1700 // system URLRequestContext too. There's no reason this should be tied to a 1708 // system URLRequestContext too. There's no reason this should be tied to a
1701 // profile. 1709 // profile.
1702 return context; 1710 return context;
1703 } 1711 }
1704 1712
1705 const metrics::UpdateUsagePrefCallbackType& 1713 const metrics::UpdateUsagePrefCallbackType&
1706 IOThread::GetMetricsDataUseForwarder() { 1714 IOThread::GetMetricsDataUseForwarder() {
1707 return metrics_data_use_forwarder_; 1715 return metrics_data_use_forwarder_;
1708 } 1716 }
OLDNEW
« no previous file with comments | « chrome/browser/io_thread.h ('k') | chrome/browser/io_thread_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698