Repository navigation
Avoid empty managed Runtime scan intervals - #26
Merged
Merged
Conversation
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.
Managed Runtime scans currently spend an entire five-second ticker interval at allocation EOF without observing any allocation. A small deployment therefore observes its instances only every other tick, adding unnecessary wait to wake requests and cleanup.
On EOF after a nonempty cursor, advance the existing bounded initialization operation and read the first page in the same reconciliation call. Preserve the five-second ticker, at most 32 allocation observations per call, one initialization operation per full scan, and a single refill so an empty store cannot spin. Provider APIs, harness behavior and suspension eligibility are unchanged.
Validation:
make checkpassed on Linux with real PostgreSQL; GitHubcheckpassed.Measured request submission to Core
Turn.started, using one server clock and PostgreSQL timestamps:Resume improved by 4.951 s and 4.921 s in these pairs. New-Session startup showed no meaningful improvement. The runs reused the same cached immutable image, helper and native runtime; image download, native first-tool timing and model response completion are outside this measurement. Two samples per version do not establish a percentile or SLA.
The sessions compatibility job passed persistence tests, then reproduced existing CI-001 at
official_agent_references.py:73(Expected BadRequestError). Its later container stage did not run. The same stale assertion was recorded before this change; no assertion or gate was bypassed.Plan and evidence: Document A, PERF-001.