From 6030a62cf069f233a6e0822ee5b4913b304689f6 Mon Sep 17 00:00:00 2001 From: c9s Date: Wed, 29 Dec 2021 17:28:45 +0800 Subject: [PATCH] change to debug level message --- pkg/exchange/binance/stream.go | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/pkg/exchange/binance/stream.go b/pkg/exchange/binance/stream.go index 3a8f74c32..f87bbb157 100644 --- a/pkg/exchange/binance/stream.go +++ b/pkg/exchange/binance/stream.go @@ -309,6 +309,7 @@ func (s *Stream) dial(listenKey string) (*websocket.Conn, error) { // Unsolicited pong frames are allowed. conn.SetPingHandler(nil) conn.SetPongHandler(func(string) error { + log.Debugf("websocket <- received pong") if err := conn.SetReadDeadline(time.Now().Add(readTimeout * 2)); err != nil { log.WithError(err).Error("pong handler can not set read deadline") } @@ -451,7 +452,7 @@ func (s *Stream) ping(ctx context.Context) { conn := s.Conn s.ConnLock.Unlock() - log.Infof("websocket ping") + log.Debugf("websocket -> ping") if err := conn.WriteControl(websocket.PingMessage, nil, time.Now().Add(writeTimeout)); err != nil { log.WithError(err).Error("ping error", err) s.Reconnect()