Skip to content

Commit

Permalink
Merge pull request #4932 from stacks-network/chore/configure-antientr…
Browse files Browse the repository at this point in the history
…opy-retry

chore: make connection_options.antientropy_retry configurable
  • Loading branch information
wileyj committed Jul 1, 2024
2 parents 35d0840 + 0f000c9 commit f938baf
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion testnet/stacks-node/src/config.rs
Original file line number Diff line number Diff line change
Expand Up @@ -2389,6 +2389,7 @@ pub struct ConnectionOptionsFile {
pub antientropy_public: Option<bool>,
pub private_neighbors: Option<bool>,
pub block_proposal_token: Option<String>,
pub antientropy_retry: Option<u64>,
}

impl ConnectionOptionsFile {
Expand Down Expand Up @@ -2420,6 +2421,7 @@ impl ConnectionOptionsFile {
self.read_only_call_limit_runtime.map(|x| {
read_only_call_limit.runtime = x;
});
let default = ConnectionOptions::default();
Ok(ConnectionOptions {
read_only_call_limit,
inbox_maxlen: self
Expand Down Expand Up @@ -2513,7 +2515,8 @@ impl ConnectionOptionsFile {
antientropy_public: self.antientropy_public.unwrap_or(true),
private_neighbors: self.private_neighbors.unwrap_or(true),
block_proposal_token: self.block_proposal_token,
..ConnectionOptions::default()
antientropy_retry: self.antientropy_retry.unwrap_or(default.antientropy_retry),
..default
})
}
}
Expand Down

0 comments on commit f938baf

Please sign in to comment.