Repository navigation
Measure repeated queue workloads with latency, retries and cross-device evidence - #7
Merged
Merged
Conversation
…ed handler timing
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.
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.