orbit backend: dispatcher pool mode - #88
Merged
Merged
Conversation
The broker draws every connected runtime as a participant, so the backend's anonymous `rhapsody.<uuid>` shows up as noise in a topology view -- two of them, unexplained, for a session with two engines. A caller which knows what the backend is for can now say so (`participant_name="rhapsody.<session>.<role>"`); uniqueness becomes that caller's contract. Unnamed backends keep the unique suffix and the old behavior exactly. Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
'consumer' is the runtime's say-nothing default. A topology viewer now sees what the participant is: the engine side of the compute hand-off. Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
A `pool` argument turns the backend's target from a per-endpoint rhapsody session into a task-dispatcher-style plugin: with no explicit endpoint the broker participant (which hosts the dispatcher) is the target and endpoint auto-selection is skipped -- the pool's pilots pick the executing endpoints, not this backend. Every submitted task is stamped with the pool (a task already naming one keeps it), and the python-version handshake for cloudpickled tasks resolves against the pool's executing endpoint (via the dispatcher's pool detail) instead of the submission target. `session_kwargs` forwards into the remote session registration, so a backend can join an existing dispatcher session by sid -- pools are keyed per session. Co-Authored-By: Claude Fable 5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_016Npyz3Hbnwos12ESsdJ2YU
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_016Npyz3Hbnwos12ESsdJ2YU
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_016Npyz3Hbnwos12ESsdJ2YU
AymenFJA
self-requested a review
August 25, 2026 13:28
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.
The rhapsody half of digital.twins#7 phase 2 (companion to radical.orbit#117, which teaches the task dispatcher the rhapsody execution dialect).
New
OrbitExecutionBackendarguments:pool: run tasks in a dispatcher-managed pool. With no explicitendpoint_namethe broker participant (hosting the dispatcher) is targeted and endpoint auto-selection is skipped — the pool's pilots pick the executing endpoints. Every submitted task is stampedpool=<name>(an explicit per-task pool wins), and the cloudpickle python-version handshake resolves against the pool's executing endpoint via the dispatcher'spool_detailinstead of the submission target. Combine withplugin_name="task_dispatcher".session_kwargs: forwarded intoget_plugin— e.g.sidto join the dispatcher session that owns the pools, orpoolsto declare them.Everything else — submission batching, notification consumption (
task_status/task_status_batch), cancel, shutdown — works unchanged against the dispatcher, which is the point of the dialect.Stacked on #87 (
participant_name/role="engine"); the diff on top of that branch is this PR's own two files. Tests: 3 new pool-mode tests;tests/unit/test_backend_execution_orbit.py41 passed (remaining unit-suite failures are pre-existing dask/telemetry environment issues).🤖 Generated with Claude Code
https://claude.ai/code/session_016Npyz3Hbnwos12ESsdJ2YU