being less aggressive in contract polling
This commit is contained in:
@@ -191,6 +191,11 @@ impl<R: RngCore + CryptoRng + Clone> DkgController<R> {
|
||||
self.state.in_progress_state_mut(epoch_id).unwrap().entered = true;
|
||||
}
|
||||
|
||||
// so at this point we don't need to be polling the contract so often anymore, but we can't easily
|
||||
// adjust the existing interval.
|
||||
// however, what we can do is just wait here for a bit each iteration
|
||||
tokio::time::sleep(Duration::from_secs(120)).await;
|
||||
|
||||
Ok(())
|
||||
}
|
||||
|
||||
|
||||
@@ -30,7 +30,7 @@ mod upgrade_helpers;
|
||||
|
||||
pub const DEFAULT_LOCAL_VALIDATOR: &str = "http://localhost:26657";
|
||||
|
||||
pub const DEFAULT_DKG_CONTRACT_POLLING_RATE: Duration = Duration::from_secs(10);
|
||||
pub const DEFAULT_DKG_CONTRACT_POLLING_RATE: Duration = Duration::from_secs(30);
|
||||
|
||||
const DEFAULT_GATEWAY_SENDING_RATE: usize = 200;
|
||||
const DEFAULT_MAX_CONCURRENT_GATEWAY_CLIENTS: usize = 50;
|
||||
|
||||
Reference in New Issue
Block a user