Repository navigation
Conversation
|
You have reached your Codex usage limits for code reviews. You can see your limits in the Codex usage dashboard. |
dporkka
force-pushed
the
codex-bounded-task-scheduler
branch
from
September 28, 2026 19:37
89c4f3f to
11a0f12
Compare
Owner
Author
|
Superseded by the landed scheduler path. PR #60/#63 established atomic ownership/resource admission and task-spec ownership; PR #65 ported the remaining useful budget-start and deferred-redelivery behavior onto current main, with concurrency accounting based on atomic |
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.
Summary
Stacked on #58. Integrate the bounded scheduler into worker run admission without duplicating scheduling logic in the worker.
Behavior
RunAdmissionseam beforeExecuteRunbudget.Engine.CheckRunStartso a queued run is denied when active concurrency is already equal to the configured maximum, while preserving existingCheckRunsemantics for already-running agentstask.metadata.scheduler:ownscpumemory_mbVerification
packages/scheduler: go test -race ./...— passapps/api: go test ./internal/budget ./internal/agentrunner ./pkg/agentexecutor— passapps/worker: go test ./internal/handlers ./cmd/worker— passgo vet— passmake buildbuilds API, CLI, worker, runner and TypeScript SDK successfully; web build then stops because the isolated validation environment does not have the Next.js binary installedmake lint-gocould not run in the isolated validation environment becausegolangci-lintis not installedFollow-up
This PR adds safe admission, not execution parallelism. The current worker event callback invokes long-running
ExecuteRunsynchronously. The next change should add a bounded execution pool that reserves admission atomically before launching work, rather than spawning unbounded goroutines.