Skip to content

benchmarking: write the turnover window with the whole-run keys - #3789

Merged
Max Smythe (maxsmythe) merged 1 commit into
agent-substrate:mainfrom
chw120:turnover-window-standard-rows
Nov 11, 2026
Merged

Max Smythe (maxsmythe) merged 1 commit into
agent-substrate:mainfrom
chw120:turnover-window-standard-rows

Conversation

@chw120

Copy link
Copy Markdown
Collaborator

In a turnover run, the whole-run Requests/s also divides by the time spent registering the fleet. A gVisor run with 2,000 sessions swapping at 10/s shows 8.1 ResumeActor/s, so the dashboards estimate the live window instead of reading it.

turnover_window.py already counts each request from the turnover fill done line to the end of the run. It writes those counts under per-request keys (requests_<name>, rps_<name>). Tables that load stats.jsonl with the schema of the whole-run rows drop those keys, so the turnover_window row reads as empty there.

Write one turnover_<name> row per request instead, with the whole-run keys (request_count, failure_count, requests_per_s, failures_per_s) and the window bounds. The swap rate is the requests_per_s of turnover_TimeToWake.

Tested with the benchmarking/locust unit tests under pytest, the way hack/verify/benchmarking-python.sh runs them.

I used an AI agent to draft the change, the test and this description, and reviewed them myself.

The turnover_window row keyed each request's counts by name, as
requests_<name>, failures_<name> and rps_<name>. Tables that load
stats.jsonl with the schema of the whole-run rows drop those keys, so
readers of those tables see only whole-run rates, which include the
fleet registration.

Write one turnover_<name> row per request instead. Each has the
request_count, failure_count, requests_per_s and failures_per_s keys of
the whole-run rows, and the window bounds.

Signed-off-by: Chenyi Wang <chenyiwang@google.com>

@maxsmythe Max Smythe (maxsmythe) left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Awesome! LGTM

@maxsmythe
Max Smythe (maxsmythe) added this pull request to the merge queue Nov 11, 2026
@maxsmythe

Copy link
Copy Markdown
Collaborator

Should say that this is a benchmarking-only change

Merged via the queue into agent-substrate:main with commit 7b00417 Nov 11, 2026
7 checks passed
@chw120
Chenyi Wang (chw120) deleted the turnover-window-standard-rows branch November 11, 2026 18:14
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.

2 participants