swactor/crates
Zachery Aaron Shores-Chmielewski b8aff00dc1 enforce datastream telemetry-only invariant: ban frame types from control code
The datastream is metrics/logging only; control decisions must never branch
on a frame.  This was a recurring cultural problem with no structural
enforcement.  This change makes it a compile-time and CI-enforced fact.

datastream crate (lib.rs):
- Stop re-exporting Frame, DatastreamEvent, FrameDelivery at crate root.
   is now a compile error (E0425).  These types live
  only in datastream::frame::* and are documented as the observer surface.
- Safe identity types (ChannelId, StreamId, Position, Record, etc.) remain
  re-exported at root for producer-side callers.

orchestration/app.rs:
- Extracted all frame-touching code (CollectedDatastreamFrame,
  drain_datastream_connections, update_load_progress_from_frame,
  drain_frames, archive_collected_frame, pump, OrchDatastream,
  DashboardSupport) into two new observability modules:
  frame_collector.rs and orch_datastream.rs.
- The orchestrator now interacts through a FrameCollector whose
  drain/drain_with_progress methods take closures; it never names Frame,
  DatastreamEvent, or CollectedDatastreamFrame.
- StageLoadProgress (the one control-relevant signal previously scraped
  from frame payloads) is extracted inside FrameCollector and handed to
  the control loop as plain data.

xtask:
- New check-telemetry-isolation command scans control-plane modules
  (orchestration/, distribution/, data-plane/, provisioning/) for
  forbidden frame-type references and fails the build if any are found.

Verified: workspace builds (myelin + dashboard feature), datastream 29
tests pass, myelin 64 lib tests pass, check-telemetry-isolation passes
clean.

Signed-off-by: Zachery Aaron Shores-Chmielewski <zacheryasc@gmail.com>
2026-08-12 16:14:57 +04:00
..
bindings feat(core): add process-local multicore runtime 2026-08-11 16:12:09 +04:00
dashboard enforce datastream telemetry-only invariant: ban frame types from control code 2026-08-12 16:14:57 +04:00
data-plane feat(core): add process-local multicore runtime 2026-08-11 16:12:09 +04:00
datastream enforce datastream telemetry-only invariant: ban frame types from control code 2026-08-12 16:14:57 +04:00
distribution feat(core): add process-local multicore runtime 2026-08-11 16:12:09 +04:00
engine feat(core): add process-local multicore runtime 2026-08-11 16:12:09 +04:00
iroh-driver enforce datastream telemetry-only invariant: ban frame types from control code 2026-08-12 16:14:57 +04:00
process feat(core): add process-local multicore runtime 2026-08-11 16:12:09 +04:00
provisioning feat(provisioning): add level-triggered cluster reconciler 2026-08-12 11:49:18 +04:00
transport feat(core): add process-local multicore runtime 2026-08-11 16:12:09 +04:00