Skip to content

benchmarking: add --burst-size to pace ResumePaused cold resumes in waves - #3750

Merged
Max Smythe (maxsmythe) merged 1 commit into
agent-substrate:mainfrom
sairajp-rewind:benchmarks/resumepaused-burst
Nov 11, 2026
Merged

Max Smythe (maxsmythe) merged 1 commit into
agent-substrate:mainfrom
sairajp-rewind:benchmarks/resumepaused-burst

Conversation

@sairajp-rewind

@sairajp-rewind Sairaj Pokale (sairajp-rewind) commented Nov 9, 2026 •

Copy link
Copy Markdown
Collaborator

ResumePausedUser spaces cold resumes one by one through a rate.Limiter with burst 1. Smooth pacing measures steady-state throughput at a given average rate, but hides the queueing, CPU throttling, and Postgres connection/lock contention that happen when many actors resume at the same time.

Add --burst-size (burst_size in /boomer-config and the Locust web UI, default 0) to release cold resumes in waves of up to burst_size users every burst_size / target_rps seconds while keeping the same average rate (target_rps).

  • When burst_size is 0 (default), ResumePausedUser keeps the existing smooth token-bucket pacing.
  • When burst_size > 0, up to burst_size callers sleep until the same wave boundary on a burst_size / target_rps grid; an overflow or late caller advances to the next boundary on the grid, and live updates to burst_size or target_rps (including across --ladder @target_rps steps) step forward from the last scheduled boundary using the new period.
  • Reject burst_size < 0 or burst_size > 0 without target_rps > 0 in the boomer knobs codec.

Supersedes #2399.

AI use: AI-assisted, I reviewed and tested it.

  • Tests pass
  • Docs updated

Comment thread docs/guides/benchmarking.md Resolved
…waves

Signed-off-by: Sairaj Pokale <sairajpokale@google.com>

@haiyanmeng haiyanmeng 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.

LGTM. Leave it to Max Smythe (@maxsmythe) for approval.

@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.

LGTM, nit not worth blocking PR on.

}

// sleepCtx blocks for d or until ctx is done.
func sleepCtx(ctx context.Context, d time.Duration) {

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.

🤖 nit 🟢 – dwell in agentsession.go is the same helper. Consider moving one copy to boomerutil and using it from both packages, here or in a follow-up.

@maxsmythe

Copy link
Copy Markdown
Collaborator

Merging as doc-only change

@maxsmythe
Max Smythe (maxsmythe) added this pull request to the merge queue Nov 11, 2026
Merged via the queue into agent-substrate:main with commit 905e2a6 Nov 11, 2026
7 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants