Resolved conflict in internal/records/records.go:
- Upstream refactor moved deletion code to records_deletion.go and
switched averaging functions from package-level globals to local
variables (var row StatsRecord / params := make(dbx.Params, 1)).
- Kept AverageProbeStats and rewrote it to match the new local-variable
pattern.
- Dropped duplicated deletion helpers from records.go (they now live in
records_deletion.go).
- Added "network_probe_stats" to the collections list in
records_deletion.go:deleteOldSystemStats so probe stats keep the same
retention policy.
- Apply appendData() for gap detection in both realtime and non-realtime
modes, so the latency chart shows breaks instead of smooth lines when
data is missing during service interruptions
- Handle null stats in gap marker entries to prevent runtime crashes
- Fix color assignment: use CSS variables (--chart-1..5) for ≤5 probes,
switch to dynamic HSL distribution for >5 probes so all lines are
visible with distinct colors
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Pass system record to NetworkProbes component and use it as a
dependency in the non-realtime fetch effect, matching the pattern
used by system_stats and container_stats in use-system-data.ts.
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
- Use shared http.Client in ProbeManager to avoid connection/transport leak
- Skip probe goroutine and agent request when system has no enabled probes
- Validate HTTP probe target URL scheme (http:// or https://) on creation
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Existing databases from main branch lack the network_probes and
network_probe_stats collections, which were only in the initial snapshot.
This separate migration ensures they are created on upgrade.
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Include probe results in the 1-second realtime WebSocket broadcast so
the frontend can update probe latency/loss every second, matching the
behavior of system and container metrics.
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>