Skip to main content

Module admin

Module admin 

Source
Expand description

Zenoh admin-space access (issue #14): browse @/** — the middleware’s own introspection — from the same un-namespaced session the convention tooling already holds (a namespaced session’s admin selector would be rewritten and match nothing, RFC 09 §5).

Admin key layouts vary between zenoh versions (report §3.1’s caveat), so this module stays a thin, honest transport: keys + JSON values, no hardcoded schema. routers extracts the few fields every 1.x layout carries, and leaves the rest visible in raw.

Structs§

AdminEntry
One admin-space entry.
CoverageRow
DeclaredEntities
The declared-entity sweep result.
DeclaredEntity
One declared entity, as the admin space reports it: the reply key is @/<zid>/<whatami>/<kind>/<declared-keyexpr...>, so the keyexpr every session declared is readable without subscribing to any data — the payload-free discovery leg of issue #84.
OriginAttachment
One liveliness origin attached to the session that declared its token — the #131 join, evidence-first: an attachment is made only from what the admin space actually said, never guessed (a guessed attachment would be the O4 failure on a picture).
RouterInfo
A router (or peer) as the admin space reports it.
StorageInfo
One configured storage, as the admin space reports it.
TopologyEdge
One reported link. Kept per-reporter — a renderer that wants an undirected mesh dedups by unordered zid pair, and reciprocal reports are corroboration, not duplication.
TopologyNode
One node of the mesh, as the topology join sees it (#118).
TopologyReport
The mesh as the admin space answered it, joined with nothing invented (#118): what answered, what was only mentioned, and who we are.

Enums§

Coverage
How a declared state family relates to the configured storages.
EntityKind
What kind of declared entity an admin reply describes.

Functions§

admin_get
GET an admin selector (default @/**). Fans to every node (target All, consolidation None — several routers may answer).
declared_entities
Enumerate declared subscribers/publishers/queryables/tokens from every reachable admin space.
declared_from_admin_entry
Parse one admin entry (@/<zid>/<whatami>/<kind>/<keyexpr...>) into a declared entity. Pure; unknown shapes yield None (the admin space is version-dependent surface — tolerate, never fail).
merge_storage_rows
One row per (zid, name), merging field by field.
origin_attachments
Join the admin space’s declared liveliness tokens against the keyspace: which origin hangs off which session (#131).
routers
Enumerate routers/peers from @/*/router (and the fields every layout carries).
state_coverage
Judge every declared state family against the configured storages (issue #14): the family’s wire selector vs each storage’s key expression, by key algebra (includes ⇒ covered, intersects ⇒ partial). Pure.
storage_from_admin_entry
Extract a storage from one admin entry, tolerantly: the key shape is @/<zid>/router/…/storage_manager/storages/<name>[…], the value a config document whose key_expr field names what it captures. Pure — the version-variance lives here, unit-tested.
storages
Enumerate configured storages across the mesh (issue #14). Zero routers (peer mesh, admin disabled) is an empty vec, never an error.
topology
Join the admin root docs (@/<zid>/<whatami>) into a topology: every answering node with its locators and version, every session it reports as an edge, and every zid that is only mentioned as a heard-of-not-queryable node.