crates/nornir-wire/src/view/mod.rs
//! # `view` — the serde view-model DTOs that cross the nornir gRPC wire
//!
//! These are the **wire-stable shapes** the `nornir-server` producers serialize
//! to JSON and the read-client(s) (`viz::remote`, a future `facett-nornir-viz`)
//! deserialize back — the ONE home for the view-model types, so a consumer can
//! depend on `nornir-wire` alone (never on `nornir`) and still decode every
//! `Viz.*` / `Workspaces.*` payload.
//!
//! ## Relocated, not mirrored
//!
//! The design (`nornir-viz-to-facett-execplan`) offered two tactics for moving a
//! view-model type here: **relocate** (move the struct, re-export from nornir so
//! producers/panes compile unchanged) or **mirror** (define a plain twin here,
//! keep nornir's type, convert at the boundary). Mirror is only needed when the
//! nornir type carries non-serde / Arrow / redb guts that cannot leave the crate.
//!
//! An on-disk audit found that **none** of the live wire-crossing view-model
//! types carry such guts:
//! - [`timeline::Timeline`] is plain serde; its one non-scalar field is a
//! [`nornir_depgraph::DepGraphSnapshot`], which already lives in the
//! `nornir-depgraph` **leaf** (the doc's "embeds `warehouse::dep_graph`" was a
//! pre-leaf-extraction snapshot — `warehouse::dep_graph` merely re-exports the
//! leaf type). So the timeline model relocates whole and re-uses the leaf type
//! directly — no snapshot mirror.
//! - The row DTOs ([`rows::RosterRow`], [`rows::CloneEventRow`]) are plain serde
//! structs with no inherent Arrow impls; the Arrow encode/decode in their old
//! nornir home are free functions over the public fields, so relocating the
//! struct (and re-exporting it) leaves them compiling.
//!
//! So every type here is **relocated** (the plan's tactic-1, "preferred where the
//! struct is already a plain serde DTO"). `nornir` re-exports each from its
//! original path (`nornir::viz::model::Timeline`, `nornir::registry::RosterRow`,
//! `nornir::warehouse::clone_events::CloneEventRow`) so the server producers, the
//! `viz` panes, and `viz::remote` keep their imports — the decoupling is that the
//! *type itself* now lives in the leaf, so Step 4 can re-point the read-client at
//! `nornir_wire::view::*` and drop its `nornir` edge.
pub mod rows;
pub mod timeline;