diff --git a/nym-api/src/coconut/dkg/controller/mod.rs b/nym-api/src/coconut/dkg/controller/mod.rs index 4b35fb3fcf..db9ce0a82c 100644 --- a/nym-api/src/coconut/dkg/controller/mod.rs +++ b/nym-api/src/coconut/dkg/controller/mod.rs @@ -191,6 +191,11 @@ impl DkgController { 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(()) } diff --git a/nym-api/src/support/config/mod.rs b/nym-api/src/support/config/mod.rs index ca2eb1328c..c5191b7960 100644 --- a/nym-api/src/support/config/mod.rs +++ b/nym-api/src/support/config/mod.rs @@ -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;