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

Unified Diff: net/quic/quic_config.cc

Issue 610073002: Change the pre-handshake idle timeout to 5s from 120s, and the default (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@Add_a_convenience_method_76423808
Patch Set: Created 6 years, 3 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
« no previous file with comments | « net/quic/quic_config.h ('k') | net/quic/quic_connection.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: net/quic/quic_config.cc
diff --git a/net/quic/quic_config.cc b/net/quic/quic_config.cc
index 82d22fbf8f8670f1a74de072b1a771a0d231c8aa..55ea08271e167a3d43043ce96d3691386ef93f5c 100644
--- a/net/quic/quic_config.cc
+++ b/net/quic/quic_config.cc
@@ -425,12 +425,13 @@ QuicErrorCode QuicFixedTagVector::ProcessPeerHello(
}
QuicConfig::QuicConfig()
- : congestion_feedback_(kCGST, PRESENCE_REQUIRED),
+ : max_time_before_crypto_handshake_(QuicTime::Delta::Zero()),
+ max_idle_time_before_crypto_handshake_(QuicTime::Delta::Zero()),
+ congestion_feedback_(kCGST, PRESENCE_REQUIRED),
connection_options_(kCOPT, PRESENCE_OPTIONAL),
idle_connection_state_lifetime_seconds_(kICSL, PRESENCE_REQUIRED),
keepalive_timeout_seconds_(kKATO, PRESENCE_OPTIONAL),
max_streams_per_connection_(kMSPC, PRESENCE_REQUIRED),
- max_time_before_crypto_handshake_(QuicTime::Delta::Zero()),
initial_congestion_window_(kSWND, PRESENCE_OPTIONAL),
initial_round_trip_time_us_(kIRTT, PRESENCE_OPTIONAL),
// TODO(rjshade): Remove this when retiring QUIC_VERSION_19.
@@ -504,15 +505,6 @@ uint32 QuicConfig::MaxStreamsPerConnection() const {
return max_streams_per_connection_.GetUint32();
}
-void QuicConfig::set_max_time_before_crypto_handshake(
- QuicTime::Delta max_time_before_crypto_handshake) {
- max_time_before_crypto_handshake_ = max_time_before_crypto_handshake;
-}
-
-QuicTime::Delta QuicConfig::max_time_before_crypto_handshake() const {
- return max_time_before_crypto_handshake_;
-}
-
void QuicConfig::SetInitialCongestionWindowToSend(size_t initial_window) {
initial_congestion_window_.SetSendValue(initial_window);
}
@@ -627,7 +619,7 @@ uint32 QuicConfig::ReceivedSocketReceiveBuffer() const {
return socket_receive_buffer_.GetReceivedValue();
}
-bool QuicConfig::negotiated() {
+bool QuicConfig::negotiated() const {
// TODO(ianswett): Add the negotiated parameters once and iterate over all
// of them in negotiated, ToHandshakeMessage, ProcessClientHello, and
// ProcessServerHello.
@@ -642,13 +634,15 @@ void QuicConfig::SetDefaults() {
congestion_feedback.push_back(kQBIC);
congestion_feedback_.set(congestion_feedback, kQBIC);
idle_connection_state_lifetime_seconds_.set(kMaximumIdleTimeoutSecs,
- kDefaultInitialTimeoutSecs);
+ kDefaultIdleTimeoutSecs);
// kKATO is optional. Return 0 if not negotiated.
keepalive_timeout_seconds_.set(0, 0);
SetMaxStreamsPerConnection(kDefaultMaxStreamsPerConnection,
kDefaultMaxStreamsPerConnection);
- max_time_before_crypto_handshake_ = QuicTime::Delta::FromSeconds(
- kDefaultMaxTimeForCryptoHandshakeSecs);
+ max_time_before_crypto_handshake_ =
+ QuicTime::Delta::FromSeconds(kMaxTimeForCryptoHandshakeSecs);
+ max_idle_time_before_crypto_handshake_ =
+ QuicTime::Delta::FromSeconds(kInitialIdleTimeoutSecs);
SetInitialFlowControlWindowToSend(kDefaultFlowControlSendWindow);
SetInitialStreamFlowControlWindowToSend(kDefaultFlowControlSendWindow);
« no previous file with comments | « net/quic/quic_config.h ('k') | net/quic/quic_connection.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698