mirror of
https://github.com/paradigmxyz/reth.git
synced 2026-01-11 00:08:13 -05:00
fix(bin): warn about CL health only when pipeline is idle (#4835)
This commit is contained in:
@@ -138,18 +138,22 @@ impl NodeState {
|
||||
}
|
||||
|
||||
fn handle_consensus_layer_health_event(&self, event: ConsensusLayerHealthEvent) {
|
||||
match event {
|
||||
ConsensusLayerHealthEvent::NeverSeen => {
|
||||
warn!("Post-merge network, but never seen beacon client. Please launch one to follow the chain!")
|
||||
}
|
||||
ConsensusLayerHealthEvent::HasNotBeenSeenForAWhile(period) => {
|
||||
warn!(?period, "Post-merge network, but no beacon client seen for a while. Please launch one to follow the chain!")
|
||||
}
|
||||
ConsensusLayerHealthEvent::NeverReceivedUpdates => {
|
||||
warn!("Beacon client online, but never received consensus updates. Please ensure your beacon client is operational to follow the chain!")
|
||||
}
|
||||
ConsensusLayerHealthEvent::HaveNotReceivedUpdatesForAWhile(period) => {
|
||||
warn!(?period, "Beacon client online, but no consensus updates received for a while. Please fix your beacon client to follow the chain!")
|
||||
// If pipeline is running, it's fine to not receive any messages from the CL.
|
||||
// So we need to report about CL health only when pipeline is idle.
|
||||
if self.current_stage.is_none() {
|
||||
match event {
|
||||
ConsensusLayerHealthEvent::NeverSeen => {
|
||||
warn!("Post-merge network, but never seen beacon client. Please launch one to follow the chain!")
|
||||
}
|
||||
ConsensusLayerHealthEvent::HasNotBeenSeenForAWhile(period) => {
|
||||
warn!(?period, "Post-merge network, but no beacon client seen for a while. Please launch one to follow the chain!")
|
||||
}
|
||||
ConsensusLayerHealthEvent::NeverReceivedUpdates => {
|
||||
warn!("Beacon client online, but never received consensus updates. Please ensure your beacon client is operational to follow the chain!")
|
||||
}
|
||||
ConsensusLayerHealthEvent::HaveNotReceivedUpdatesForAWhile(period) => {
|
||||
warn!(?period, "Beacon client online, but no consensus updates received for a while. Please fix your beacon client to follow the chain!")
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user