Skip to content

Commit

Permalink
feat: misc logging improvements for fallback mode (ethereum-optimism#…
Browse files Browse the repository at this point in the history
  • Loading branch information
jelias2 authored and rdovgan committed Jun 24, 2024
1 parent f023ec7 commit 3d69961
Showing 1 changed file with 6 additions and 1 deletion.
7 changes: 6 additions & 1 deletion proxyd/consensus_poller.go
Original file line number Diff line number Diff line change
Expand Up @@ -150,7 +150,7 @@ func (ah *PollerAsyncHandler) Init() {

log.Info("number of healthy primary candidates", "healthy_candidates", len(healthyCandidates))
if len(healthyCandidates) == 0 {
log.Info("zero healthy candidates, querying fallback backend",
log.Debug("zero healthy candidates, querying fallback backend",
"backend_name", be.Name)
ah.cp.UpdateBackend(ah.ctx, be)
}
Expand Down Expand Up @@ -703,6 +703,11 @@ func (cp *ConsensusPoller) FilterCandidates(backends []*Backend) map[*Backend]*b
continue
}
if !be.skipPeerCountCheck && bs.peerCount < cp.minPeerCount {
log.Debug("backend peer count too low for inclusion in consensus",
"backend_name", be.Name,
"peer_count", bs.peerCount,
"min_peer_count", cp.minPeerCount,
)
continue
}
if !bs.inSync {
Expand Down

0 comments on commit 3d69961

Please sign in to comment.