instar 1.3.710 → 1.3.712

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (72) hide show
  1. package/dist/commands/server.d.ts.map +1 -1
  2. package/dist/commands/server.js +228 -1
  3. package/dist/commands/server.js.map +1 -1
  4. package/dist/config/ConfigDefaults.d.ts.map +1 -1
  5. package/dist/config/ConfigDefaults.js +25 -0
  6. package/dist/config/ConfigDefaults.js.map +1 -1
  7. package/dist/core/HttpLeaseTransport.d.ts +9 -0
  8. package/dist/core/HttpLeaseTransport.d.ts.map +1 -1
  9. package/dist/core/HttpLeaseTransport.js +28 -2
  10. package/dist/core/HttpLeaseTransport.js.map +1 -1
  11. package/dist/core/MessagingToneGate.d.ts.map +1 -1
  12. package/dist/core/MessagingToneGate.js +3 -2
  13. package/dist/core/MessagingToneGate.js.map +1 -1
  14. package/dist/core/MultiMachineCoordinator.d.ts +44 -0
  15. package/dist/core/MultiMachineCoordinator.d.ts.map +1 -1
  16. package/dist/core/MultiMachineCoordinator.js +52 -0
  17. package/dist/core/MultiMachineCoordinator.js.map +1 -1
  18. package/dist/core/PeerEndpointResolver.d.ts +0 -0
  19. package/dist/core/PeerEndpointResolver.d.ts.map +1 -1
  20. package/dist/core/PeerEndpointResolver.js +0 -0
  21. package/dist/core/PeerEndpointResolver.js.map +1 -1
  22. package/dist/core/PostUpdateMigrator.d.ts.map +1 -1
  23. package/dist/core/PostUpdateMigrator.js +19 -0
  24. package/dist/core/PostUpdateMigrator.js.map +1 -1
  25. package/dist/core/RopeRecoveryProber.d.ts +126 -0
  26. package/dist/core/RopeRecoveryProber.d.ts.map +1 -0
  27. package/dist/core/RopeRecoveryProber.js +266 -0
  28. package/dist/core/RopeRecoveryProber.js.map +1 -0
  29. package/dist/core/devGatedFeatures.d.ts.map +1 -1
  30. package/dist/core/devGatedFeatures.js +12 -0
  31. package/dist/core/devGatedFeatures.js.map +1 -1
  32. package/dist/core/ropeProbeContract.d.ts +56 -0
  33. package/dist/core/ropeProbeContract.d.ts.map +1 -0
  34. package/dist/core/ropeProbeContract.js +92 -0
  35. package/dist/core/ropeProbeContract.js.map +1 -0
  36. package/dist/core/tailscaleStatusParser.d.ts +46 -0
  37. package/dist/core/tailscaleStatusParser.d.ts.map +1 -0
  38. package/dist/core/tailscaleStatusParser.js +80 -0
  39. package/dist/core/tailscaleStatusParser.js.map +1 -0
  40. package/dist/core/types.d.ts +56 -0
  41. package/dist/core/types.d.ts.map +1 -1
  42. package/dist/core/types.js.map +1 -1
  43. package/dist/monitoring/RopeHealthMonitor.d.ts +243 -0
  44. package/dist/monitoring/RopeHealthMonitor.d.ts.map +1 -0
  45. package/dist/monitoring/RopeHealthMonitor.js +659 -0
  46. package/dist/monitoring/RopeHealthMonitor.js.map +1 -0
  47. package/dist/monitoring/guardManifest.d.ts.map +1 -1
  48. package/dist/monitoring/guardManifest.js +45 -0
  49. package/dist/monitoring/guardManifest.js.map +1 -1
  50. package/dist/scaffold/templates.d.ts.map +1 -1
  51. package/dist/scaffold/templates.js +9 -0
  52. package/dist/scaffold/templates.js.map +1 -1
  53. package/dist/server/AgentServer.d.ts +2 -0
  54. package/dist/server/AgentServer.d.ts.map +1 -1
  55. package/dist/server/AgentServer.js +1 -0
  56. package/dist/server/AgentServer.js.map +1 -1
  57. package/dist/server/CapabilityIndex.js +1 -1
  58. package/dist/server/CapabilityIndex.js.map +1 -1
  59. package/dist/server/routes.d.ts +3 -0
  60. package/dist/server/routes.d.ts.map +1 -1
  61. package/dist/server/routes.js +19 -0
  62. package/dist/server/routes.js.map +1 -1
  63. package/package.json +1 -1
  64. package/scripts/lint-scrape-fixture-realness.js +20 -0
  65. package/src/data/builtin-manifest.json +65 -65
  66. package/src/data/state-coherence-registry.json +17 -0
  67. package/src/scaffold/templates/jobs/instar/rope-health-digest.md +42 -0
  68. package/src/scaffold/templates.ts +9 -0
  69. package/upgrades/1.3.711.md +79 -0
  70. package/upgrades/1.3.712.md +41 -0
  71. package/upgrades/side-effects/tone-gate-rule-id-contract.md +78 -0
  72. package/upgrades/side-effects/u4-rope-probe-alerts.md +140 -0
@@ -0,0 +1,126 @@
1
+ /**
2
+ * RopeRecoveryProber — U4.3 traffic-independent rope-health recovery probe
3
+ * (docs/specs/u4-3-breaker-recovery-probe.md).
4
+ *
5
+ * The hedge transport starves dead ropes: endpoints[0] wins inside hedgeDelayMs
6
+ * and the losers are cancelled, so a dead rope sorted behind a healthy one is
7
+ * never re-dialed — and (before the R-r2-1 transport fix) a cancelled recovering
8
+ * rope had its streak reset by the winner. This prober guarantees dead ropes get
9
+ * DIALED: riding the existing ~5s lease-pull tick (no new loop — the carrier is
10
+ * an attached tick listener), it sends a pinned, signed, bogus-uid canary probe
11
+ * to each probe-eligible (peer, kind) and feeds the typed result into the ONE
12
+ * health authority (`PeerEndpointResolver.recordResult`) — no second state
13
+ * machine; the shipped hysteresis/EWMA own the `lastKnownGood` reclaim.
14
+ *
15
+ * Probe selection is EPISODE-scoped (R-r2-2/R-r3-1/R-r3-2): an episode OPENS
16
+ * when a rope goes dead; while open, the rope stays eligible regardless of the
17
+ * dead flag's momentary state (a fail-after-partial-recovery — recoveryStreak 0,
18
+ * consecutiveFailures 1 — stays in-episode: the limbo fix); it CLOSES when the
19
+ * rope reclaims lastKnownGood (traffic takes over). Within an episode the probe
20
+ * layer owns the cadence in BOTH health states: exponential backoff toward the
21
+ * P19 floor on the failure path, `midIntervalMs` mid-recovery, and the floor
22
+ * after `maxUnreclaimedSuccesses` successes without reclaim (slow-but-alive).
23
+ * Exhaustion (`exhaustAttempts` consecutive failures) drops to the floor cadence
24
+ * and escalates ONCE per (peer, kind, episode) — the Eternal-Sentinel exemption:
25
+ * probing NEVER hard-stops (a healed rope must always be rediscoverable).
26
+ *
27
+ * The probe layer holds SCHEDULING state ONLY (R-r2-4): lastProbeAt, episode
28
+ * markers, and a dry-run shadow streak. Health truth lives solely in the
29
+ * resolver's HealthRecord. Dry-run SENDS real probes (harmless by the typed-
30
+ * refusal contract) with the same due-gate/backoff/floor brakes, logs would-close
31
+ * verdicts from the shadow streak, and never mutates the HealthRecord.
32
+ */
33
+ import type { PeerEndpointResolver } from './PeerEndpointResolver.js';
34
+ import type { MeshEndpoint } from './types.js';
35
+ /** Same base as the resolver's own probe backoff — the failure path widens from here. */
36
+ export declare const PROBE_BACKOFF_BASE_MS = 5000;
37
+ export interface RopeProbeTarget {
38
+ machineId: string;
39
+ kind: MeshEndpoint['kind'];
40
+ url: string;
41
+ }
42
+ export interface RopeProbeSendResult {
43
+ /** TRUE only for the exact typed contract (see ropeProbeContract.parseProbeResponse). */
44
+ typedSuccess: boolean;
45
+ /** Classification/detail for logs + metrics (never surfaced to users). */
46
+ detail: string;
47
+ latencyMs: number;
48
+ }
49
+ export interface RopeRecoveryProberConfig {
50
+ /** Live mode feeds recordResult; dry-run keeps a shadow streak and never mutates health. */
51
+ dryRun: boolean;
52
+ /** P19 floor cadence (max interval) — failure exhaustion AND slow-but-alive both cap here. */
53
+ floorMs: number;
54
+ /** Consecutive probe failures before the exhaustion transition + escalate-once. */
55
+ exhaustAttempts: number;
56
+ /** A close→re-death inside this window is a probe FAILURE for backoff (episode brake). */
57
+ reopenEpisodeWindowMs: number;
58
+ /** Mid-recovery cadence (episode open, rope not dead, lastKnownGood not reclaimed). */
59
+ midIntervalMs: number;
60
+ /** Consecutive successful probes WITHOUT lastKnownGood reclaim before floor cadence. */
61
+ maxUnreclaimedSuccesses: number;
62
+ }
63
+ export interface RopeRecoveryProberDeps {
64
+ resolver: PeerEndpointResolver;
65
+ /** The dialable (peer, kind, url) set — server wiring derives it from the same
66
+ * validated registry view the transport dials (resolver.resolve output). */
67
+ listTargets: () => RopeProbeTarget[];
68
+ /** Send ONE pinned probe (MeshRpcClient envelope → POST <url>/mesh/rpc → typed
69
+ * classification). Must never throw — a transport error is a failure result. */
70
+ sendProbe: (target: RopeProbeTarget) => Promise<RopeProbeSendResult>;
71
+ /** Escalate-once sink (deduped per (peer,kind,episode)). Absent = log-only. */
72
+ raiseAttention?: (item: {
73
+ id: string;
74
+ title: string;
75
+ body: string;
76
+ }) => unknown;
77
+ /** Feature-metrics sink (key `rope-recovery-probe`). Absent = no metrics. */
78
+ recordMetric?: (event: 'probe-sent' | 'probe-success' | 'probe-failure' | 'rope-recovered' | 'exhaustion-trip' | 'slow-alive-floor' | 'dry-run-would-probe' | 'dry-run-would-close') => void;
79
+ now?: () => number;
80
+ logger?: (msg: string) => void;
81
+ }
82
+ /** One row of the /health `ropeHealth` surface (spec §3). */
83
+ export interface RopeHealthViewRow {
84
+ peer: string;
85
+ kind: MeshEndpoint['kind'];
86
+ state: 'healthy' | 'dead' | 'exhausted';
87
+ consecutiveFailures: number;
88
+ recoveryStreak: number;
89
+ lastResultAt: number | null;
90
+ lastProbeAt: number | null;
91
+ nextProbeDueAt: number | null;
92
+ }
93
+ export declare class RopeRecoveryProber {
94
+ private readonly d;
95
+ private readonly cfg;
96
+ /** key = `${peer} ${kind}` (same key shape as the resolver's health map). */
97
+ private readonly ropes;
98
+ /** Single-in-flight CAS per (peer, kind). */
99
+ private readonly inFlight;
100
+ constructor(deps: RopeRecoveryProberDeps, cfg: RopeRecoveryProberConfig);
101
+ private now;
102
+ private log;
103
+ private key;
104
+ /**
105
+ * One carrier tick (attached to the coordinator's lease-pull tick). Scans the
106
+ * resolver snapshot, manages episodes, and fires due probes (fire-and-forget —
107
+ * the CAS prevents overlap; the carrier tick is never blocked on a dial).
108
+ */
109
+ onTick(): void;
110
+ /** The episode-owned cadence (R-r3-2): failure backoff → floor; mid-recovery 45s;
111
+ * slow-but-alive → floor; exhaustion → floor. */
112
+ private currentIntervalMs;
113
+ private onProbeResult;
114
+ private escalate;
115
+ /**
116
+ * The /health `ropeHealth` rows (spec §3): resolver truth + probe scheduling
117
+ * state, per (peer, kind). Served via MultiMachineCoordinator's registration
118
+ * handle into the AUTHED branch only.
119
+ */
120
+ view(): RopeHealthViewRow[];
121
+ /** Test/observability helper — is a probe currently in flight for (peer, kind)? */
122
+ isInFlight(peer: string, kind: string): boolean;
123
+ /** Test helper — the episode-open state for (peer, kind). */
124
+ episodeOpen(peer: string, kind: string): boolean;
125
+ }
126
+ //# sourceMappingURL=RopeRecoveryProber.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"RopeRecoveryProber.d.ts","sourceRoot":"","sources":["../../src/core/RopeRecoveryProber.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GA+BG;AAEH,OAAO,KAAK,EAAE,oBAAoB,EAAyB,MAAM,2BAA2B,CAAC;AAC7F,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,YAAY,CAAC;AAE/C,yFAAyF;AACzF,eAAO,MAAM,qBAAqB,OAAQ,CAAC;AAE3C,MAAM,WAAW,eAAe;IAC9B,SAAS,EAAE,MAAM,CAAC;IAClB,IAAI,EAAE,YAAY,CAAC,MAAM,CAAC,CAAC;IAC3B,GAAG,EAAE,MAAM,CAAC;CACb;AAED,MAAM,WAAW,mBAAmB;IAClC,yFAAyF;IACzF,YAAY,EAAE,OAAO,CAAC;IACtB,0EAA0E;IAC1E,MAAM,EAAE,MAAM,CAAC;IACf,SAAS,EAAE,MAAM,CAAC;CACnB;AAED,MAAM,WAAW,wBAAwB;IACvC,4FAA4F;IAC5F,MAAM,EAAE,OAAO,CAAC;IAChB,8FAA8F;IAC9F,OAAO,EAAE,MAAM,CAAC;IAChB,mFAAmF;IACnF,eAAe,EAAE,MAAM,CAAC;IACxB,0FAA0F;IAC1F,qBAAqB,EAAE,MAAM,CAAC;IAC9B,uFAAuF;IACvF,aAAa,EAAE,MAAM,CAAC;IACtB,wFAAwF;IACxF,uBAAuB,EAAE,MAAM,CAAC;CACjC;AAED,MAAM,WAAW,sBAAsB;IACrC,QAAQ,EAAE,oBAAoB,CAAC;IAC/B;iFAC6E;IAC7E,WAAW,EAAE,MAAM,eAAe,EAAE,CAAC;IACrC;qFACiF;IACjF,SAAS,EAAE,CAAC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AAG;IAGX,OAAO,CAAC,GAAG;IAIX;;;;OAIG;IACH,MAAM,IAAI,IAAI;IAgFd;sDACkD;IAClD,OAAO,CAAC,iBAAiB;IAmBzB,OAAO,CAAC,aAAa;IAgErB,OAAO,CAAC,QAAQ;IAgBhB;;;;OAIG;IACH,IAAI,IAAI,iBAAiB,EAAE;IAoB3B,mFAAmF;IACnF,UAAU,CAAC,IAAI,EAAE,MAAM,EAAE,IAAI,EAAE,MAAM,GAAG,OAAO;IAI/C,6DAA6D;IAC7D,WAAW,CAAC,IAAI,EAAE,MAAM,EAAE,IAAI,EAAE,MAAM,GAAG,OAAO;CAGjD"}
@@ -0,0 +1,266 @@
1
+ /**
2
+ * RopeRecoveryProber — U4.3 traffic-independent rope-health recovery probe
3
+ * (docs/specs/u4-3-breaker-recovery-probe.md).
4
+ *
5
+ * The hedge transport starves dead ropes: endpoints[0] wins inside hedgeDelayMs
6
+ * and the losers are cancelled, so a dead rope sorted behind a healthy one is
7
+ * never re-dialed — and (before the R-r2-1 transport fix) a cancelled recovering
8
+ * rope had its streak reset by the winner. This prober guarantees dead ropes get
9
+ * DIALED: riding the existing ~5s lease-pull tick (no new loop — the carrier is
10
+ * an attached tick listener), it sends a pinned, signed, bogus-uid canary probe
11
+ * to each probe-eligible (peer, kind) and feeds the typed result into the ONE
12
+ * health authority (`PeerEndpointResolver.recordResult`) — no second state
13
+ * machine; the shipped hysteresis/EWMA own the `lastKnownGood` reclaim.
14
+ *
15
+ * Probe selection is EPISODE-scoped (R-r2-2/R-r3-1/R-r3-2): an episode OPENS
16
+ * when a rope goes dead; while open, the rope stays eligible regardless of the
17
+ * dead flag's momentary state (a fail-after-partial-recovery — recoveryStreak 0,
18
+ * consecutiveFailures 1 — stays in-episode: the limbo fix); it CLOSES when the
19
+ * rope reclaims lastKnownGood (traffic takes over). Within an episode the probe
20
+ * layer owns the cadence in BOTH health states: exponential backoff toward the
21
+ * P19 floor on the failure path, `midIntervalMs` mid-recovery, and the floor
22
+ * after `maxUnreclaimedSuccesses` successes without reclaim (slow-but-alive).
23
+ * Exhaustion (`exhaustAttempts` consecutive failures) drops to the floor cadence
24
+ * and escalates ONCE per (peer, kind, episode) — the Eternal-Sentinel exemption:
25
+ * probing NEVER hard-stops (a healed rope must always be rediscoverable).
26
+ *
27
+ * The probe layer holds SCHEDULING state ONLY (R-r2-4): lastProbeAt, episode
28
+ * markers, and a dry-run shadow streak. Health truth lives solely in the
29
+ * resolver's HealthRecord. Dry-run SENDS real probes (harmless by the typed-
30
+ * refusal contract) with the same due-gate/backoff/floor brakes, logs would-close
31
+ * verdicts from the shadow streak, and never mutates the HealthRecord.
32
+ */
33
+ /** Same base as the resolver's own probe backoff — the failure path widens from here. */
34
+ export const PROBE_BACKOFF_BASE_MS = 5_000;
35
+ export class RopeRecoveryProber {
36
+ d;
37
+ cfg;
38
+ /** key = `${peer} ${kind}` (same key shape as the resolver's health map). */
39
+ ropes = new Map();
40
+ /** Single-in-flight CAS per (peer, kind). */
41
+ inFlight = new Set();
42
+ constructor(deps, cfg) {
43
+ this.d = deps;
44
+ this.cfg = cfg;
45
+ }
46
+ now() {
47
+ return (this.d.now ?? Date.now)();
48
+ }
49
+ log(m) {
50
+ this.d.logger?.(`[rope-probe] ${m}`);
51
+ }
52
+ key(peer, kind) {
53
+ return `${peer} ${kind}`;
54
+ }
55
+ /**
56
+ * One carrier tick (attached to the coordinator's lease-pull tick). Scans the
57
+ * resolver snapshot, manages episodes, and fires due probes (fire-and-forget —
58
+ * the CAS prevents overlap; the carrier tick is never blocked on a dial).
59
+ */
60
+ onTick() {
61
+ const nowMs = this.now();
62
+ const targets = this.d.listTargets();
63
+ if (targets.length === 0)
64
+ return; // single-machine / no dialable peers — strict no-op
65
+ const targetByKey = new Map();
66
+ for (const t of targets)
67
+ targetByKey.set(this.key(t.machineId, t.kind), t);
68
+ for (const row of this.d.resolver.snapshot()) {
69
+ const k = this.key(row.peer, row.kind);
70
+ const target = targetByKey.get(k);
71
+ if (!target)
72
+ continue; // not currently dialable (evicted/undiscovered) — nothing to pin
73
+ const st = this.ropes.get(k) ?? { episode: null, lastClosedAt: 0, lastClosedProbeFailures: 0, prevDead: false };
74
+ this.ropes.set(k, st);
75
+ // ── The rope-recovered breadcrumb keys on the DEAD FLAG clearing (R-r2-3). ──
76
+ if (st.prevDead && !row.dead) {
77
+ this.log(`rope-recovered ${row.peer}/${row.kind} (dead flag cleared; lastKnownGood reclaim follows the shipped hysteresis)`);
78
+ this.d.recordMetric?.('rope-recovered');
79
+ }
80
+ st.prevDead = row.dead;
81
+ // ── Episode lifecycle (R-r2-2 / R-r3-1). ──
82
+ if (!st.episode && row.dead) {
83
+ // OPEN. Episode brake: a close→re-death within the reopen window counts as
84
+ // a probe FAILURE for backoff purposes — the new episode's backoff starts
85
+ // widened (overriding the resolver's freshly-reset isProbeDue).
86
+ const braked = st.lastClosedAt > 0 && nowMs - st.lastClosedAt <= this.cfg.reopenEpisodeWindowMs;
87
+ st.episode = {
88
+ openedAt: nowMs,
89
+ // A braked reopen also DEFERS its first probe by the widened interval
90
+ // (lastProbeAt seeded to now) — an immediate re-probe per episode would
91
+ // let a flapping rope cycle hot at the reopen rate.
92
+ lastProbeAt: braked ? nowMs : 0,
93
+ probeFailures: braked ? st.lastClosedProbeFailures + 1 : 0,
94
+ unreclaimedSuccesses: 0,
95
+ exhausted: false,
96
+ escalatedExhaust: false,
97
+ escalatedSlowAlive: false,
98
+ shadowStreak: 0,
99
+ shadowWouldClose: false,
100
+ };
101
+ this.log(`episode open ${row.peer}/${row.kind}${braked ? ' (reopen brake: backoff widened)' : ''}`);
102
+ }
103
+ else if (st.episode && row.lastKnownGood) {
104
+ // CLOSE — lastKnownGood reclaimed; traffic takes over.
105
+ st.lastClosedAt = nowMs;
106
+ st.lastClosedProbeFailures = st.episode.probeFailures;
107
+ this.log(`episode close ${row.peer}/${row.kind} (lastKnownGood reclaimed)`);
108
+ st.episode = null;
109
+ }
110
+ const ep = st.episode;
111
+ if (!ep)
112
+ continue;
113
+ // ── Probe-layer due gate — owns the cadence in BOTH modes (R-r2-4a). ──
114
+ const interval = this.currentIntervalMs(ep, row);
115
+ if (ep.lastProbeAt !== 0 && nowMs - ep.lastProbeAt < interval)
116
+ continue;
117
+ if (this.inFlight.has(k))
118
+ continue; // single-in-flight CAS
119
+ this.inFlight.add(k);
120
+ ep.lastProbeAt = nowMs;
121
+ this.d.recordMetric?.(this.cfg.dryRun ? 'dry-run-would-probe' : 'probe-sent');
122
+ // Fire-and-forget: the tick is a carrier, never blocked on a dial.
123
+ void this.d
124
+ .sendProbe(target)
125
+ .then((res) => this.onProbeResult(k, row, res))
126
+ .catch((err) => {
127
+ // A sendProbe seam that throws despite its contract is a failure result.
128
+ this.onProbeResult(k, row, {
129
+ typedSuccess: false,
130
+ detail: `send-error: ${err instanceof Error ? err.message : String(err)}`,
131
+ latencyMs: 0,
132
+ });
133
+ })
134
+ .finally(() => {
135
+ this.inFlight.delete(k);
136
+ });
137
+ }
138
+ }
139
+ /** The episode-owned cadence (R-r3-2): failure backoff → floor; mid-recovery 45s;
140
+ * slow-but-alive → floor; exhaustion → floor. */
141
+ currentIntervalMs(ep, row) {
142
+ if (ep.exhausted)
143
+ return this.cfg.floorMs;
144
+ // In dry-run the HealthRecord is never probe-fed, so `row.dead` stays true
145
+ // even while probes SUCCEED — the shadow streak stands in for the dead-clear
146
+ // so a succeeding dry-run rope rides the mid-recovery cadence (and then the
147
+ // slow-alive floor), never a hot 5s loop (R-r2-4a: the floor applies in
148
+ // dry-run too).
149
+ const shadowRecovered = this.cfg.dryRun && ep.shadowStreak > 0;
150
+ const failurePath = ep.probeFailures > 0 || (row.dead && !shadowRecovered);
151
+ if (failurePath) {
152
+ const exp = Math.min(ep.probeFailures, 30); // 2^30 clamp — floorMs caps anyway
153
+ return Math.min(this.cfg.floorMs, PROBE_BACKOFF_BASE_MS * 2 ** exp);
154
+ }
155
+ // Mid-recovery (in-episode, not dead, not reclaimed): the probe layer's own
156
+ // cadence — NEVER the resolver's trivially-true ~5s (the 17k/day shape).
157
+ if (ep.unreclaimedSuccesses >= this.cfg.maxUnreclaimedSuccesses)
158
+ return this.cfg.floorMs;
159
+ return this.cfg.midIntervalMs;
160
+ }
161
+ onProbeResult(k, rowAtSend, res) {
162
+ const st = this.ropes.get(k);
163
+ const ep = st?.episode;
164
+ if (!st || !ep)
165
+ return; // episode closed while the probe was in flight — result moot
166
+ const [peer, kind] = [rowAtSend.peer, rowAtSend.kind];
167
+ if (res.typedSuccess) {
168
+ this.d.recordMetric?.('probe-success');
169
+ ep.probeFailures = 0;
170
+ ep.unreclaimedSuccesses += 1;
171
+ if (ep.exhausted) {
172
+ // Re-arm: any success clears exhaustion and re-enables the normal backoff.
173
+ ep.exhausted = false;
174
+ this.log(`exhaustion cleared ${peer}/${kind} (typed success — re-armed)`);
175
+ }
176
+ if (this.cfg.dryRun) {
177
+ ep.shadowStreak += 1;
178
+ if (!ep.shadowWouldClose) {
179
+ ep.shadowWouldClose = true;
180
+ this.log(`dry-run would-close ${peer}/${kind}: first typed success would clear the dead flag (shadow streak ${ep.shadowStreak})`);
181
+ this.d.recordMetric?.('dry-run-would-close');
182
+ }
183
+ }
184
+ else {
185
+ this.d.resolver.recordResult(peer, kind, true, res.latencyMs);
186
+ }
187
+ if (ep.unreclaimedSuccesses === this.cfg.maxUnreclaimedSuccesses &&
188
+ !ep.escalatedSlowAlive) {
189
+ // Slow-but-alive: answers probes but the EWMA keeps it below the reclaim
190
+ // bar — drop to floor cadence + the same escalate-once posture.
191
+ ep.escalatedSlowAlive = true;
192
+ this.d.recordMetric?.('slow-alive-floor');
193
+ this.escalate(`rope-probe-slow-alive:${peer}:${kind}:${ep.openedAt}`, `Mesh rope ${kind} answers probes but stays demoted`, `The ${kind} rope to peer ${peer} has answered ${ep.unreclaimedSuccesses} consecutive recovery probes but has not reclaimed preferred status — latency above the reclaim bar. Probing continues at the floor cadence.`);
194
+ }
195
+ }
196
+ else {
197
+ this.d.recordMetric?.('probe-failure');
198
+ ep.probeFailures += 1;
199
+ ep.unreclaimedSuccesses = 0;
200
+ if (this.cfg.dryRun) {
201
+ ep.shadowStreak = 0;
202
+ }
203
+ else {
204
+ this.d.resolver.recordResult(peer, kind, false, res.latencyMs);
205
+ }
206
+ this.log(`probe failed ${peer}/${kind} (${res.detail}; consecutive ${ep.probeFailures})`);
207
+ if (ep.probeFailures >= this.cfg.exhaustAttempts && !ep.exhausted) {
208
+ ep.exhausted = true;
209
+ this.d.recordMetric?.('exhaustion-trip');
210
+ if (!ep.escalatedExhaust) {
211
+ ep.escalatedExhaust = true; // escalate ONCE per (peer, kind, episode)
212
+ this.escalate(`rope-probe-exhausted:${peer}:${kind}:${ep.openedAt}`, `Mesh rope ${kind} not recovering`, `The ${kind} rope to peer ${peer} has failed ${ep.probeFailures} recovery probes; probing continues at the floor rate (${Math.round(this.cfg.floorMs / 60000)} min).`);
213
+ }
214
+ }
215
+ }
216
+ }
217
+ escalate(id, title, body) {
218
+ try {
219
+ const r = this.d.raiseAttention?.({ id, title, body });
220
+ if (r && typeof r.catch === 'function') {
221
+ void r.catch(() => {
222
+ // @silent-fallback-ok: escalation is best-effort observability — the probe
223
+ // itself keeps running at the floor; the item re-arms on the next episode.
224
+ });
225
+ }
226
+ this.log(`escalated: ${title}`);
227
+ }
228
+ catch {
229
+ // @silent-fallback-ok: same as above — a throwing attention sink must never
230
+ // break the probe loop (signal, not authority).
231
+ }
232
+ }
233
+ /**
234
+ * The /health `ropeHealth` rows (spec §3): resolver truth + probe scheduling
235
+ * state, per (peer, kind). Served via MultiMachineCoordinator's registration
236
+ * handle into the AUTHED branch only.
237
+ */
238
+ view() {
239
+ const nowRows = [];
240
+ for (const row of this.d.resolver.snapshot()) {
241
+ const st = this.ropes.get(this.key(row.peer, row.kind));
242
+ const ep = st?.episode ?? null;
243
+ const lastResultAt = Math.max(row.lastOkAt, row.lastFailAt);
244
+ nowRows.push({
245
+ peer: row.peer,
246
+ kind: row.kind,
247
+ state: ep?.exhausted ? 'exhausted' : row.dead ? 'dead' : 'healthy',
248
+ consecutiveFailures: row.consecutiveFailures,
249
+ recoveryStreak: row.recoveryStreak,
250
+ lastResultAt: lastResultAt > 0 ? lastResultAt : null,
251
+ lastProbeAt: ep && ep.lastProbeAt > 0 ? ep.lastProbeAt : null,
252
+ nextProbeDueAt: ep ? (ep.lastProbeAt === 0 ? this.now() : ep.lastProbeAt + this.currentIntervalMs(ep, row)) : null,
253
+ });
254
+ }
255
+ return nowRows;
256
+ }
257
+ /** Test/observability helper — is a probe currently in flight for (peer, kind)? */
258
+ isInFlight(peer, kind) {
259
+ return this.inFlight.has(this.key(peer, kind));
260
+ }
261
+ /** Test helper — the episode-open state for (peer, kind). */
262
+ episodeOpen(peer, kind) {
263
+ return !!this.ropes.get(this.key(peer, kind))?.episode;
264
+ }
265
+ }
266
+ //# sourceMappingURL=RopeRecoveryProber.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"RopeRecoveryProber.js","sourceRoot":"","sources":["../../src/core/RopeRecoveryProber.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GA+BG;AAKH,yFAAyF;AACzF,MAAM,CAAC,MAAM,qBAAqB,GAAG,KAAK,CAAC;AAuF3C,MAAM,OAAO,kBAAkB;IACZ,CAAC,CAAyB;IAC1B,GAAG,CAA2B;IAC/C,6EAA6E;IAC5D,KAAK,GAAG,IAAI,GAAG,EAAwB,CAAC;IACzD,6CAA6C;IAC5B,QAAQ,GAAG,IAAI,GAAG,EAAU,CAAC;IAE9C,YAAY,IAA4B,EAAE,GAA6B;QACrE,IAAI,CAAC,CAAC,GAAG,IAAI,CAAC;QACd,IAAI,CAAC,GAAG,GAAG,GAAG,CAAC;IACjB,CAAC;IAEO,GAAG;QACT,OAAO,CAAC,IAAI,CAAC,CAAC,CAAC,GAAG,IAAI,IAAI,CAAC,GAAG,CAAC,EAAE,CAAC;IACpC,CAAC;IACO,GAAG,CAAC,CAAS;QACnB,IAAI,CAA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C,IAAI,EAAE,IAAI,CAAC,CAAC,CAAC;IACjD,CAAC;IAED,6DAA6D;IAC7D,WAAW,CAAC,IAAY,EAAE,IAAY;QACpC,OAAO,CAAC,CAAC,IAAI,CAAC,KAAK,CAAC,GAAG,CAAC,IAAI,CAAC,GAAG,CAAC,IAAI,EAAE,IAAI,CAAC,CAAC,EAAE,OAAO,CAAC;IACzD,CAAC;CACF"}
@@ -1 +1 @@
1
- {"version":3,"file":"devGatedFeatures.d.ts","sourceRoot":"","sources":["../../src/core/devGatedFeatures.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;GAwBG;AAEH,oEAAoE;AACpE,MAAM,WAAW,eAAe;IAC9B,mEAAmE;IACnE,IAAI,EAAE,MAAM,CAAC;IACb,uEAAuE;IACvE,UAAU,EAAE,MAAM,CAAC;IACnB,6DAA6D;IAC7D,WAAW,EAAE,MAAM,CAAC;IACpB;;;;;;OAMG;IACH,aAAa,EAAE,MAAM,CAAC;CACvB;AAED,eAAO,MAAM,kBAAkB,EAAE,eAAe,EA0a/C,CAAC;AAEF;;;;;;;;;;;;;;;;;;;;;;;GAuBG;AACH,MAAM,MAAM,gBAAgB,GACxB,aAAa,GACb,cAAc,GACd,gBAAgB,GAChB,sBAAsB,GACtB,iBAAiB,CAAC;AAEtB,MAAM,WAAW,iBAAiB;IAChC,uEAAuE;IACvE,UAAU,EAAE,MAAM,CAAC;IACnB,6CAA6C;IAC7C,QAAQ,EAAE,gBAAgB,CAAC;IAC3B,mFAAmF;IACnF,MAAM,EAAE,MAAM,CAAC;CAChB;AAED,eAAO,MAAM,oBAAoB,EAAE,iBAAiB,EAgJnD,CAAC;AAEF;;;GAGG;AACH,wBAAgB,eAAe,CAAC,MAAM,EAAE,OAAO,EAAE,UAAU,EAAE,MAAM,GAAG,OAAO,CAO5E"}
1
+ {"version":3,"file":"devGatedFeatures.d.ts","sourceRoot":"","sources":["../../src/core/devGatedFeatures.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;GAwBG;AAEH,oEAAoE;AACpE,MAAM,WAAW,eAAe;IAC9B,mEAAmE;IACnE,IAAI,EAAE,MAAM,CAAC;IACb,uEAAuE;IACvE,UAAU,EAAE,MAAM,CAAC;IACnB,6DAA6D;IAC7D,WAAW,EAAE,MAAM,CAAC;IACpB;;;;;;OAMG;IACH,aAAa,EAAE,MAAM,CAAC;CACvB;AAED,eAAO,MAAM,kBAAkB,EAAE,eAAe,EAsb/C,CAAC;AAEF;;;;;;;;;;;;;;;;;;;;;;;GAuBG;AACH,MAAM,MAAM,gBAAgB,GACxB,aAAa,GACb,cAAc,GACd,gBAAgB,GAChB,sBAAsB,GACtB,iBAAiB,CAAC;AAEtB,MAAM,WAAW,iBAAiB;IAChC,uEAAuE;IACvE,UAAU,EAAE,MAAM,CAAC;IACnB,6CAA6C;IAC7C,QAAQ,EAAE,gBAAgB,CAAC;IAC3B,mFAAmF;IACnF,MAAM,EAAE,MAAM,CAAC;CAChB;AAED,eAAO,MAAM,oBAAoB,EAAE,iBAAiB,EAgJnD,CAAC;AAEF;;;GAGG;AACH,wBAAgB,eAAe,CAAC,MAAM,EAAE,OAAO,EAAE,UAAU,EAAE,MAAM,GAAG,OAAO,CAO5E"}
@@ -54,6 +54,18 @@ export const DEV_GATED_FEATURES = [
54
54
  description: 'Cross-machine coherence journal.',
55
55
  justification: 'Append-only local journal of content-free lifecycle events; no egress, no spend, no destructive action.',
56
56
  },
57
+ {
58
+ name: 'ropeRecoveryProbe',
59
+ configPath: 'multiMachine.meshTransport.recoveryProbeEnabled',
60
+ description: 'U4.3 traffic-independent rope-health recovery probe — rides the lease-pull tick, sends pinned signed bogus-uid canary probes to dead mesh ropes and feeds the typed result into the ONE health authority (PeerEndpointResolver.recordResult), so a healed rope closes in minutes instead of staying presumed-dead (the week-long Tailscale strand).',
61
+ justification: 'Ships recoveryProbeDryRun:true (the dry-run canary): dry-run SENDS real probes — harmless by the typed-refusal payload contract (a signed bogus-uid deliverMessage the peer answers with not-router/sender-rejected; nothing can ever be injected) — but never mutates the HealthRecord. The only user-facing egress is the DEDUPED escalate-once attention item per (peer, kind, episode) — bounded, episode-keyed output, the same posture as the degradationLadderNeverSilent precedent already in this registry — so it is safe AND runnable live-on-dev rather than an action-bearing DARK_GATE_EXCLUSIONS case. P19 Eternal-Sentinel floor (15 min) bounds a permanently-dead rope in BOTH modes; no spend, no destructive action.',
62
+ },
63
+ {
64
+ name: 'ropeHealthAlerts',
65
+ configPath: 'monitoring.ropeHealth.enabled',
66
+ description: 'U4.5 rope-health alerts — the in-server RopeHealthMonitor: a bounded 30s evaluation loop over the U4.3 resolver snapshot with deterministic sleep-aware classification (ok/degraded/peer-offline/urgent), episode-deduped HIGH partition alerts, Tailscale key-expiry warnings, GET /mesh/rope-health, and the rope-health-digest daily job.',
67
+ justification: 'The urgent tier auto-posts HIGH attention items, which normally pushes a feature into DARK_GATE_EXCLUSIONS\' action-bearing category. This takes the OTHER branch deliberately (R-r2-6): the only egress is EPISODE-DEDUPED (ONE HIGH item per (machine-pair, episode); an already-open split-brain item wins and suppresses it), SLEEP-GATED (the mesh-independent git-synced heartbeat discriminator kills the lid-close false-alarm class by construction — a sleeping machine stops writing heartbeats, so it classifies peer-offline, never urgent), and it is OPERATOR-MANDATED partition alerting — the silent-partition gap is the incident class the operator directed this project to close. Same bounded-escalation posture as the degradationLadderNeverSilent precedent already in this registry. No spend (deterministic classifier, zero LLM), no destructive action; the digest job logs only until digestTopicId is set.',
68
+ },
57
69
  {
58
70
  name: 'warmSessionA2A',
59
71
  configPath: 'threadline.warmSessionA2A.enabled',
@@ -1 +1 @@
1
- {"version":3,"file":"devGatedFeatures.js","sourceRoot":"","sources":["../../src/core/devGatedFeatures.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;GAwBG;AAoBH,MAAM,CAAC,MAAM,kBAAkB,GAAsB;IACnD;QACE,IAAI,EAAE,yBAAyB;QAC/B,UAAU,EAAE,6CAA6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E,uMAAuM;KAChN;IACD;QACE,UAAU,EAAE,kDAAkD;QAC9D,QAAQ,EAAE,gBAAgB;QAC1B,MAAM,EAAE,ymBAAymB;KAClnB;IACD;QACE,UAAU,EAAE,2CAA2C;QACvD,QAAQ,EAAE,gBAAgB;QAC1B,MAAM,EAAE,gXAAgX;KACzX;IACD;QACE,UAAU,EAAE,6CAA6C;QACzD,QAAQ,EAAE,gBAAgB;QAC1B,MAAM,EAAE,uVAAuV;KAChW;IACD,sDAAsD;IACtD;QACE,UAAU,EAAE,uCAAuC;QACnD,QAAQ,EAAE,cAAc;QACxB,MAAM,EAAE,wXAAwX;KACjY;IACD,gFAAgF;IAChF,uFAAuF;IACvF;QACE,UAAU,EAAE,gBAAgB;QAC5B,QAAQ,EAAE,sBAAsB;QAChC,MAAM,EAAE,8NAA8N;KACvO;IACD;QACE,UAAU,EAAE,gBAAgB;QAC5B,QAAQ,EAAE,sBAAsB;QAChC,MAAM,EAAE,gQAAgQ;KACzQ;CACF,CAAC;AAEF;;;GAGG;AACH,MAAM,UAAU,eAAe,CAAC,MAAe,EAAE,UAAkB;IACjE,IAAI,GAAG,GAAY,MAAM,CAAC;IAC1B,KAAK,MAAM,GAAG,IAAI,UAAU,CAAC,KAAK,CAAC,GAAG,CAAC,EAAE,CAAC;QACxC,IAAI,GAAG,IAAI,IAAI,IAAI,OAAO,GAAG,KAAK,QAAQ;YAAE,OAAO,SAAS,CAAC;QAC7D,GAAG,GAAI,GAA+B,CAAC,GAAG,CAAC,CAAC;IAC9C,CAAC;IACD,OAAO,GAAG,CAAC;AACb,CAAC"}
@@ -0,0 +1,56 @@
1
+ /**
2
+ * ropeProbeContract — the U4.3 recovery probe's payload + typed-response contract
3
+ * (docs/specs/u4-3-breaker-recovery-probe.md §2 "Probe success is the exact typed
4
+ * contract, never any-2xx").
5
+ *
6
+ * The probe reuses the G4 delivery-canary PAYLOAD contract: a signed, bogus-uid
7
+ * `deliverMessage` MeshRpc command the peer answers with a TYPED refusal per its
8
+ * role — `not-router` (403, RBAC: we are not the lease holder in the peer's view)
9
+ * or `sender-rejected` (200 ack, the peer's sender re-validation refused the
10
+ * bogus uid). Either typed refusal PROVES the whole path: transport connect +
11
+ * signed envelope verified + the peer's real dispatcher answered. A malformed,
12
+ * untyped, or unsigned 2xx (captive portal, wrong server) is a FAILURE.
13
+ *
14
+ * `parseProbeResponse` is the REGISTERED parser (Scrape/Parser Fixture Realness):
15
+ * it consumes the RAW response body bytes + HTTP status, and its tests feed it
16
+ * captured byte-for-byte fixtures of real /mesh/rpc responses (see
17
+ * tests/fixtures/captured/mesh-rpc-probe-responses/ + SCRAPE_PARSERS in
18
+ * scripts/lint-scrape-fixture-realness.js).
19
+ */
20
+ import type { MeshCommand } from './MeshRpc.js';
21
+ /**
22
+ * A deliberately-unresolvable sender uid (no Telegram uid is ever this value and
23
+ * the users registry can never contain it) — the "bogus uid" of the G4 canary
24
+ * payload contract. The peer's sender re-validation refuses it with the typed
25
+ * `sender-rejected` ack; it can never inject a real message.
26
+ */
27
+ export declare const ROPE_PROBE_BOGUS_UID = 999999999999;
28
+ /** The session-key prefix — non-numeric BY DESIGN so no topic-shaped consumer
29
+ * (working-set trigger, spawn bridge — both `Number(session)`-gated) can ever
30
+ * act on a probe, and the SenderRejectionNoticer's user-topic exclusion holds. */
31
+ export declare const ROPE_PROBE_SESSION_PREFIX = "rope-probe:";
32
+ /**
33
+ * Build the probe command. `ownershipEpoch: 0` + an unknown session means the
34
+ * stale-ownership fence passes through to sender re-validation (ownerEpochOf on
35
+ * an unknown session is null), so the answer is deterministic per role.
36
+ */
37
+ export declare function buildRopeProbeCommand(selfMachineId: string, nonce: string): MeshCommand;
38
+ export type RopeProbeClassification = 'ack-sender-rejected' | 'refused-not-router' | 'untyped-2xx' | 'auth-rejected' | 'accepted-not-refused' | 'malformed' | 'http-error';
39
+ export interface RopeProbeVerdict {
40
+ /** TRUE only for the two typed refusals — the exact contract; any-2xx never closes. */
41
+ typedSuccess: boolean;
42
+ classification: RopeProbeClassification;
43
+ /** The dispatcher's typed reason / ack value, when one parsed (for logs). */
44
+ detail?: string;
45
+ }
46
+ /**
47
+ * Classify a raw /mesh/rpc probe response (REGISTERED parser — fed captured
48
+ * byte-for-byte fixtures in tests). Success is the EXACT typed contract:
49
+ * - 403 with dispatcher reason `not-router` (peer refused our non-router send), OR
50
+ * - 200 ack `{ result: { accepted: 'sender-rejected' } }` (peer's sender
51
+ * re-validation refused the bogus uid).
52
+ * EVERYTHING else — an untyped 2xx, a malformed body, an unsigned/unknown-sender
53
+ * rejection, or an unexpected acceptance — records as FAILURE.
54
+ */
55
+ export declare function parseProbeResponse(rawBody: string, status: number): RopeProbeVerdict;
56
+ //# sourceMappingURL=ropeProbeContract.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"ropeProbeContract.d.ts","sourceRoot":"","sources":["../../src/core/ropeProbeContract.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;GAkBG;AAEH,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,cAAc,CAAC;AAEhD;;;;;GAKG;AACH,eAAO,MAAM,oBAAoB,eAAkB,CAAC;AAEpD;;mFAEmF;AACnF,eAAO,MAAM,yBAAyB,gBAAgB,CAAC;AAEvD;;;;GAIG;AACH,wBAAgB,qBAAqB,CAAC,aAAa,EAAE,MAAM,EAAE,KAAK,EAAE,MAAM,GAAG,WAAW,CAUvF;AAED,MAAM,MAAM,uBAAuB,GAC/B,qBAAqB,GACrB,oBAAoB,GACpB,aAAa,GACb,eAAe,GACf,sBAAsB,GACtB,WAAW,GACX,YAAY,CAAC;AAEjB,MAAM,WAAW,gBAAgB;IAC/B,uFAAuF;IACvF,YAAY,EAAE,OAAO,CAAC;IACtB,cAAc,EAAE,uBAAuB,CAAC;IACxC,6EAA6E;IAC7E,MAAM,CAAC,EAAE,MAAM,CAAC;CACjB;AAED;;;;;;;;GAQG;AACH,wBAAgB,kBAAkB,CAAC,OAAO,EAAE,MAAM,EAAE,MAAM,EAAE,MAAM,GAAG,gBAAgB,CAyCpF"}