korp Ingest pane — the collector consumption seam — design
Class:
design· Function axis:f0(one drivable pane consumes every korp collector) ·f1IngestRowmirror +from_descriptormapping ·f2demo_fullproduction roster ·f3robot-drive + test-matrix. Strict: this file states only the shape that is built. It documents thefacett-korphalf of "provide the collectors korp needs, korp can consume" — the collectors themselves live in the sibling leafkorp-collectors(boats/planes/energy/roads).
f0 — one pane, every collector (the whole)
korp's open-data ingest surface is a drivable facett-korp::IngestPane (Elm/Facet/ Panel, headless update_json + state_json). The collectors it lists — OSM/Trafikverket roads, AIS boats, OpenSky planes, ENTSO-E energy — are not re-implemented here; they are the built-ins of korp-collectors::registry(). This crate is a pure leaf (depends on facett-core only, never korp-collectors), so the host maps the registry across the seam. No cycle, no twin.
f1 — IngestRow mirror + the from_descriptor mapping
IngestRow { name, source, target, direction } is the facett-side mirror of a (CollectorMeta, SourceTarget) descriptor. The host maps the live registry through one call, preserving the declared flow direction (IngestRow::new hardcodes "source"; from_descriptor carries meta.direction.as_str() so a sink stays a sink):
let rows = korp_collectors::registry_descriptors()
.into_iter()
.map(|(meta, st)| facett_korp::IngestRow::from_descriptor(
meta.name, st.source.as_str(), st.label(), meta.direction.as_str()))
.collect();
let pane = facett_korp::IngestPane::from_descriptors("Ingest", rows);
f2 — demo_full — the production roster without a live registry
IngestPane::demo_full() hand-mirrors korp_collectors::registry() so a host without a live registry (or a headless test) still shows the real breadth — the boats (ais, marinetraffic_ais), planes (opensky), energy (entsoe), and roads (osm, trafikverket_road_network) feeds the task names — not just the 4-row demo(). Same from_descriptor shape as the live host, so the two paths never diverge in structure.
f3 — robot-drive + test contract
- Test:
full_roster_carries_boats_planes_energy_roads_and_is_drivableasserts the four data families are present by collector name, then drives select-by-name + run throughupdate_jsonand assertsstate_jsonqueues the jera job.from_descriptor_preserves_directionproves thesinkcase.render.rspaints the full roster and drives the AIS row (the watch-on-DISPLAY leg). - Matrix cell:
facett-korp/ingest · full_registry_roster_consumed— one visible row for the consumption seam (green ⟺ boats/planes/energy/roads all reachable).
Deferred (plan)
- Live cross-crate connector test (
facett-demomapping the realkorp_collectors::registry_descriptors()throughfrom_descriptor, mirroringregion_picker_connector.rs) — deferred to keep the default build lean: it pullsreqwest/tokio/osm-katanawhich are not otherwise in facett-demo's default tree (nordisk build-frugality law). Thefrom_descriptorAPI +demo_fullmirror make it a thin add when a heavy build is affordable (Loki/Odin).