Closed Sarah-E-Greene closed 9 years ago
I just browsed to pigeonhole and it looks as expected.
Selecting yesterday && today as the date range changed this to the broken graph.
Looking a bit further now.
Looking at @series
here, if I load one day I get:
"[{\"name\":\"Number of alerts per 1h\",\"data\":[[1431612000000,0],[1431615600000,0],[1431619200000,4],[1431622800000,2]...
If I load more than one day the data contains 2 values for each timestamp: "0" and then the actual value:
"[{\"name\":\"Number of alerts per 1h\",\"data\"[[1431525600000,0],[1431525600000,3],[1431529200000,0],[1431529200000,4],[1431532800000,0],[1431532800000,2]:(..)[1431615600000,0],[1431615600000,0],[1431619200000,0],[1431619200000,4],(..)
Turns out influxdb returns the data we display:
:count=>[{"time"=>1431565200, "count"=>19}, {"time"=>1431561600, "count"=>18},(..),{"time"=>1431561600, "count"=>0}, {"time"=>1431565200, "count"=>0},(..)
I can't even.
select count(incident_key) from pigeonhole where time > 1431525600s and time < 1431662482s group by time(1h) fill(0)
returns duplicates, while
select count(incident_key) from pigeonhole group by time(1h), fill(0) where time > 1431525600s and time < 1431662421s
doesn't.
Looking at the query language the latter is the preferred syntax. PR coming up.
As shown below, the line graph keeps dropping to 0 for every point, even though there's non-zero data for every point.