I had some spare time so thought I would try out the new ifql interface and see if it can help some of my raw data queries go faster. This is using ifql 0.0.4 and influxdb 1.4.2.
I tried two simple queries on a 30s range of data containing 24055 rows and about a dozen tags:
The first query takes 8-9 seconds to run. If I change count(*) to * and bring the data back, it takes 12-13s.
SELECT count(*) FROM "table" WHERE time >= '2018-01-25T00:00:00Z' AND time < '2018-01-25T00:00:30Z'"
The ifql equivalent:
q=from(db:"mydb").filter(fn: (r) => r["_measurement"] == "table" AND r["_field"] == "gauge").range(start:2018-01-25T00:00:00Z,stop:2018-01-25T00:00:30Z).group().count()
takes 40s, and removing the group().count() to bring back the raw data takes 40s as well.
So I’m happy to hear any advice on how I could modify the query, but for me, this isn’t yet ready to use, it’s about 4x slower.