From 68339d86b964944375f13b154f5c7428702e0f72 Mon Sep 17 00:00:00 2001 From: Fintan Halpenny Date: Thu, 7 Mar 2024 11:24:36 +0000 Subject: [PATCH] node: increase timeouts For larger fetches, a timeout for the channels and socket control are required. Bump the timeout from 9s to 30s. Signed-off-by: Fintan Halpenny X-Clacks-Overhead: GNU Terry Pratchett --- radicle-node/src/wire/protocol.rs | 2 +- radicle/src/node.rs | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/radicle-node/src/wire/protocol.rs b/radicle-node/src/wire/protocol.rs index e0de9714..e68e8288 100644 --- a/radicle-node/src/wire/protocol.rs +++ b/radicle-node/src/wire/protocol.rs @@ -44,7 +44,7 @@ pub const NOISE_XK: HandshakePattern = HandshakePattern { /// Default time to wait to receive something from a worker channel. Applies to /// workers waiting for data from remotes as well. -pub const DEFAULT_CHANNEL_TIMEOUT: time::Duration = time::Duration::from_secs(9); +pub const DEFAULT_CHANNEL_TIMEOUT: time::Duration = time::Duration::from_secs(30); /// Default time to wait until a network connection is considered inactive. pub const DEFAULT_CONNECTION_TIMEOUT: time::Duration = time::Duration::from_secs(30); diff --git a/radicle/src/node.rs b/radicle/src/node.rs index a61b1c89..96d476af 100644 --- a/radicle/src/node.rs +++ b/radicle/src/node.rs @@ -46,7 +46,7 @@ pub const DEFAULT_SOCKET_NAME: &str = "control.sock"; /// Default radicle protocol port. pub const DEFAULT_PORT: u16 = 8776; /// Default timeout when waiting for the node to respond with data. -pub const DEFAULT_TIMEOUT: time::Duration = time::Duration::from_secs(9); +pub const DEFAULT_TIMEOUT: time::Duration = time::Duration::from_secs(30); /// Maximum length in bytes of a node alias. pub const MAX_ALIAS_LENGTH: usize = 32; /// Penalty threshold at which point we avoid connecting to this node.