Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

validator-network: Improve logging #2668

Merged
merged 1 commit into from
Jun 22, 2024
Merged

Conversation

jsdanielh
Copy link
Member

Improve validator-network logging by moving most of the recurring errors to trace and only log to debug when there is a change in the state of the cache.

Pull request checklist

  • All tests pass. The project builds and runs.
  • I have resolved any merge conflicts.
  • I have resolved all clippy and rustfmt warnings.

@@ -128,11 +128,11 @@ where
Ok(peer_id)
}
Ok(None) => {
log::trace!(validator_id, %public_key, "Unable to resolve validator peer ID: Entry not found in DHT");
log::debug!(validator_id, %public_key, "Unable to resolve validator peer ID: Entry not found in DHT");
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think it'd be better to still log these messages the first time they appear, but stop logging them afterwards.

Improve `validator-network` logging by moving most of the recurring
errors to `trace` and only log to `debug` when there is a change in
the state of the cache.
Copy link
Member

@hrxi hrxi left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

After talking to @jsdanielh, this looks good to me.

@jsdanielh jsdanielh merged commit 63a8c85 into albatross Jun 22, 2024
6 checks passed
@jsdanielh jsdanielh deleted the jsdanielh/minor_fixes branch June 22, 2024 09:16
@jsdanielh jsdanielh added this to the Nimiq PoS Mainnet milestone Jun 22, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants