adds metrics tracking crds writes and votes (#20953)

This commit is contained in:
behzad nouri
2021-10-26 13:02:30 +00:00
committed by GitHub
parent cd5e690427
commit 1297a13586
14 changed files with 544 additions and 111 deletions

View File

@ -523,6 +523,7 @@ mod tests {
super::*,
rand::{seq::SliceRandom, Rng},
solana_gossip::{
crds::GossipRoute,
crds_value::{CrdsData, CrdsValue},
deprecated::{
shuffle_peers_and_index, sorted_retransmit_peers_and_stakes,
@ -589,7 +590,10 @@ mod tests {
for node in nodes.iter().skip(1) {
let node = CrdsData::ContactInfo(node.clone());
let node = CrdsValue::new_unsigned(node);
assert_eq!(gossip_crds.insert(node, now), Ok(()));
assert_eq!(
gossip_crds.insert(node, now, GossipRoute::LocalMessage),
Ok(())
);
}
}
(nodes, stakes, cluster_info)