Skip to content

Commit 70874df

Browse files
authored
Reduce logging (#397)
1 parent cc87fc8 commit 70874df

File tree

2 files changed

+5
-5
lines changed

2 files changed

+5
-5
lines changed

service/bfg/bfg.go

+2-2
Original file line numberDiff line numberDiff line change
@@ -305,11 +305,11 @@ func (s *Server) handleRequest(pctx context.Context, bws *bfgWs, wsid string, cm
305305
select {
306306
case <-s.requestLimiter:
307307
default:
308-
log.Infof("Request limiter hit %v: %v", bws.addr, cmd)
308+
log.Tracef("Request limiter hit %v: %v", bws.addr, cmd)
309309
select {
310310
case <-s.requestLimiter:
311311
case <-ctx.Done():
312-
log.Infof("request context done %v: %v", bws.addr, cmd)
312+
log.Debugf("request context done %v: %v", bws.addr, cmd)
313313
return
314314
}
315315
}

service/bss/bss.go

+3-3
Original file line numberDiff line numberDiff line change
@@ -423,7 +423,7 @@ func (s *Server) handleWebsocket(w http.ResponseWriter, r *http.Request) {
423423

424424
log.Tracef("responding with %v", spew.Sdump(ping))
425425
if err := bssapi.Write(r.Context(), bws.conn, "0", ping); err != nil {
426-
log.Errorf("Write: %v", err)
426+
log.Tracef("Write: %v", err)
427427
}
428428

429429
log.Infof("Unauthenticated connection from %v", r.RemoteAddr)
@@ -471,7 +471,7 @@ func (s *Server) deleteSession(id string) {
471471

472472
func writeNotificationResponse(bws *bssWs, response any) {
473473
if err := bssapi.Write(bws.requestContext, bws.conn, "", response); err != nil {
474-
log.Errorf(
474+
log.Tracef(
475475
"handleBtcFinalityNotification write: %v %v",
476476
bws.addr,
477477
err,
@@ -530,7 +530,7 @@ func (s *Server) handleBFGWebsocketReadUnauth(ctx context.Context, conn *protoco
530530
Timestamp: time.Now().Unix(),
531531
}
532532
if err := bfgapi.Write(ctx, conn, rid, response); err != nil {
533-
log.Errorf("handleBFGWebsocketReadUnauth write: %v",
533+
log.Tracef("handleBFGWebsocketReadUnauth write: %v",
534534
err)
535535
}
536536
case bfgapi.CmdBTCFinalityNotification:

0 commit comments

Comments
 (0)