From 23ad228310cd28c0b650661687613d051807985a Mon Sep 17 00:00:00 2001 From: Folke Behrens Date: Fri, 21 Mar 2025 14:21:53 +0000 Subject: [PATCH] pgxn: Increase the pageserver response timeout a bit (#11339) Increase the PS response timeout slightly but noticeably, so it does not coincide with the default TCP_RTO_MAX. --- pgxn/neon/libpagestore.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/pgxn/neon/libpagestore.c b/pgxn/neon/libpagestore.c index 511790ccb0..20f4d462c0 100644 --- a/pgxn/neon/libpagestore.c +++ b/pgxn/neon/libpagestore.c @@ -82,7 +82,8 @@ static int max_reconnect_attempts = 60; static int stripe_size; static int pageserver_response_log_timeout = 10000; -static int pageserver_response_disconnect_timeout = 120000; /* 2 minutes */ +/* 2.5 minutes. A bit higher than highest default TCP retransmission timeout */ +static int pageserver_response_disconnect_timeout = 150000; typedef struct { @@ -1450,7 +1451,7 @@ pg_init_libpagestore(void) "If the pageserver doesn't respond to a request within this timeout, " "disconnect and reconnect.", &pageserver_response_disconnect_timeout, - 120000, 100, INT_MAX, + 150000, 100, INT_MAX, PGC_SUSET, GUC_UNIT_MS, NULL, NULL, NULL);