This is an automated email from the ASF dual-hosted git repository.

hubcio pushed a commit to branch fix/docs-audit-core
in repository https://gitbox.apache.org/repos/asf/iggy.git

commit 1ec2ae4aeda29cb89664b51fc5bc4733128c74ec
Author: Hubert Gruszecki <[email protected]>
AuthorDate: Sat Sep 12 20:05:31 2026 +0200

    fix(bench): preserve runtime tuning in benchmark reports
    
    Runtime controls outside typed configuration disappeared from saved
    benchmark commands. Allow the two nonsecret controls explicitly
    while keeping credential filtering and checking the saved report.
---
 core/bench/src/utils/mod.rs         | 6 +++++-
 core/integration/src/bench_utils.rs | 4 ++++
 2 files changed, 9 insertions(+), 1 deletion(-)

diff --git a/core/bench/src/utils/mod.rs b/core/bench/src/utils/mod.rs
index 91af04bce..8f64eaad9 100644
--- a/core/bench/src/utils/mod.rs
+++ b/core/bench/src/utils/mod.rs
@@ -45,6 +45,8 @@ pub mod cpu_name;
 pub mod finish_condition;
 pub mod rate_limiter;
 
+const RUNTIME_ENV_VARS: &[&str] = &["IGGY_SHARD_RUNTIME_CAPACITY", 
"IGGY_SHARD_EVENT_INTERVAL"];
+
 pub fn batch_total_size_bytes(polled_messages: &PolledMessages) -> u64 {
     polled_messages
         .messages
@@ -189,7 +191,9 @@ fn add_environment_variables(parts: &mut Vec<String>, 
server_address: &str) {
     if is_localhost {
         let iggy_vars: Vec<_> = std::env::vars()
             .filter(|(name, _)| {
-                ServerConfig::find_by_env_name(name).is_some_and(|mapping| 
!mapping.is_secret)
+                RUNTIME_ENV_VARS.contains(&name.as_str())
+                    || ServerConfig::find_by_env_name(name)
+                        .is_some_and(|mapping| !mapping.is_secret)
             })
             .collect();
 
diff --git a/core/integration/src/bench_utils.rs 
b/core/integration/src/bench_utils.rs
index 6db6d1330..4648d7cdd 100644
--- a/core/integration/src/bench_utils.rs
+++ b/core/integration/src/bench_utils.rs
@@ -242,6 +242,8 @@ mod tests {
                 ("IGGY_ENCRYPTION_KEY", TEST_SECRET),
                 ("IGGY_UNRELATED_CREDENTIAL", TEST_SECRET),
                 ("IGGY_SHARDING_CPU_ALLOCATION", "4"),
+                ("IGGY_SHARD_RUNTIME_CAPACITY", "8192"),
+                ("IGGY_SHARD_EVENT_INTERVAL", "256"),
             ])
             .timeout(BENCH_WAIT_TIMEOUT)
             .unwrap();
@@ -253,6 +255,8 @@ mod tests {
             .path();
         let report = 
fs::read_to_string(report_dir.join("report.json")).unwrap();
         assert!(report.contains("IGGY_SHARDING_CPU_ALLOCATION=4"));
+        assert!(report.contains("IGGY_SHARD_RUNTIME_CAPACITY=8192"));
+        assert!(report.contains("IGGY_SHARD_EVENT_INTERVAL=256"));
         for (source, content) in [
             ("report", report.as_str()),
             ("stdout", &String::from_utf8_lossy(&output.stdout)),

Reply via email to