Hi all,
I'm currently fixing this issue: Seperate AlignByDevicePlan from QueryPlan[1]. There are three aspects that I changed: (1) Restructure QueryPlan The general query aligning by time and the AlignByDevice query ( which is called groupByDevice before ) were both storaged in QueryPlan before. As they store different parameters and invoke different query process, I seperated them from QueryPlan. QueryPlan is as base class now, the RawDataQueryPlan and AlignByDevicePlan representing two types of queries are as subclasses of QueryPlan. (2) The query process of an AlignByDevicePlan There were three subclasses of QueryPlan before: GroupByPlan, FillQueryPlan, AggregationPlan. They are as subclasses of RawDataQueryPlan now. To avoid redundance, I didn't design the same subclasses for AlignByDevicePlan, instead these three sub-plan are storaged as parameters in it. For example, if a query are both a AlignByDevicePlan and a GroupByPlan, the GroupByPlan parameter will be assigned and processed later. (3) The name of AlignByDevicePlan Maybe you have noticed that. Because GroupByDevice is not a standard sql statement, so I rename it as AlignByDevice. Thanks for the advice of Xiangdong Huang for this change. I also changed some names which used GroupByDevice, but it was just a part. Hope we can change it little by little later. [1] https://issues.apache.org/jira/browse/IOTDB-468 Best, Xiangwei Wei