Flux query language in Grafana
A lower limit for the auto group by time interval. Recommended to be set to write frequency, for example 1m
if your data is written every minute. This option can also be overridden/configured in a dashboard panel under data source options. It’s important to note that this value needs to be formatted as a number followed by a valid time identifier, e.g. 1m
(1 minute) or 30s
(30 seconds). The following time identifiers are supported:
Supported macros
The macros support copying and pasting from Chronograph.
Grafana Flux query:
|> range(start: 2020-06-11T13:59:07Z, stop: 2020-06-11T14:59:07Z)
|> filter(fn: (r) => r["_measurement"] == "cpu" or r["_measurement"] == "swap")
|> aggregateWindow(every: 2s, fn: mean)
You can view the interpolated version of a query with the query inspector. For more information, refer to and Queries.