Jialin Qiao created IOTDB-862:
---------------------------------
Summary: Register a time range (raw data/ down sampling) query
template for monitoring applications
Key: IOTDB-862
URL: https://issues.apache.org/jira/browse/IOTDB-862
Project: Apache IoTDB
Issue Type: New Feature
Components: Core/Engine
Reporter: Jialin Qiao
In monitoring scenarios, the query pattern is constant, only the time range
predicate varies. What's more, the time range is in monotone increasing.
For example, someone uses Grafana to visualize a time series for the last 5
minutes and refresh the web page per 5s. Then, for each query instance, IoTDB
receives a query like "select s1 from root.sg.d1 where time >= T2-5m and time
<=T2". And the next query instance is "select s1 from root.sg.d1 where time >=
T2+5s-5m and time <=T2+5s"
We can see that there are many overlapped data between the two query instances.
So, if we can cache the result of the first query, then, data of 4m55s could be
reused for the next query.
The idea is:
(1) let users register such query templates (only time range condition can be
changed)
(2) cache the result data of the query
(3) for each query, read the data in the cache, and load the left data on disk.
(4) discard the outdated data in the cache
(5) we suppose users can bear some out-of-order data not be visualized on
Grafana
User interface:
(1) a sql to register/drop query templates
(2) a new keyword to claim that a query uses the template
(3) users can set the cache size in iotdb-engine.properties
--
This message was sent by Atlassian Jira
(v8.3.4#803005)