Skip to content

Commit

Permalink
Merge #1545
Browse files Browse the repository at this point in the history
1545: fix: always resend query to adults r=bochaco a=joshuef

Remove a potential source of errors. We _always_ send on queries now. Regardless if the client already exists in `pending_queries`. There's a reason they're re-requesting.

When we have cache implemented at elders we can short circuit this there... but otherwise we should treat each request equally.

Co-authored-by: Josh Wilson <joshuef@gmail.com>
  • Loading branch information
bors[bot] and joshuef committed Sep 5, 2022
2 parents e8202a6 + 7c207e4 commit b62c056
Showing 1 changed file with 0 additions and 4 deletions.
4 changes: 0 additions & 4 deletions sn_node/src/node/data/records.rs
Expand Up @@ -103,10 +103,6 @@ impl Node {
if peers.len() > MAX_WAITING_PEERS_PER_QUERY {
warn!("Dropping query from {source_client:?}, there are more than {MAX_WAITING_PEERS_PER_QUERY} waiting already");
return Ok(vec![]);
} else {
// we don't respond to the actual query, as we're still within data query timeout
// we rely on the data query cache timeout to decide as/when we'll be re-sending a query to adults
return Ok(cmds);
}
}

Expand Down

0 comments on commit b62c056

Please sign in to comment.