Skip to content

feat(console): authoritative membership in the topology lens#208

Open
Lanzelot1 wants to merge 1 commit into
feat/console-participantfrom
feat/console-membership
Open

feat(console): authoritative membership in the topology lens#208
Lanzelot1 wants to merge 1 commit into
feat/console-participantfrom
feat/console-membership

Conversation

@Lanzelot1

Copy link
Copy Markdown
Collaborator

What

Closes the one real gap where the web dashboard beat the console. The topology lens (t) was traffic-derived only — a fold of the last ~120s of messages — so it couldn't show a subscribed-but-silent agent, couldn't distinguish live vs durable-offline membership, and had no freshness signal. It now overlays the broker-authoritative membership feed (readMembership/watchMembership — the exact source the web /graph uses: delivery-daemon CONNZ ∪ durable registry).

  • MeshView reads the feed once + watches it (150ms-debounced re-read), best-effort: on an open mesh or a space with no delivery daemon the read throws and is caught → the lens stays exactly as before (prefillDms-style degrade; never surfaced as a connection error). Exposed as MeshSnapshot.membership.
  • foldTopo merges it onto the traffic graph: silent subscribers become member nodes, subscriptions become resting spokes (live / durable), wide readers (>/*) get a badge (no spoke-per-hub), bounded wildcards (team.>) expand against the channel registry via core subjectMatches, and ids resolve through the roster so a member that also has traffic isn't double-counted. Membership links are kept separate from traffic edges (they have no rate).
  • Renderers: the map (③) draws the full membership skeleton under traffic (live solid-faint, durable/offline dashed) + the wide badge; the matrix (②) shows a light / marker for member-without-traffic cells; the sequence (①) stays a traffic timeline. A header pill reads membership: live / stale / traffic-only.

No core change (the feed + methods already exist); no SPEC change.

Stacked on #206 (feat/console-participant) — retarget to main as the chain merges.

Verified

  • pnpm typecheck clean; smoke:view (MeshView) still green (no regression).
  • New hermetic smoke:topo-membership (15 checks): silent subscriber → member node + live link; durable-offline → durable link; > → wide, no spoke; team.> → expands to both concretes; member-with-traffic → single node (no double-count) with its edge preserved; freshness live/stale; degrade (no feed → empty memberships, available:false, node set identical to a plain fold).
  • Live end-to-end against a sandboxed auth mesh + delivery daemon: an admin observer's MeshView reads the feed (with a daemon asOf heartbeat), a provisioned subscribed-but-silent agent appears in it, and foldTopo surfaces it as a member node with a live spoke to #general — matching the web graph. Plus the real TUI on the open demo mesh shows membership: traffic-only and degrades cleanly.

@Lanzelot1 Lanzelot1 force-pushed the feat/console-participant branch from 8909549 to c6c57ed Compare July 8, 2026 08:35
@Lanzelot1 Lanzelot1 force-pushed the feat/console-membership branch from 63803e6 to d8175e6 Compare July 8, 2026 08:35
@Lanzelot1 Lanzelot1 force-pushed the feat/console-participant branch from c6c57ed to e452a23 Compare July 8, 2026 08:51
@Lanzelot1 Lanzelot1 force-pushed the feat/console-membership branch from d8175e6 to 2e2b20d Compare July 8, 2026 08:51
@Lanzelot1 Lanzelot1 force-pushed the feat/console-participant branch from e452a23 to a9a5f91 Compare July 8, 2026 09:07
@Lanzelot1 Lanzelot1 force-pushed the feat/console-membership branch from 2e2b20d to 260e49f Compare July 8, 2026 09:07
@Lanzelot1 Lanzelot1 force-pushed the feat/console-participant branch from a9a5f91 to 36b9355 Compare July 8, 2026 09:19
@Lanzelot1 Lanzelot1 force-pushed the feat/console-membership branch from 260e49f to 2e2a867 Compare July 8, 2026 09:19
The topology lens was traffic-derived only — it couldn't show a subscribed-
but-silent agent or distinguish live vs durable-offline membership. It now
overlays the broker-authoritative membership feed (readMembership/
watchMembership — the same source as the web graph): MeshView reads and
watches it best-effort, and foldTopo merges silent subscribers as nodes with
live/durable spokes, badges wide readers (>/*), and resolves ids to the
roster so a member with traffic isn't double-counted. A header pill reads
membership: live/stale/traffic-only. The map draws the full skeleton, the
matrix a light marker, the sequence stays a traffic timeline. With no
delivery daemon (or an open mesh) it degrades to exactly the prior view.
@Lanzelot1 Lanzelot1 force-pushed the feat/console-participant branch from 36b9355 to 5dcde20 Compare July 8, 2026 09:42
@Lanzelot1 Lanzelot1 force-pushed the feat/console-membership branch from 2e2a867 to 9fa3f87 Compare July 8, 2026 09:42
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant