mirror of
https://github.com/zvx-echo6/central.git
synced 2026-06-10 20:04:43 +02:00
Third CENTRAL_TRAFFIC-family member, first telemetry traffic source. Polls a
configured tile coverage set (Idaho metros, z=10), fetches Orbis vector flow
tiles, decodes per-segment relative_speed + road geometry, emits one telemetry
Event per road segment per poll to the new CENTRAL_TRAFFIC_FLOW stream. Renders
as colored polylines (green free-flow -> red jam) on the /telemetry map.
Production code; supervisor + gui + ARCHIVE restart (NEW event-bearing stream
central.traffic_flow.> -> archive must resubscribe). Ships disabled; needs a
"tomtom" api key in config.api_keys before enable.
- Subject central.traffic_flow.{z}.{x}.{y} (token traffic_flow, non-overlapping
with central.traffic.>). category="flow.tomtom_flow" -> GUI event_type "flow".
- Severity from relative_speed: >=0.75=1, 0.5-0.75=2, 0.25-0.5=3, <0.25=4.
- Cadence 300s; 7-day retention (high-volume telemetry). Dedup minute-bucketed,
inherited from the v0.9.1 SourceAdapter mixin.
- Shared tomtom_flow_parse module (decode + slippy-tile georeference) reused by
the v0.9.4 on-demand passthrough endpoint.
- Generic framework change (Option A, ~3 lines, inert for the other 14
adapters): Geo.geometry optional field + archive _build_geom_sql prefers it,
so segments persist their real LineString to the PostGIS geom column.
- Idaho-only (Orbis tier confirmed live). Cameras + Navi passthrough are follow-ups.
- deps: mapbox-vector-tile (vector PBF decode); itsdangerous promoted to an
explicit dependency (gui/csrf.py + gui/wizard.py imported it as an undeclared
transitive that uv re-lock would otherwise prune).
Full suite: 780 passed, 1 skipped (central and unprivileged zvx, 3x each).
Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
|
||
|---|---|---|
| .. | ||
| 001_create_config_schema.sql | ||
| 002_add_updated_at_trigger_and_index.sql | ||
| 003_add_streams_table.sql | ||
| 004_nws_states_to_bbox.sql | ||
| 005_add_firms_adapter.sql | ||
| 006_add_usgs_quake_adapter.sql | ||
| 007_add_config_system.sql | ||
| 008_add_operators.sql | ||
| 009_add_sessions.sql | ||
| 010_add_audit_log.sql | ||
| 011_events_add_adapter_column.sql | ||
| 013_add_session_csrf_token.sql | ||
| 014_events_time_id_index.sql | ||
| 015_add_adapters_last_error.sql | ||
| 016_add_wfigs_adapters.sql | ||
| 017_add_inciweb_adapter.sql | ||
| 018_add_swpc_adapters.sql | ||
| 019_add_central_space_stream.sql | ||
| 020_add_gdacs_adapter.sql | ||
| 021_add_central_disaster_stream.sql | ||
| 022_add_eonet_adapter.sql | ||
| 023_add_nwis_adapter_and_hydro_stream.sql | ||
| 024_add_config_enrichment.sql | ||
| 025_add_wzdx_adapter_and_traffic_stream.sql | ||
| 026_add_state_511_atis_adapter.sql | ||
| 027_add_tomtom_flow_adapter_and_flow_stream.sql | ||