docs: AgentOS durable background execution (job queue) - #759
Open
ysolanky wants to merge 14 commits into
Open
Conversation
Add an AgentOS Background Execution section covering the durable job queue shipped in v3.0: overview and quickstart, durable queue semantics (guarantee, max_attempts, stores, idempotency keys, session serialization, config reference), multi-replica Redis coordination, durable HITL continuations, and the /queue operations surface. Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
|
Preview deployment for your docs. Learn more about Mintlify Previews.
💡 Tip: Enable Workflows to automatically generate PRs for you. |
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
The 202 contract, PENDING status, /resume, /cancel and the db requirement are unchanged from v2. The only default change is the per-replica concurrency cap; durability, Redis coordination, idempotency keys and the /queue surface are opt-in via QueueConfig. Fix the migration guide and changelog, which presented the opt-in features as defaults. Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Splice the four /queue paths and their schemas (QueueJobSchema, PaginatedResponse_QueueJobSchema_) from a v3 AgentOS OpenAPI dump into reference-api/openapi.yaml, add the schema pages and a Queue nav group, and document the queue and event_stream AgentOS parameters. Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
kausmeows
reviewed
Aug 28, 2026
| @@ -0,0 +1,175 @@ | |||
| --- | |||
| title: Background Execution | |||
Contributor
There was a problem hiding this comment.
maybe we say Durable Background Execution?
| agent_os = AgentOS( | ||
| agents=[agent], | ||
| db=db, | ||
| queue=QueueConfig(durable=True), |
Contributor
There was a problem hiding this comment.
do we not pass redis here?
|
|
||
| ## With more than one replica | ||
|
|
||
| Set `QueueConfig(redis=...)` as soon as you run two or more replicas behind a load balancer. One setting installs both the event stream and the cancellation manager on each replica, backed by a shared Redis, so a run started on one replica can be watched, resumed, and cancelled from any other. No `set_cancellation_manager()` or `set_event_stream()` call is needed. |
|
|
||
| Set `QueueConfig(redis=...)` as soon as you run two or more replicas behind a load balancer. One setting installs both the event stream and the cancellation manager on each replica, backed by a shared Redis, so a run started on one replica can be watched, resumed, and cancelled from any other. No `set_cancellation_manager()` or `set_event_stream()` call is needed. | ||
|
|
||
| See [Multi-replica deployments](/agent-os/background-execution/multi-replica) for what Redis does here, and why `queue.redis` is a different job from `db=RedisDb`. |
Contributor
There was a problem hiding this comment.
do we opensource this- https://github.com/agno-agi/agentos-durable and people can test if needed?
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
User-facing docs for AgentOS durable background execution (the v3.0 job queue, agno-agi/agno#9079). Adds a Background Execution group to the AgentOS tab with five pages:
agent-os/background-execution/overview- mental model (db = truth,queue.redis= coordination,durable=True= promise), quickstart, 202 contract, modes, limitationsagent-os/background-execution/durable-queue- the guarantee,max_attemptscrash semantics, queue stores, idempotency keys, session serialization, latency, fullQueueConfigreferenceagent-os/background-execution/multi-replica- events out / cancel in viaqueue.redis, coordination vsdb=RedisDbticket storage,RedisCoordinationagent-os/background-execution/hitl-continuations- continuing a paused durable run through the queue under the samerun_idagent-os/background-execution/operations-/queueendpoints, requeue, stats, retention, admin gating,deployment_idAlso adds a cross-link note to the SDK-level
background-execution/overviewMulti-Container section.Verification
cookbook/05_agent_os/background_tasks/durable_queue.pyanddurable_continue.py(feat/v3.0, 3.0.0a4) against local Postgres. Confirmed the 202/poll contract, ticket states,/queue/statsand/queue/jobs, Idempotency-Key dedup, paused ticket, 409 on inline continue, 202 durable continue and double-click attach, cancel of a paused run, requeue behavior.QueueConfigfield re-checked againstlibs/agno/agno/job_queue/config.py.mint broken-linksandscripts/inventory/run_all.py: 0 broken links.Review notes
serialize_sessions, "starts in milliseconds", requeue claiming immediately) documents feat: serialize background runs per session (head-of-line durable claims) agno#9587 and feat: wake the local queue worker on enqueue (durable submissions start in milliseconds) agno#9667, which are still open. Those sections should ship with, or be removed if those PRs don't land in, v3.0.max_attempts=2crash reclaim,RedisDbas queue store, streaming through the queue. All written from source.🤖 Generated with Claude Code