Add incoming pull response counter (#11591)
This commit is contained in:
parent
bb8ccbb022
commit
54137e3446
|
@ -242,6 +242,7 @@ struct GossipStats {
|
|||
push_message_count: Counter,
|
||||
push_message_value_count: Counter,
|
||||
push_response_count: Counter,
|
||||
pull_requests_count: Counter,
|
||||
}
|
||||
|
||||
pub struct ClusterInfo {
|
||||
|
@ -1689,9 +1690,14 @@ impl ClusterInfo {
|
|||
}
|
||||
|
||||
// process the collected pulls together
|
||||
let rsp = self.handle_pull_requests(recycler, gossip_pull_data, stakes);
|
||||
if let Some(rsp) = rsp {
|
||||
let _ignore_disconnect = response_sender.send(rsp);
|
||||
if !gossip_pull_data.is_empty() {
|
||||
self.stats
|
||||
.pull_requests_count
|
||||
.add_relaxed(gossip_pull_data.len() as u64);
|
||||
let rsp = self.handle_pull_requests(recycler, gossip_pull_data, stakes);
|
||||
if let Some(rsp) = rsp {
|
||||
let _ignore_disconnect = response_sender.send(rsp);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -2256,6 +2262,14 @@ impl ClusterInfo {
|
|||
i64
|
||||
),
|
||||
);
|
||||
datapoint_info!(
|
||||
"cluster_info_stats5",
|
||||
(
|
||||
"pull_requests_count",
|
||||
self.stats.pull_requests_count.clear(),
|
||||
i64
|
||||
),
|
||||
);
|
||||
|
||||
*last_print = Instant::now();
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue