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

FEATURE: Adding metrics - num_get_vote_accounts_voting, num_live_validator_histories #35

Merged
merged 5 commits into from
May 10, 2024

Conversation

coachchucksol
Copy link
Contributor

@coachchucksol coachchucksol commented May 9, 2024

Added two new metrics to the emit_validator_history_metrics function:

  • num_live_validator_histories: The number of validator history accounts that have "live" vote accounts with the owner of said vote account being the vote program
  • num_get_vote_accounts_voting: The number of vote accounts actually voting. More specifically, accounts that have voted in the current epoch retrieved from get_vote_accounts_with_retry.

Copy link
Collaborator

@ebatsell ebatsell left a comment

Choose a reason for hiding this comment

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

Take a look at the lint output as well, the udeps seems to be a different issue

keepers/validator-keeper/src/lib.rs Outdated Show resolved Hide resolved
keepers/validator-keeper/src/lib.rs Outdated Show resolved Hide resolved
@coachchucksol coachchucksol changed the title FEATURE: Adding metrics - num_alive_validator_histories, num_get_vote_accounts_live_validators FEATURE: Adding metrics - num_get_vote_accounts_voting, num_live_validator_histories May 10, 2024
let live_validator_histories_count =
get_multiple_accounts_batched(&all_history_vote_accounts, client)
.await
.expect("Cannot fetch validator history vote accounts")
Copy link
Collaborator

Choose a reason for hiding this comment

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

? here instead of expect

Copy link
Contributor

Choose a reason for hiding this comment

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

Done

@coachchucksol coachchucksol merged commit ea2543a into master May 10, 2024
6 checks passed
@coachchucksol coachchucksol deleted the adding_metrics branch May 10, 2024 16:07
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.

3 participants