Keyboard shortcuts

Press or to navigate between chapters

Press S or / to search in the book

Press ? to show this help

Press Esc to hide this help

The Standard Library as Architecture

  • Iterator is the core streaming protocol for structured rows.
  • Box<dyn Iterator<Item = Value> + Send> erases arbitrary lazy adapter chains.
  • std::process::Command, Stdio, child handles, and pipes implement Unix interoperability.
  • Arc<AtomicBool> broadcasts interruption cheaply to streams and workers.
  • mpsc::sync_channel bounds parallel result buffering; ordinary mpsc carries child status.
  • Arc<Mutex<_>> protects rare shared job/status and cached-pool state.
  • HashMap powers scopes, declarations, records, environment overlays, and pool caches.
  • Cow<'a, str> avoids allocating borrowed command/signature text until ownership is needed.
  • Span { start, end } is small provenance carried through values and errors.

Moving PipelineData between commands is important. A stream has one consumer; cloning it would create surprising alias-dependent observation. Materialized Values remain cloneable and safe to share.