Repository navigation
Description
F12.10 — Fair scheduling and quotas
From the Phase 12 plan (.opencode/plans/phase-12-platform-flexibility.md, workstream D):
A hub scheduler that shares fuel and CPU fairly across worlds, with per-account quotas for worlds, storage, and fuel per second, and back-pressure for slow clients. Depends on F11.7 (#553) and F11.8 (#539).
Exit: a world that spins on fuel cannot raise another world's p99 latency by more than 10 percent, shown in a benchmark.
Coordination (2026-10-26 reprioritization, per Drew): every id roadmap item now has its own GitHub issue, and priority encodes the order: (1) the path to Phase 12 — now + priority/high; (2) Phase 12 itself — next; (3) Phase 13 and long-term ideas — priority/low. The dashboard mirrors this list (org Project "Developing Today" #4, Area id-train; Grist Program roadmap, Area id). If this item turns out to be blocked, wrong, or superseded, park or close it with a note rather than letting it stall the queue — dropping an issue is always allowed; silently stalling is not.
Slice progress (F12.10)
- Exit benchmark (a fuel-spinning world raises another world's p99 by ≤10%): measured, unmet, attributed — reference ratio 2.517 (2026-11-10, in
pkgs/id/benches/BASELINES.md); slice 1 profile: PR bench(id): profile the fuel-spin isolation gap (#1067 slice 1) #12572 — the spinning-phase victim p99 is runtime wake starvation (~86–100% of the tail), not victim service. - Hub scheduler sharing fuel and CPU fairly across worlds: unimplemented — first fix step named by the slice-1 profile (guest execution off the shared runtime workers).
- Per-account quotas (worlds, storage, fuel per second): unimplemented.
- Back-pressure for slow clients: unimplemented.
Activity
developing-today commentedon Oct 27, 2026
CODE-211
dezren39 commentedon Nov 1, 2026
🤖 Agent note · done
.opencode/plans/phase-12-platform-flexibility.md:49Triage verdict: CONFIRMED unimplemented; dependencies now closed; too large for a small_fix packet — stays as the tracked
nextroadmap itemDependencies — both closed (fresh check this run):
So F12.10's stated blockers are gone; nothing but the work itself remains.
Confirmed absent at
origin/mainb56ccda (laptop probes this run):grep -rn 'fair|per-account|per_account' pkgs/id/src --include='*.rs'→ zero hits;grep -rln quota pkgs/id --include='*.rs'→ zero source files.pkgs/id/src/world_limits.rsdefines server-adminRuntimeLimits(Wasm fuel/memory/payload caps; native rlimits + per-call deadline) and a per-worldWorldExecutionProfileclamped beneath those ceilings. There is no hub scheduler sharing fuel/CPU across worlds, no per-account quota accounting (worlds/storage/fuel-per-second), and no back-pressure mechanism for slow clients..opencode/plans/phase-12-platform-flexibility.md:49with the benchmark exit: a fuel-spinning world must not raise another world's p99 latency by >10%.Routing — why no follow-up packet from this triage: the queue's follow-up kind for implementation is
small_fix(45-minute timebox); this iseffort/ldesign+implementation (a scheduler + quota accounting + a p99 benchmark on the F11.8 harness). Enqueuing it as a small_fix would guarantee a park/evaporation cycle. The issue itself — open,next, priority/normal per the 2026-10-26 coordination — remains the tracking vehicle. Recommended next step when Phase 12 work is picked: a design slice first (scheduler placement: world actor vs hub; quota store; benchmark shape on #539's harness), then implementation slices sized to the queue.246 remaining items
dezren39 commentedon Nov 23, 2026
Progress from
felix: per-account quotas slice starting on the decided ownership model (decision note 7088000939): ownership resolution at the charge path (registry > creator-principal config > caller), per-account bound alongside the process-wide guest-burn budget atrun_guest_call, charges settling by actual fuel. Design doc + worktreefelix/1067-per-account-quotasfirst; PR (unmerged, Felix reviews) to follow.fix(id-worlds): queue fuel-refused capability results; back off sched…
id: rustfmt the #1067 account-quota slice
dezren39 commentedon Nov 23, 2026
agent-note:v1
event: progress
by: agent felix (kind muse, Muse sandbox seat; queue fallback claim, worker felix)
at: 2026-11-22
Per-account quotas slice is up for review: #12739 (unmerged; Felix reviews). Design:
doc/2026-11-23_design_id1067-account-quotas.mdon the branch.What landed, on the 2026-11-22 ownership decision (registry > creator-principal configuration > caller):
id-worlds::account_charge:WorldAccountRegistry(JSON config store in the RuntimeLimits idiom;install_shared, first install wins; a malformed file errors rather than reading as empty),WorldChargeConfig/ChargeMode, and the pureresolve_charge_account. A callerless call charges the world's own charge key as its account bucket — visible in the counters, never silently charged to a different account.ChargeResolutionError::CreatorNotRecorded: the guest call does not run, no permit is taken, nothing is charged, a warn log names the world and reason, and the error propagates as the call's error. No silent caller fallback.GuestBurnBudget::acquire_chargedadmits against the process-wide bound and an optional per-account concurrency bound (RuntimeLimits::guest_burn_per_account_concurrency/--world-guest-burn-per-account-concurrency; 0 = none, the default, so an unconfigured hub runs exactly slice-2 admission). Queue-never-refuse preserved; per-waiter eligibility means one account at its bound queues only its own calls. Grant order: least attained service by account, then key, then arrival. Charges settle by actual fuel at both levels;snapshot()gains per-account counters. Pre-accountacquire()delegates with the key as its own account — behaviour-identical for existing callers.WorldInstanceresolves before admission;restore_programinstalls the shared registry and applies the bound. The instance setter surface mirrorsset_charge_key/set_burn_budget.Evidence (laptop, fleet-build-lock): fail-before — the new budget tests on pristine main fail to compile, 10 errors naming the missing APIs. Pass-after — id-worlds filtered suites (guest_burn + account_charge + sandbox) 57/57 including all 14 new tests; id-caps 179/179; id-cli check clean and lib 743 passed with the single failure
test_command_lists_cover_all_clap_subcommands("README CLI Commands table omitswalk") failing identically on pristine main — pre-existing, not this change. Module-reach OK; rustfmt clean; no new dependencies.Honest exit shape: the exit criterion is not claimed — the ratio gap is attributed in BASELINES.md to scheduler contention around the burn path, which a per-account bound does not govern. What changed: per-account fairness and attribution are real at the funnel. Remaining on #1067: the hub scheduler, slow-client back-pressure, caller-principal threading (the funnel still sees participant ids, not accounts — the session layer's resolved
Principaldoes not reach the actor today; until it does, default-mode charges land on the installed caller where one is set and on the world's own bucket otherwise, and no world yet records a creator for mode (a)), and the persistent-spinner profile variant.Note: this issue currently shows CLOSED (closed 2026-11-22T15:56:21Z, at the slice-2 merge) while its own record — the decision note and this slice — treats the quota remainder as open. Flagging for the reviewer rather than reopening from the lane.
dezren39 commentedon Nov 23, 2026
Released by
felix(outcome: free). Per-account quotas slice landed as PR #12739 (unmerged, Felix reviews): ownership resolution (registry > creator config > caller) at the run_guest_call charge path, per-account concurrency bound + per-account LAS fairness in GuestBurnBudget, creator-less creator-mode fails visibly. Evidence: fail-before compile errors on main; laptop id-worlds filtered 57/57 (14 new tests), id-caps 179/179, id-cli 743+1 pre-existing failure identical on main. Remaining on #1067: hub scheduler, slow-client back-pressure, caller-principal threading to the funnel, persistent-spinner profile variant. Note: issue shows CLOSED since the slice-2 merge while its record treats the remainder as open — flagged on the issue for the reviewer.Merge pull request #12739 from developing-today/felix/1067-per-accoun…
dezren39 commentedon Nov 23, 2026
agent-note:v1
event: reopened + slice landed
by: agent felix (kind muse, Muse sandbox seat)
at: 2026-11-22
Reopening: this issue was auto-closed at the slice-2 merge (2026-11-22T15:56:21Z), but its record continues past that point — Drewry's ownership decision landed after the close (comment 7088000939: calling account is the DEFAULT, creator principal and admin registry are per-world OPTIONS, precedence registry > creator-config > caller, directory-derived rejected), and remainder work was explicitly still open. The close was a merge-keyword artifact, not a done verdict.
Landed against the decision: PR #12739 merged 2026-11-23T00:49:53Z — per-account quotas at the run_guest_call funnel. resolve_charge_account implements the decided precedence; the admin registry is a JSON config store in the RuntimeLimits idiom (no UI, as scoped); GuestBurnBudget admits against the process-wide bound AND a per-account concurrency bound (default 0 = unconfigured hub runs exactly slice-2 admission), grant order least-attained-service by account then key then arrival, charges settle by actual fuel at both levels, snapshot gains per-account counters. Creator-less creator-mode worlds fail VISIBLY (typed CreatorNotRecorded error, call does not run, nothing charged) — never silently charged to the caller. Evidence (laptop, build lock): fail-before compile errors naming the new API on pristine main; 57/57 filtered id-worlds tests, id-caps 179/179; the one lib-test failure (README CLI table omits
walk) fails identically on pristine main. No new dependencies. Design: doc/2026-11-23_design_id1067-account-quotas.md.Still open on this issue, unchanged: the exit-shape criterion (ratio ~3.8 vs ≤2 — attributed to spawn/shutdown churn + the blocking round trip, not governed by admission), hub scheduler, slow-client back-pressure, caller-principal threading (the session layer's resolved Principal does not yet reach the actor, so default-mode charges go to the installed caller or the world's own bucket), a world creation record for creator-mode, and the persistent-spinner profile variant. The clippy gate could not run to a verdict on the laptop (venue rustc mix, E0514 in dependency crates, identical on untouched code) —
just checkin the nix dev shell remains the canonical gate for this slice.