CHOMPER WIKI

No results for “”

Smoky chart (SQL)

A Smoky chart panel draws one column per time bucket, shaded to show the spread of several raw numeric readings in that bucket — not just their average. Use it whenever a single number per bucket (a plain average, a gauge) would hide something real: a latency check where the median is fine but a tail of slow requests isn’t, or a day of order totals where one huge outlier and a cluster of small orders average out to something that describes neither. It’s modeled on the classic SmokePing latency graph, generalized to any metric that naturally comes as several raw readings per time bucket, not just network probes.

Dashboard with three Smoky chart panels: probe latency density with loss coloring, order total spread per day, and a sensor delta panel with negative values

Query convention

SELECT  toStartOfInterval(timestamp, INTERVAL 5 MINUTE) AS bucket,  groupArray(JSONExtractFloat(metadata, 'latency_ms')) AS samples,  countIf(JSONExtractFloat(metadata, 'latency_ms') < 0) / count() AS lossFROM chomper.eventsWHERE event_class = 'probe'  AND timestamp >= parseDateTimeBestEffort({from:String}) AND timestamp <= parseDateTimeBestEffort({to:String})GROUP BY bucket ORDER BY bucket

Three columns: bucket (a time bucket, same convention as a Time series panel), samples — an array of every raw value in that bucket, built with groupArray(<expr>) — and an optional loss column (a 0–1 fraction). When your query returns loss, the whole column is tinted by health (green → amber → rose, configurable thresholds) instead of a flat color, and a bucket at 100% loss renders as an empty gap rather than a solid red column — it reads as a real outage, not just “bad performance.”

Example: a metric with no failure concept

Not every use of this panel is about failures. Leave loss out entirely and every column just uses a flat color:

SELECT  toDate(timestamp) AS bucket,  groupArray(JSONExtractFloat(metadata, 'order_total')) AS samplesFROM chomper.eventsWHERE event_class = 'order'  AND timestamp >= parseDateTimeBestEffort({from:String}) AND timestamp <= parseDateTimeBestEffort({to:String})GROUP BY bucket ORDER BY bucket

This reads as “the spread of check sizes per day,” not just their average — a day with one huge outlier order and mostly small ones looks visibly different from a day where every order clustered around the same amount, something a plain average-per-day gauge or time series would flatten into an identical single number.

Reading the chart

Hover any column for the exact numbers: the bucket’s date/time, the min/avg/max across its samples, and a loss % line when the query returns one. Hovering also highlights the full column with a soft background, the same way a comparison-bars tooltip highlights its own category.

Hovering a column shows its date, min/avg/max, and loss percentage in a tooltip

Choosing a center point

Every column shades outward from a single center point — brightest right at the center, fading toward that bucket’s own highest and lowest samples. Which value counts as the center is configurable (Center point):

  • Median (default) and Average — derive the center from that bucket’s own samples. Use these for a genuinely two-sided metric — a temperature deviation, a profit/loss delta — where values can legitimately land above or below the middle.
  • Zero — a fixed reference regardless of where a bucket’s own data happens to sit. Use this for any delta-style metric where “no change” is the meaningful baseline, not whatever the data averages to.
  • Minimum — collapses back to a plain bar anchored at the bottom of the scale, growing only upward. Use this for a metric that’s never negative — plain latency, queue depth — where there’s no real “downward” half to show.
A Smoky chart panel with Center point set to Median, showing columns that float both above and below zero

The value scale

Min/Max define the shared scale every column’s samples are drawn against. The first time you run a query with no scale saved yet, Chomper suggests one from the real values that query just returned (with a little padding on each side) — edit either field afterward to take over manually; once you do, your value sticks and won’t get recomputed on the next run.

Display options

  • Unit — a text suffix shown in the hover tooltip, e.g. "ms".
  • Show min/max — labels the scale’s two endpoints at the chart’s left edge.
Unit and Show min/max options in the panel editor sidebar
  • Loss thresholds — the color bands a loss value maps to, same “from this value upward, use this color” model as a Gauge panel’s thresholds, just against a 0–1 fraction instead of an arbitrary number.
  • Color — the flat tint used whenever the query has no loss column at all.
Loss thresholds and Color options in the panel editor sidebar

Drilling down into a column

Click any column to see the underlying rows, same as any other SQL panel — bind the clicked bucket with {bucket:String}, and the loss fraction (if your query has one) with {loss:Float64}:

SELECT * FROM chomper.eventsWHERE toStartOfInterval(timestamp, INTERVAL 5 MINUTE) = {bucket:String}  AND timestamp >= parseDateTimeBestEffort({from:String}) AND timestamp <= parseDateTimeBestEffort({to:String})ORDER BY timestamp DESCLIMIT 100

This is a plain time-bucket drill-down — the same shape a Time series panel’s own drill-down uses — so the exact same query works whether or not your main query returns a loss column.

Last updated 27 July 2026