Skip to content

ci: automated Python-vs-Rust benchmarks#35

Merged
Arkptz merged 7 commits intomainfrom
docs/benchmarks
Apr 22, 2026
Merged

ci: automated Python-vs-Rust benchmarks#35
Arkptz merged 7 commits intomainfrom
docs/benchmarks

Conversation

@Arkptz
Copy link
Copy Markdown
Owner

@Arkptz Arkptz commented Apr 22, 2026

Summary

Replace the minimal Rust-only benchmark workflow with a comprehensive
Python-vs-Rust comparison. The new workflow generates a synthetic ~80 MB
flow via httpbin + mitmdump + hey, then runs hyperfine and RSS measurements
on both tools against two datasets (Petstore fixture and synthetic). Results
are uploaded as artifacts and optionally auto-committed to docs/benchmarks.md
on scheduled/manual runs.

Type of Change

  • CI / build / tooling
  • Documentation update

Checklist

  • cargo fmt --all clean
  • cargo clippy --all-targets --all-features -- -D warnings clean
  • cargo test passes locally
  • Added or updated tests for the change
  • Updated README / CLI help text if user-facing behavior changed
  • Added entry to CHANGELOG.md under [Unreleased] (if user-facing)
  • Used conventional commit style in commit messages (feat:, fix:, docs:, etc.)

Testing

Workflow YAML reviewed for correctness. Actual benchmark runs on merge to
main (paths filter matches .github/workflows/bench.yml). Manual trigger
available via workflow_dispatch.

Related Issues

Closes #8

Arkptz added 4 commits April 23, 2026 00:35
testdata/flows/multiple.flow is a unit-test scaffolding file without real
URLs, producing 0 discovered paths regardless of prefix. No 11 KB real
capture is checked into the repo (petstore.flow is generated by the Docker
integration tests). Keep the synthetic 80 MB tier as the sole benchmark,
which is both reproducible in CI and representative of real-world captures
where Python interpreter boot cost no longer dominates the measurement.
Arkptz added 3 commits April 23, 2026 00:46
Generating the synthetic capture in CI is fragile — it requires httpbin
via service container, mitmdump, hey, and Go tooling just to produce a
fixture that never changes between runs. Pre-generate once, upload to a
GitHub release asset tagged bench-fixtures-v1, download on each CI run
with SHA-256 integrity check. The workflow is now ~90 lines shorter and
runs in ~3-5 min instead of 10+ min.
@Arkptz Arkptz merged commit 412f37d into main Apr 22, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Benchmark mitm2openapi vs Python mitmproxy2swagger

1 participant