Skip to content

Commit

Permalink
Add logging when RpcHealthStatus::Unknown (#18099)
Browse files Browse the repository at this point in the history
  • Loading branch information
CriesofCarrots authored Jun 21, 2021
1 parent 16c42a7 commit 7759210
Showing 1 changed file with 9 additions and 1 deletion.
10 changes: 9 additions & 1 deletion core/src/rpc_health.rs
Original file line number Diff line number Diff line change
Expand Up @@ -98,7 +98,15 @@ impl RpcHealth {
RpcHealthStatus::Behind { num_slots }
}
}
_ => RpcHealthStatus::Unknown,
(latest_account_hash_slot, latest_trusted_validator_account_hash_slot) => {
if latest_account_hash_slot.is_none() {
warn!("health check: latest_account_hash_slot not available");
}
if latest_trusted_validator_account_hash_slot.is_none() {
warn!("health check: latest_trusted_validator_account_hash_slot not available");
}
RpcHealthStatus::Unknown
}
}
} else {
// No trusted validator point of reference available, so this validator is healthy
Expand Down

0 comments on commit 7759210

Please sign in to comment.