From 25feb36ddd0db5ba9f40ebe9893136a1f5b7996c Mon Sep 17 00:00:00 2001 From: Maria Kuklina Date: Fri, 20 Sep 2024 14:36:09 +0200 Subject: [PATCH 1/2] fix(config): change defaults for batching --- crates/server-config/src/defaults.rs | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/crates/server-config/src/defaults.rs b/crates/server-config/src/defaults.rs index 59fa30272c..2a4217de25 100644 --- a/crates/server-config/src/defaults.rs +++ b/crates/server-config/src/defaults.rs @@ -277,18 +277,18 @@ pub fn default_proof_poll_period() -> Duration { } pub fn default_min_batch_count() -> usize { - // Wait for at least 5 proofs before sending the tx to reduce TPS - 5 + // Wait for at least 1 proof before sending the tx to reduce TPS + 1 } pub fn default_max_batch_count() -> usize { - // 30 is the default minimal proof count per CU on the mainnet - 30 + // 4 is the default minimal proof count per CU on the mainnet + 4 } pub fn default_max_proof_batch_size() -> usize { - // 128 is the average CU number on a single machine - 128 + // 2 is the average CU number on a single machine + 2 } pub fn default_epoch_end_window() -> Duration { From 2e16719dcc3b25037ebd4b5f490c65e97a4073af Mon Sep 17 00:00:00 2001 From: folex <0xdxdy@gmail.com> Date: Fri, 20 Sep 2024 15:43:50 +0300 Subject: [PATCH 2/2] fix: Apply suggestions from code review --- crates/server-config/src/defaults.rs | 3 --- 1 file changed, 3 deletions(-) diff --git a/crates/server-config/src/defaults.rs b/crates/server-config/src/defaults.rs index 2a4217de25..59cab61ec1 100644 --- a/crates/server-config/src/defaults.rs +++ b/crates/server-config/src/defaults.rs @@ -277,17 +277,14 @@ pub fn default_proof_poll_period() -> Duration { } pub fn default_min_batch_count() -> usize { - // Wait for at least 1 proof before sending the tx to reduce TPS 1 } pub fn default_max_batch_count() -> usize { - // 4 is the default minimal proof count per CU on the mainnet 4 } pub fn default_max_proof_batch_size() -> usize { - // 2 is the average CU number on a single machine 2 }