Skip to content

Commit

Permalink
from became unused, so removed from all process_pull_response() calls
Browse files Browse the repository at this point in the history
  • Loading branch information
greg committed Oct 16, 2023
1 parent 277639e commit f4ee1ba
Show file tree
Hide file tree
Showing 4 changed files with 2 additions and 20 deletions.
1 change: 0 additions & 1 deletion gossip/src/cluster_info.rs
Original file line number Diff line number Diff line change
Expand Up @@ -2184,7 +2184,6 @@ impl ClusterInfo {
{
let _st = ScopedTimer::from(&self.stats.process_pull_response);
self.gossip.process_pull_responses(
from,
filtered_pulls,
filtered_pulls_expired_timeout,
failed_inserts,
Expand Down
2 changes: 0 additions & 2 deletions gossip/src/crds_gossip.rs
Original file line number Diff line number Diff line change
Expand Up @@ -274,7 +274,6 @@ impl CrdsGossip {
/// Process a pull response.
pub fn process_pull_responses(
&self,
from: &Pubkey,
responses: Vec<CrdsValue>,
responses_expired_timeout: Vec<CrdsValue>,
failed_inserts: Vec<Hash>,
Expand All @@ -283,7 +282,6 @@ impl CrdsGossip {
) {
self.pull.process_pull_responses(
&self.crds,
from,
responses,
responses_expired_timeout,
failed_inserts,
Expand Down
18 changes: 2 additions & 16 deletions gossip/src/crds_gossip_pull.rs
Original file line number Diff line number Diff line change
Expand Up @@ -360,7 +360,6 @@ impl CrdsGossipPull {
pub(crate) fn process_pull_responses(
&self,
crds: &RwLock<Crds>,
from: &Pubkey,
responses: Vec<CrdsValue>,
responses_expired_timeout: Vec<CrdsValue>,
failed_inserts: Vec<Hash>,
Expand Down Expand Up @@ -542,7 +541,6 @@ impl CrdsGossipPull {
fn process_pull_response(
&self,
crds: &RwLock<Crds>,
from: &Pubkey,
timeouts: &CrdsTimeouts,
response: Vec<CrdsValue>,
now: u64,
Expand All @@ -552,7 +550,6 @@ impl CrdsGossipPull {
self.filter_pull_responses(crds, timeouts, response, now, &mut stats);
self.process_pull_responses(
crds,
from,
versioned,
versioned_expired_timeout,
failed_inserts,
Expand Down Expand Up @@ -1195,7 +1192,6 @@ pub(crate) mod tests {
let failed = node
.process_pull_response(
&node_crds,
&node_pubkey,
&node.make_timeouts(node_pubkey, &HashMap::new(), Duration::default()),
rsp.into_iter().flatten().collect(),
1,
Expand Down Expand Up @@ -1374,14 +1370,8 @@ pub(crate) mod tests {
);
// inserting a fresh value should be fine.
assert_eq!(
node.process_pull_response(
&node_crds,
&peer_pubkey,
&timeouts,
vec![peer_entry.clone()],
1,
)
.0,
node.process_pull_response(&node_crds, &timeouts, vec![peer_entry.clone()], 1,)
.0,
0
);

Expand All @@ -1393,7 +1383,6 @@ pub(crate) mod tests {
assert_eq!(
node.process_pull_response(
&node_crds,
&peer_pubkey,
&timeouts,
vec![peer_entry.clone(), unstaked_peer_entry],
node.crds_timeout + 100,
Expand All @@ -1407,7 +1396,6 @@ pub(crate) mod tests {
assert_eq!(
node.process_pull_response(
&node_crds,
&peer_pubkey,
&timeouts,
vec![peer_entry],
node.crds_timeout + 1,
Expand All @@ -1424,7 +1412,6 @@ pub(crate) mod tests {
assert_eq!(
node.process_pull_response(
&node_crds,
&peer_pubkey,
&timeouts,
vec![peer_vote.clone()],
node.crds_timeout + 1,
Expand All @@ -1438,7 +1425,6 @@ pub(crate) mod tests {
assert_eq!(
node.process_pull_response(
&node_crds,
&peer_pubkey,
&timeouts,
vec![peer_vote],
node.crds_timeout + 2,
Expand Down
1 change: 0 additions & 1 deletion gossip/tests/crds_gossip.rs
Original file line number Diff line number Diff line change
Expand Up @@ -575,7 +575,6 @@ fn network_run_pull(
.gossip
.filter_pull_responses(&timeouts, rsp, now, &mut stats);
node.gossip.process_pull_responses(
&from,
vers,
vers_expired_timeout,
failed_inserts,
Expand Down

0 comments on commit f4ee1ba

Please sign in to comment.