feat: add throughput benchmark suite#54
Open
danfry1 wants to merge 1 commit into
Open
Conversation
Add benchmarks/index.ts (run via `bun run bench`) measuring engine and storage overhead — enqueue throughput and end-to-end execution (enqueue to durable completion) — across the in-memory and Bun SQLite adapters, for 1- and 5-step workflows. Uses a no-op passthrough input schema and trivial handlers so the numbers reflect Reflow's own cost. Publishes baseline numbers in the README.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Adds a throughput benchmark suite so Reflow's performance is measurable and reproducible — supporting the project's "no external services, low overhead" positioning with real numbers.
bun run bench(benchmarks/index.ts) measures the engine + storage layers (trivial handlers, no-op passthrough input schema, so the numbers reflect Reflow's own cost rather than a workload):createRunrate.Baseline numbers (Bun, Apple Silicon) are published in the README's new Performance section. The harness warms up the JIT/disk before timing and has a drain safety-bound so it can never spin.
Base
Branched off
fix/sqlite-bun-changes(#52): the Bun SQLite adapter only functions with that change-detection fix (without it,updateClaimedRunStatusreturns false, runs never complete, and the benchmark stalls — which this work incidentally re-confirmed). Once #52 merges, this retargets tomaincleanly (it only adds new files:benchmarks/, abenchscript, and README/CHANGELOG notes).Verified:
typecheck,test,build,lint:deps,test:bunall pass; the benchmark file is independently type-clean.