From ab1d2ae340b8f497a7edf920b0c5feea34786c79 Mon Sep 17 00:00:00 2001 From: Xiaolong Chen Date: Thu, 14 Aug 2025 19:52:48 +0800 Subject: [PATCH] Set the read/write buffer size of the sentinel client to 4KiB Signed-off-by: Xiaolong Chen --- sentinel.go | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/sentinel.go b/sentinel.go index 7963a0699..008f23cfe 100644 --- a/sentinel.go +++ b/sentinel.go @@ -201,8 +201,9 @@ func (opt *FailoverOptions) sentinelOptions(addr string) *Options { MinRetryBackoff: opt.MinRetryBackoff, MaxRetryBackoff: opt.MaxRetryBackoff, - ReadBufferSize: opt.ReadBufferSize, - WriteBufferSize: opt.WriteBufferSize, + // The sentinel client uses a 4KiB read/write buffer size. + ReadBufferSize: 4096, + WriteBufferSize: 4096, DialTimeout: opt.DialTimeout, ReadTimeout: opt.ReadTimeout,