increasing max ttl

This commit is contained in:
godmodegalactus 2024-05-29 17:51:11 +02:00
parent f1a877ecfb
commit 9145ee7bc5
No known key found for this signature in database
GPG Key ID: 22DA4A30887FDA3C
3 changed files with 14 additions and 25 deletions

View File

@ -127,7 +127,7 @@ impl Client {
let _ = sender.send(message);
}
Err(e) => {
log::error!("Error getting message {}", e);
log::trace!("Error getting message {}", e);
}
}
});

View File

@ -3,7 +3,7 @@ pub const MAX_ALLOWED_PARTIAL_RESPONSES: usize = 32 * 1024;
pub const DEFAULT_MAX_RECIEVE_WINDOW_SIZE: u64 = 1024 * 1024; // 1 MBs
pub const DEFAULT_CONNECTION_TIMEOUT: u64 = 10;
pub const DEFAULT_MAX_NB_CONNECTIONS: u64 = 10;
pub const DEFAULT_MAX_ACK_DELAY: u64 = 250;
pub const DEFAULT_MAX_ACK_DELAY: u64 = 400;
pub const DEFAULT_ACK_EXPONENT: u64 = 3;
pub const ALPN_GEYSER_PROTOCOL_ID: &[u8] = b"geyser";
pub const MAX_DATAGRAM_SIZE: usize = 1350; // MAX: 65527
pub const MAX_DATAGRAM_SIZE: usize = 2000; // MAX: 65527

View File

@ -299,6 +299,7 @@ pub fn server_loop(
}
}
#[allow(clippy::too_many_arguments)]
fn create_client_task(
connection: quiche::Connection,
receiver: mpsc::Receiver<(quiche::RecvInfo, Vec<u8>)>,
@ -384,16 +385,8 @@ fn create_client_task(
);
}
}
if send_message(
&mut connection,
&mut partial_responses,
stream_id,
&message,
).is_err() {
true
} else {
false
}
send_message(&mut connection, &mut partial_responses, stream_id, &message)
.is_err()
}
Err(e) => {
match e {
@ -406,20 +399,16 @@ fn create_client_task(
}
};
if close && !closed {
if stop_laggy_client && !closed {
if let Err(e) = connection.close(true, 1, b"laggy client") {
if e != quiche::Error::Done {
log::error!("error closing client : {}", e);
}
} else {
log::info!(
"Stopping laggy client : {}",
connection.trace_id(),
);
if close && !closed && stop_laggy_client {
if let Err(e) = connection.close(true, 1, b"laggy client") {
if e != quiche::Error::Done {
log::error!("error closing client : {}", e);
}
closed = true;
} else {
log::info!("Stopping laggy client : {}", connection.trace_id(),);
}
closed = true;
break;
}
}