Skip to content

v1.2.0 — usable reporting windows, summary-by-default responses

Choose a tag to compare

@whasamatau whasamatau released this 21 Aug 03:49
· 8 commits to master since this release
4f50e69

Fixes the two reporting_get_data defects found during a live memory-pressure investigation against TrueNAS 26.0.0-BETA.1. Full write-up: docs/FIELD-REPORT-2026-08-21-reporting-and-diagnostics.md.

Fixed — start/end were unsatisfiable

Neither spelling worked. The Zod schema demanded a string, middlewared's query schema demands an integer epoch, and the value was forwarded verbatim — so a string returned query.start: Input should be a valid integer while a number never got past the schema. ISO 8601 was never converted despite the parameter description promising it, which left the no-argument call and its fixed last-hour window as the only thing that worked.

Both now accept epoch seconds (number or string) or ISO 8601 and coerce to integer epoch seconds. An inverted window is rejected up front instead of being passed upstream.

Changed — responses default to a summary

A two-graph, one-hour query returned 400,403 characters (3,601 points per graph at 1s resolution), while the aggregations block the payload already carries is ~200 bytes and answers most of what these graphs get consulted for.

detail now defaults to "summary" — keeps aggregations, legend, start, end; drops the raw series; reports the elided count as data_points.

⚠️ This changes the default response shape. Callers that parse data should pass detail: "raw". detail: "downsampled" returns roughly max_points rows (default 120), bucketed to preserve each bucket's minimum and maximum — a mean-based reduction erases exactly the spikes and troughs the series is read for.

aggregate's description is also corrected: it adds the aggregations block and does not reduce the size of data.

Notes

Minor rather than major: the change is additive with a documented opt-out, following the precedent of 1.1.2, which altered the content of every response (secret redaction) as a patch. No action surface change — 270 registered actions and the tier counts are unchanged. 268 tests pass.