Skip to content

Commit 96ae320

Browse files
chore(changeset): bump @agent-bundle/runtime minor and write the consumer-facing summary for #376
1 parent 379caa2 commit 96ae320

1 file changed

Lines changed: 2 additions & 2 deletions

File tree

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
---
2-
"@agent-bundle/runtime": patch
2+
"@agent-bundle/runtime": minor
33
"agent-bundle": patch
44
---
55

6-
Wire the #99 stage-4 `mcp-resource-updated` delivery route into generated stateful MCP servers. `@agent-bundle/runtime/notices` gains `createNoticeInboxSignaller` — one connection's subscription to the reserved inbox resource (`AGENT_NOTICE_INBOX_URI`) that, after each completed render, sends at most one `notifications/resources/updated` for the subscriber's newly eligible pending notices and records it through `signalAvailability()` as an availability receipt (never delivery), honouring `nextAttemptAt` and bounding signals per notice by `retryBudget` across restarts. The ledger gains `reserveAvailability()` / `releaseAvailability()` (and `AgentNotice.availabilityReservation`, `AGENT_NOTICE_AVAILABILITY_RESERVATION_TTL_MS`): the signaller holds a notice's budget slot by compare-and-swap before the wire write so concurrent processes cannot both send, finalizes the hold into the receipt only when the protocol write succeeds, and releases it when the write fails, so a failed send costs no budget and the receipt always means the write succeeded. The hold is renewed while the write is pending (a different key may take it over only after the TTL, and a lapsed holder cannot steal it back), a reserved receipt is recorded only by the key that still holds the slot (otherwise `signalAvailability()` rejects with the new `AgentNoticeError` code `reservation-lost`; a notice acknowledged, expired, or withdrawn while its send was in flight keeps the hold and records the receipt without changing state), and a receipt whose commit failed after a successful send is retried idempotently on the renewal cadence, before later observations, and on `close()`; `unsubscribe()` resolves only after in-flight observations settle; `@agent-bundle/runtime/mount` gains `createGeneratedNoticeRuntime` and `GeneratedRuntimeState.noticeLedger()` so a server process can hold its own handle on the durable store its worker mounts. Generated workspace-durable MCP entries now register `resources/subscribe`/`resources/unsubscribe` for the inbox URI only, advertise `resources.subscribe` exactly when that wiring is active, fail subscriptions closed when the store is unreadable, and the inbox projection exposes the `availability` receipt alongside `exposure`. Volatile lifetimes keep the store in the worker's heap and advertise no subscription capability.
6+
Generated MCP servers with a workspace-durable state lifetime now deliver notices over the `mcp-resource-updated` route: they accept `resources/subscribe` / `resources/unsubscribe` for the reserved inbox resource `AGENT_NOTICE_INBOX_URI`, advertise `resources.subscribe` only when that wiring is active, and send each subscribed session at most one `notifications/resources/updated` per newly eligible pending notice — honouring `nextAttemptAt`, bounded per notice by `retryBudget` across restarts, never duplicated across concurrent server processes over one store, and recorded as an `availability` receipt (never a delivery claim) that the inbox projection exposes beside `exposure`. Subscriptions fail closed when the store is unreadable; volatile lifetimes advertise no subscription capability. `@agent-bundle/runtime/notices` exports `createNoticeInboxSignaller`, `AGENT_NOTICE_AVAILABILITY_RESERVATION_TTL_MS`, and the `AgentNoticeError` code `reservation-lost`; `@agent-bundle/runtime/mount` exports `createGeneratedNoticeRuntime` and `GeneratedRuntimeState.noticeLedger()`. Breaking for implementers of `AgentNoticeLedger`: the interface now requires `reserveAvailability()` and `releaseAvailability()`, and `AgentNotice` gains the optional `availabilityReservation` field. (#376)

0 commit comments

Comments
 (0)