From 6f99663b3bb713bff12025cd46793727cc1c9dff Mon Sep 17 00:00:00 2001 From: HAOYUatHZ <37070449+HAOYUatHZ@users.noreply.github.com> Date: Mon, 20 Nov 2023 15:34:59 +0800 Subject: [PATCH] =?UTF-8?q?feat(ws):=20increase=20`wsReadBuffer`,=20`wsWri?= =?UTF-8?q?teBuffer`=20&=20`wsMessageSizeLi=E2=80=A6=20(#568)?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit feat(ws): increase `wsReadBuffer`, `wsWriteBuffer` & `wsMessageSizeLimit` --- rpc/websocket.go | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/rpc/websocket.go b/rpc/websocket.go index 538e53a31b..23c97c89f7 100644 --- a/rpc/websocket.go +++ b/rpc/websocket.go @@ -33,12 +33,12 @@ import ( ) const ( - wsReadBuffer = 1024 - wsWriteBuffer = 1024 + wsReadBuffer = 3 * 1024 + wsWriteBuffer = 3 * 1024 wsPingInterval = 30 * time.Second wsPingWriteTimeout = 5 * time.Second wsPongTimeout = 30 * time.Second - wsDefaultReadLimit = 32 * 1024 * 1024 + wsDefaultReadLimit = 5 * 32 * 1024 * 1024 ) var wsBufferPool = new(sync.Pool)