From 2faae8c8538c02662b996cd2a16c3a2225ebcbc0 Mon Sep 17 00:00:00 2001 From: Adam Tucker Date: Mon, 15 Apr 2024 17:45:22 -0600 Subject: [PATCH] Merge pull request #21 from osmosis-labs/adam/downstream-websocket-log-noise fix(rpc): Make websocket's log on success be in Debug, not info (#2788) --- .../unreleased/improvements/2788-move-ws-info-log-to-debug | 1 + CHANGELOG.md | 2 ++ rpc/jsonrpc/server/ws_handler.go | 2 +- 3 files changed, 4 insertions(+), 1 deletion(-) create mode 100644 .changelog/unreleased/improvements/2788-move-ws-info-log-to-debug diff --git a/.changelog/unreleased/improvements/2788-move-ws-info-log-to-debug b/.changelog/unreleased/improvements/2788-move-ws-info-log-to-debug new file mode 100644 index 00000000000..7e5012e823d --- /dev/null +++ b/.changelog/unreleased/improvements/2788-move-ws-info-log-to-debug @@ -0,0 +1 @@ +Move the websockets info log for successful replies to debug. diff --git a/CHANGELOG.md b/CHANGELOG.md index 89b65f9bef1..42d4143fa17 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -2,6 +2,8 @@ ## Unreleased +* [#21](https://github.com/osmosis-labs/cometbft/pull/21) Move websocket logs to Debug + ## v0.37.4-v24-osmo-2 * [#20](https://github.com/osmosis-labs/cometbft/pull/20) Fix the rollback command diff --git a/rpc/jsonrpc/server/ws_handler.go b/rpc/jsonrpc/server/ws_handler.go index 8e07d68dd7a..844fb86f4fb 100644 --- a/rpc/jsonrpc/server/ws_handler.go +++ b/rpc/jsonrpc/server/ws_handler.go @@ -381,7 +381,7 @@ func (wsc *wsConnection) readRoutine() { returns := rpcFunc.f.Call(args) // TODO: Need to encode args/returns to string if we want to log them - wsc.Logger.Info("WSJSONRPC", "method", request.Method) + wsc.Logger.Debug("WSJSONRPC", "method", request.Method) result, err := unreflectResult(returns) if err != nil {