diff --git a/docs/plans/2026-08-18-mesh-reconnect-plan.md b/docs/plans/2026-08-18-mesh-reconnect-plan.md index ca91795..e9da086 100644 --- a/docs/plans/2026-08-18-mesh-reconnect-plan.md +++ b/docs/plans/2026-08-18-mesh-reconnect-plan.md @@ -85,6 +85,12 @@ not a wait for `timeoutMs`. 3. **Manifest comparison.** Capture the contributed set at boot, compare per D4, reuse `compilePattern(...).shape` for routes. Refusal logs the missing token or route by name. 4. **`invalidateRemoteBindings(link)`** per D8, called on successful reconnect. + + **Note, 2026-09-06:** this no longer exists. When the mesh stopped exporting providers, the + remote app-scope binding went with it, and `invalidateRemoteBindings`, the `rebind` array and the + `onReconnect` callback went with that — there is no cached value left to invalidate, so a + reconnected link is simply usable again on the next RPC. The rest of this plan shipped as + written; only this step has no counterpart in the code. 5. **Config**: `mesh: { reconnect?: boolean | { initialDelayMs?, maxDelayMs? }, onManifestChange?: 'refuse' }`. Reconnect defaults **on**. Validate at boot like the other mesh options. 6. **Tests.** Reconnect after the teapot returns; refuse when a token disappears, with the message diff --git a/src/app/types.ts b/src/app/types.ts index 1483896..e597582 100644 --- a/src/app/types.ts +++ b/src/app/types.ts @@ -145,7 +145,9 @@ export interface MeshConfig { * one of its tokens still fails the boot, naming it. A permanent refusal — a wrong secret, a * protocol mismatch — fails at once without spending the grace. * - * `0` restores the old behaviour of a single attempt. + * `0` means one attempt and no grace. That is the attempt count boot used to have, and nothing + * more: exhausting it no longer fails the boot, so a single unreachable teapot still warns and + * starts. To make a teapot's absence fatal, have something local `@needs` one of its tokens. */ bootTimeoutMs?: number; } diff --git a/src/mesh/protocol.ts b/src/mesh/protocol.ts index 85d082f..2af6f86 100644 --- a/src/mesh/protocol.ts +++ b/src/mesh/protocol.ts @@ -18,6 +18,14 @@ * * Bumping per change would make the number mean "work happened" rather than "we are * incompatible", which is the one thing it is here to say. + * + * **One exception has been taken, and its terms are the point.** The manifest's `scopes` field was + * renamed to `steps` at v1 — a rename, which the first rule above would otherwise cover — without a + * bump. It was allowed because there is no deployed pair the rename could split: mesh is alpha, + * every app using it is gated behind `experimental: true`, and both peers ship out of this one + * repo, so a teacup and a teapot are always on the same version. Each of those three has to hold + * for the exception to; the first mesh release that drops `experimental` retires it, and a rename + * after that earns a bump like any other. */ export const MESH_PROTOCOL_VERSION = 1;