chronograf
chronograf copied to clipboard
Account for absolute time ranges in auto GROUPBY interval calculation
Here's a query with a 2d relative timespan. Auto GROUPBY interval came out to 43s:
SELECT mean("usage_idle") AS "mean_usage_idle" FROM "telegraf"."autogen"."cpu" WHERE time > now() - 2d AND time < now() GROUP BY time(43s)
Here's the same query from the same graph with a 2d absolute timespan. Auto GROUPBY interval came out to 1s:
SELECT mean("usage_idle") AS "mean_usage_idle" FROM "telegraf"."autogen"."cpu" WHERE time > '2017-07-05T18:10:00.000Z' AND time < '2017-07-07T18:10:00.000Z' GROUP BY time(1s)
I would expect these values to be the same. It looks like chronograf.go:L195 is assuming a relative time range -- we need to expand support to include absolute ranges as well.
@lukevmorris @timraymond what is the status of this, does it still need addressing?