Skip to content

Measure repeated queue workloads with latency, retries and cross-device evidence - #7

Merged
harshitethic merged 1 commit into
mainfrom
feat/workload-latency-benchmarks
Oct 15, 2026
Merged

harshitethic merged 1 commit into
mainfrom
feat/workload-latency-benchmarks

Conversation

@harshitethic

Copy link
Copy Markdown
Owner

The existing one-run no-op smoke test could not explain worker contention, retries, or tail latency. This adds a dependency-free spawned-process benchmark with repeated worker/handler sweeps, nearest-rank operation percentiles, observed handler timing, source fingerprints and complete retained trial data.

Every trial validates exact successful job IDs, attempt/retry totals, queue state, full event counts and SQLite integrity. Timeout and crashed-worker paths reap all children, including a live sibling of a crashed worker. Six regressions bring the suite to 54. CI runs a small sweep and retains its report without speed thresholds.

Recorded evidence: 30 trials on Kali and 30 on macOS; 18,000 completed jobs and 1,800 retries. Final 54-test suites passed on both devices. An exploratory run exposed that requested 5 ms sleeps on the Mac were much longer in practice; added observed-handler instrumentation and repeated the entire sweep. The published runs show roughly 173–191 ms handler medians on that Mac versus about 5.1 ms on Kali. The cause is not isolated, and the results are explicitly not a CPU ranking, production capacity or SLO. All trials, unfavorable results, per-worker imbalance and tail latencies are retained.

Includes methodology, limitations and an optional matplotlib plot regenerated from retained trials. Core queue behavior and released version are unchanged.

Local checks: 54 tests on Kali/Python 3.12 and Mac/Python 3.14; eight-trial exact CI smoke; Ruff lint/format; report accounting/source-hash verification; chart visual inspection. Awaiting independent Python 3.11–3.13 CI and CodeQL before merge.

@harshitethic
harshitethic merged commit 7daed8f into main Oct 15, 2026
8 checks passed
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.

1 participant