Problem
The traffic dashboard panels (data.doublezero.xyz) still depend on InfluxDB. On lower / zoomed-in timeframes (sub-5-minute buckets) they query the InfluxDB-derived fact_dz_device_interface_counters, which trails real time by ~1 hour, so those views show a trailing ~1h empty gap on every device. Now that every device emits gNMI, the panels should be served from gNMI end to end and stop using InfluxDB.
Evidence
Freshness by table (mainnet-beta, 2026-07-18):
| Table |
Fed by |
Lag |
telemetry_<env>.interface_state (raw gNMI) |
gNMI tunnel |
~0 min (real-time) |
device_interface_rollup_5m |
gNMI (interface_state) |
~3 min |
fact_dz_device_interface_counters |
InfluxDB-derived |
~64 min |
- Panel routing in
api/handlers/traffic_dashboard.go (isRawBucket / trafficTimeFilter): sub-5m buckets use the raw InfluxDB fact table; >= 5m buckets use the gNMI rollup. So zoomed views fall onto InfluxDB and inherit its ~1h lag.
- gNMI coverage is complete: 97/97 current mainnet devices present in
interface_state (24h), and zero current devices are InfluxDB-only (checked dz_devices_current against both sources). The InfluxDB fallback is no longer exercised.
What to do
- Sub-5m / raw traffic path: read the gNMI
interface_state table (real-time, ~30s samples, finer than 5m) with on-the-fly per-sample deltas, mirroring ComputeDeviceInterfaceRollupFromGNMI in indexer/pkg/rollup/activities.go, instead of fact_dz_device_interface_counters.
- Rollup path: the gNMI-over-InfluxDB coalesce (
coalesceDeviceInterfaceBuckets) already prefers gNMI; drop the InfluxDB fallback (or leave it inert) once coverage is confirmed.
- Remove InfluxDB from the traffic panel query path entirely, so every zoom level is real-time gNMI.
- Guard: before removing the fallback, add/confirm a check that every activated device has gNMI coverage (per-device coverage check, infra #1464), so a future gNMI-less device is caught rather than silently blank.
Scope note
fact_dz_device_interface_counters (InfluxDB-derived) has other consumers beyond these panels (traffic / topology / incidents / users handlers). This issue scopes to the traffic panels being served from gNMI. Migrating the remaining consumers and fully decommissioning the InfluxDB ingestion + backfill is a larger follow-up worth tracking separately.
Outcome
All interface-traffic panels served from gNMI (interface_state for sub-5m, device_interface_rollup_5m for >= 5m), real-time at every zoom level, with no InfluxDB in the panel path.
Problem
The traffic dashboard panels (data.doublezero.xyz) still depend on InfluxDB. On lower / zoomed-in timeframes (sub-5-minute buckets) they query the InfluxDB-derived
fact_dz_device_interface_counters, which trails real time by ~1 hour, so those views show a trailing ~1h empty gap on every device. Now that every device emits gNMI, the panels should be served from gNMI end to end and stop using InfluxDB.Evidence
Freshness by table (mainnet-beta, 2026-07-18):
telemetry_<env>.interface_state(raw gNMI)device_interface_rollup_5minterface_state)fact_dz_device_interface_countersapi/handlers/traffic_dashboard.go(isRawBucket/trafficTimeFilter): sub-5m buckets use the raw InfluxDB fact table; >= 5m buckets use the gNMI rollup. So zoomed views fall onto InfluxDB and inherit its ~1h lag.interface_state(24h), and zero current devices are InfluxDB-only (checkeddz_devices_currentagainst both sources). The InfluxDB fallback is no longer exercised.What to do
interface_statetable (real-time, ~30s samples, finer than 5m) with on-the-fly per-sample deltas, mirroringComputeDeviceInterfaceRollupFromGNMIinindexer/pkg/rollup/activities.go, instead offact_dz_device_interface_counters.coalesceDeviceInterfaceBuckets) already prefers gNMI; drop the InfluxDB fallback (or leave it inert) once coverage is confirmed.Scope note
fact_dz_device_interface_counters(InfluxDB-derived) has other consumers beyond these panels (traffic / topology / incidents / users handlers). This issue scopes to the traffic panels being served from gNMI. Migrating the remaining consumers and fully decommissioning the InfluxDB ingestion + backfill is a larger follow-up worth tracking separately.Outcome
All interface-traffic panels served from gNMI (
interface_statefor sub-5m,device_interface_rollup_5mfor >= 5m), real-time at every zoom level, with no InfluxDB in the panel path.