Skip to main content

zenkey_fleet/
lib.rs

1//! Fleet engine for keyspace-v2 tooling (issue #15).
2//!
3//! The shared core of `zenctl` and `zengui`: everything a bus explorer needs
4//! that is not presentation. The RFC 05 §2.1 fan-in discipline lives in
5//! exactly one place ([`query::fleet_get`], moved verbatim from zenctl —
6//! target `All`, consolidation `None`, attribution by the reply's own key);
7//! the liveliness roster, registry-slice sets, and the schema-aware decode
8//! seam build on it.
9//!
10//! Sessions opened here are deliberately **un-namespaced** (RFC 09 §5): an
11//! explorer sees the wire as it really is, full keys included — that is what
12//! lets it spot a leak. Do not "fix" this by setting a namespace.
13
14pub mod admin;
15pub mod bench;
16pub mod blob;
17pub mod context_store;
18pub mod diff;
19pub mod discover;
20pub mod facts;
21pub mod ingest;
22pub mod query;
23pub mod record;
24pub mod registry;
25pub mod report;
26pub mod roster;
27pub mod scout;
28pub mod seed;
29pub mod serve;
30pub mod session;
31pub mod skeleton;
32pub mod stats;
33pub mod sub;
34pub mod tree;
35pub mod write;
36
37#[cfg(feature = "decode")]
38pub mod body;
39#[cfg(feature = "decode")]
40pub mod decode;
41#[cfg(feature = "decode")]
42pub mod doctor;
43#[cfg(feature = "decode")]
44pub use body::{
45    BodySource, PrepareMode, PreparedBody, encode_encoding, prepare_publish, prepare_request,
46};
47#[cfg(feature = "decode")]
48pub use decode::{
49    SchemaDrift, TotalityGap, schema_drift, schema_dump, schemas_for_type, totality_gaps,
50};
51#[cfg(feature = "decode")]
52pub use doctor::{CHECK_IDS, DoctorSpec, run_doctor};
53
54pub use admin::{
55    AdminEntry, Coverage, CoverageRow, RouterInfo, StorageInfo, admin_get, routers, state_coverage,
56    storages,
57};
58pub use admin::{DeclaredEntities, DeclaredEntity, EntityKind, declared_entities};
59pub use admin::{
60    OriginAttachment, TopologyEdge, TopologyNode, TopologyReport, origin_attachments, topology,
61};
62pub use bench::{BenchSpec, bench_rpc};
63#[cfg(feature = "blob")]
64pub use blob::{BlobFetchSpec, FETCH_PRIORITY, blob_fetch, blob_probe, blob_tree_index};
65pub use blob::{BlobTarget, blob_list, declared_by};
66pub use context_store::{StoredContext, active_name, cache_dir};
67pub use diff::{ByteDiff, Change, ValueDiff, byte_diff};
68pub use discover::{AliveToken, DiscoveredBase, discover_bases};
69pub use facts::{FactsCache, KeyDescription, KeyFacts, KeyShape, Registration, describe_key};
70pub use ingest::{IngestRow, parse_row};
71pub use query::{
72    Answer, FetchOutcome, FetchSpec, FetchedValue, FleetAnswer, RepeatingQuery, RepeatingRegistry,
73    StateSample, ValueSource, declare_repeating, declare_repeating_any, fetch_value, fleet_get,
74    fleet_get_at, fleet_get_call, fleet_registry, state_snapshot,
75};
76pub use record::{
77    RecordBounds, RecordReport, ReplayEvent, ReplayReport, ReplayTarget, ZREC_VERSION, ZrecHeader,
78    ZrecItem, ZrecReader, ZrecWriter, record, replay,
79};
80pub use registry::SliceSet;
81pub use roster::{
82    BridgeMatch, Freshness, NodeInfo, ProducerInfo, bridge_resolve, node_info, roster,
83};
84pub use scout::{HelloView, ScoutStream, scout};
85pub use seed::{SeedCoverage, SeedItem, SeedPolicy, SeededSubscriber, seed_subscribe};
86pub use serve::{MockResponder, ServedQuery, declare_responder};
87pub use session::{open, open_with_config};
88pub use skeleton::{MergedNode, NodeStatus, Skeleton};
89pub use stats::LatencySummary;
90pub use sub::{
91    EventStream, FleetEvent, Monitor, MonitorCore, MonitorSpec, SampleSource, SampleView,
92    StreamItem, WatchId,
93};
94pub use tree::KeyTreeSnapshot;
95pub use write::{
96    CallTarget, MatchingEvents, Publication, RetireClass, call, check_retire, declare_publication,
97};
98/// The RFC 07 reference client, re-exported so a frontend, an example or a
99/// test cannot end up on a different version of it than the engine.
100#[cfg(feature = "blob")]
101pub use zblob;