Skip to content

Commit

Permalink
ci: increase handshake and idle timeouts in qns
Browse files Browse the repository at this point in the history
  • Loading branch information
WesleyRosenblum committed Aug 14, 2023
1 parent c7e3f51 commit 59937c2
Show file tree
Hide file tree
Showing 2 changed files with 13 additions and 1 deletion.
2 changes: 1 addition & 1 deletion quic/s2n-quic-qns/src/client/interop.rs
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@ pub struct Interop {
#[structopt(long, env = "TESTCASE", possible_values = &Testcase::supported(is_supported_testcase))]
testcase: Option<Testcase>,

#[structopt(long, default_value = "10")]
#[structopt(long, default_value = "20")]
concurrency: u64,

#[structopt(min_values = 1, required = true)]
Expand Down
12 changes: 12 additions & 0 deletions quic/s2n-quic-qns/src/limits.rs
Original file line number Diff line number Diff line change
@@ -1,6 +1,8 @@
// Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
// SPDX-License-Identifier: Apache-2.0

use core::time::Duration;

#[derive(Debug, structopt::StructOpt)]
pub struct Limits {
/// The maximum bits/sec for each connection
Expand All @@ -16,6 +18,12 @@ pub struct Limits {
}

impl Limits {
// Increase the MaxHandshakeDuration from the default of 10 seconds
const MAX_HANDSHAKE_DURATION: Duration = Duration::from_secs(30);

// Increase KeepAlivePeriod from the default of 30 seconds
const MAX_KEEP_ALIVE_PERIOD: Duration = Duration::from_secs(60);

pub fn limits(&self) -> s2n_quic::provider::limits::Limits {
let data_window = self.data_window();

Expand All @@ -31,6 +39,10 @@ impl Limits {
.with_bidirectional_remote_data_window(data_window)
.unwrap()
.with_unidirectional_data_window(data_window)
.unwrap()
.with_max_handshake_duration(Self::MAX_HANDSHAKE_DURATION)
.unwrap()
.with_max_keep_alive_period(Self::MAX_KEEP_ALIVE_PERIOD)
.unwrap();

if let Some(size) = self.stream_send_buffer_size {
Expand Down

0 comments on commit 59937c2

Please sign in to comment.