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

Unified Diff: net/quic/quic_stream_factory.cc

Issue 346043002: Add support for setting QUIC connection options via field trial config. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Fix comments Created 6 years, 6 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: net/quic/quic_stream_factory.cc
diff --git a/net/quic/quic_stream_factory.cc b/net/quic/quic_stream_factory.cc
index dd17924503a58deb2eb72c9ccfaa9ed1e9af931b..a0e502118ca62a78632a0959393b1e59ddb43a34 100644
--- a/net/quic/quic_stream_factory.cc
+++ b/net/quic/quic_stream_factory.cc
@@ -85,7 +85,8 @@ bool IsEcdsaSupported() {
}
QuicConfig InitializeQuicConfig(bool enable_pacing,
- bool enable_time_based_loss_detection) {
+ bool enable_time_based_loss_detection,
+ QuicTagVector connection_options) {
QuicConfig config;
config.SetDefaults();
config.EnablePacing(enable_pacing);
@@ -94,6 +95,7 @@ QuicConfig InitializeQuicConfig(bool enable_pacing,
config.set_idle_connection_state_lifetime(
QuicTime::Delta::FromSeconds(kIdleConnectionTimeoutSeconds),
QuicTime::Delta::FromSeconds(kIdleConnectionTimeoutSeconds));
+ config.SetCongestionOptionsToSend(connection_options);
return config;
}
@@ -458,7 +460,8 @@ QuicStreamFactory::QuicStreamFactory(
const QuicVersionVector& supported_versions,
bool enable_port_selection,
bool enable_pacing,
- bool enable_time_based_loss_detection)
+ bool enable_time_based_loss_detection,
+ QuicTagVector connection_options)
: require_confirmation_(true),
host_resolver_(host_resolver),
client_socket_factory_(client_socket_factory),
@@ -470,7 +473,8 @@ QuicStreamFactory::QuicStreamFactory(
clock_(clock),
max_packet_length_(max_packet_length),
config_(InitializeQuicConfig(enable_pacing,
- enable_time_based_loss_detection)),
+ enable_time_based_loss_detection,
+ connection_options)),
supported_versions_(supported_versions),
enable_port_selection_(enable_port_selection),
port_seed_(random_generator_->RandUint64()),

Powered by Google App Engine
This is Rietveld 408576698