Skip to content

perf: add criterion benchmark suite for daemon mode - #3016

Merged
oferchen merged 1 commit into
masterfrom
perf/daemon-benchmarks
Mar 23, 2026
Merged

oferchen merged 1 commit into
masterfrom
perf/daemon-benchmarks

Conversation

@oferchen

Copy link
Copy Markdown
Owner

Summary

  • Rename daemon_bench.rs to daemon_benchmark.rs and update the [[bench]] section in Cargo.toml
  • Add bench_module_access_check benchmark group exercising the full module access check pattern through the public API: module lookup, auth user membership, host ACL pattern matching, and secrets file credential lookup
  • Covers both allowed and denied paths (unauthorized user, denied host) at 10/50/100 module scales

Existing benchmarks already covered:

  • Config parsing: bench_config_parse with 10/50/100 modules
  • Module lookup: bench_module_lookup with hit/miss scenarios
  • Auth challenge generation: bench_auth_challenge_response with all 5 digest algorithms (SHA-512/256/1, MD5, MD4) plus full verify round-trips
  • Secrets file: bench_secrets_file with parse and lookup at 10/100/1000 entries
  • Path validation: bench_path_validation with adversarial configs (long comments, many filters, deep host ACLs)

Test plan

  • CI passes (fmt, clippy, nextest on all platforms)
  • Benchmark compiles: cargo bench -p daemon --bench daemon_benchmark --no-run

@oferchen
oferchen force-pushed the perf/daemon-benchmarks branch from c5e9454 to e3499b4 Compare March 23, 2026 18:14
Rename daemon_bench to daemon_benchmark and add module access check
benchmarks covering the full access check pattern: module lookup, auth
user verification, host ACL pattern matching, and secrets file lookup
with both allowed and denied paths at 10/50/100 module scales.
@oferchen
oferchen force-pushed the perf/daemon-benchmarks branch from e3499b4 to 824845f Compare March 23, 2026 19:24
@oferchen
oferchen merged commit 6d996a6 into master Mar 23, 2026
4 of 11 checks passed
@oferchen
oferchen deleted the perf/daemon-benchmarks branch March 23, 2026 19:24
oferchen added a commit that referenced this pull request May 1, 2026
Rename daemon_bench to daemon_benchmark and add module access check
benchmarks covering the full access check pattern: module lookup, auth
user verification, host ACL pattern matching, and secrets file lookup
with both allowed and denied paths at 10/50/100 module scales.
oferchen added a commit that referenced this pull request May 5, 2026
Rename daemon_bench to daemon_benchmark and add module access check
benchmarks covering the full access check pattern: module lookup, auth
user verification, host ACL pattern matching, and secrets file lookup
with both allowed and denied paths at 10/50/100 module scales.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant