Class QueryRouter
- java.lang.Object
-
- org.apache.iotdb.db.query.executor.QueryRouter
-
- All Implemented Interfaces:
IQueryRouter
public class QueryRouter extends java.lang.Object implements IQueryRouter
Query entrance class of IoTDB query process. All query clause will be transformed to physical plan, physical plan will be executed by EngineQueryRouter.
-
-
Constructor Summary
Constructors Constructor Description QueryRouter()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description org.apache.iotdb.tsfile.read.query.dataset.QueryDataSetaggregate(AggregationPlan aggregationPlan, QueryContext context)Execute aggregation query.org.apache.iotdb.tsfile.read.query.dataset.QueryDataSetfill(FillQueryPlan fillQueryPlan, QueryContext context)Execute fill query.protected AggregationExecutorgetAggregationExecutor(QueryContext context, AggregationPlan aggregationPlan)protected FillQueryExecutorgetFillExecutor(FillQueryPlan plan)protected GroupByWithoutValueFilterDataSetgetGroupByWithoutValueFilterDataSet(QueryContext context, GroupByTimePlan plan)protected GroupByWithValueFilterDataSetgetGroupByWithValueFilterDataSet(QueryContext context, GroupByTimePlan plan)protected LastQueryExecutorgetLastQueryExecutor(LastQueryPlan lastQueryPlan)protected RawDataQueryExecutorgetRawDataQueryExecutor(RawDataQueryPlan queryPlan)org.apache.iotdb.tsfile.read.query.dataset.QueryDataSetgroupBy(GroupByTimePlan groupByTimePlan, QueryContext context)Execute groupBy query.org.apache.iotdb.tsfile.read.query.dataset.QueryDataSetgroupByFill(GroupByTimeFillPlan groupByFillPlan, QueryContext context)Execute group by fill queryorg.apache.iotdb.tsfile.read.query.dataset.QueryDataSetlastQuery(LastQueryPlan lastQueryPlan, QueryContext context)Execute last queryorg.apache.iotdb.tsfile.read.query.dataset.QueryDataSetrawDataQuery(RawDataQueryPlan queryPlan, QueryContext context)Execute physical plan.org.apache.iotdb.tsfile.read.query.dataset.QueryDataSetudafQuery(UDAFPlan udafPlan, QueryContext context)Execute UDAF query.org.apache.iotdb.tsfile.read.query.dataset.QueryDataSetudtfQuery(UDTFPlan udtfPlan, QueryContext context)Execute UDTF query
-
-
-
Method Detail
-
rawDataQuery
public org.apache.iotdb.tsfile.read.query.dataset.QueryDataSet rawDataQuery(RawDataQueryPlan queryPlan, QueryContext context) throws StorageEngineException, QueryProcessException
Description copied from interface:IQueryRouterExecute physical plan.- Specified by:
rawDataQueryin interfaceIQueryRouter- Throws:
StorageEngineExceptionQueryProcessException
-
getRawDataQueryExecutor
protected RawDataQueryExecutor getRawDataQueryExecutor(RawDataQueryPlan queryPlan)
-
aggregate
public org.apache.iotdb.tsfile.read.query.dataset.QueryDataSet aggregate(AggregationPlan aggregationPlan, QueryContext context) throws StorageEngineException, QueryProcessException, java.io.IOException
Description copied from interface:IQueryRouterExecute aggregation query.- Specified by:
aggregatein interfaceIQueryRouter- Throws:
StorageEngineExceptionQueryProcessExceptionjava.io.IOException
-
udafQuery
public org.apache.iotdb.tsfile.read.query.dataset.QueryDataSet udafQuery(UDAFPlan udafPlan, QueryContext context) throws org.apache.iotdb.tsfile.exception.filter.QueryFilterOptimizationException, StorageEngineException, java.io.IOException, QueryProcessException
Description copied from interface:IQueryRouterExecute UDAF query.- Specified by:
udafQueryin interfaceIQueryRouter- Throws:
org.apache.iotdb.tsfile.exception.filter.QueryFilterOptimizationExceptionStorageEngineExceptionjava.io.IOExceptionQueryProcessException
-
getAggregationExecutor
protected AggregationExecutor getAggregationExecutor(QueryContext context, AggregationPlan aggregationPlan)
-
groupBy
public org.apache.iotdb.tsfile.read.query.dataset.QueryDataSet groupBy(GroupByTimePlan groupByTimePlan, QueryContext context) throws org.apache.iotdb.tsfile.exception.filter.QueryFilterOptimizationException, StorageEngineException, QueryProcessException, java.io.IOException
Description copied from interface:IQueryRouterExecute groupBy query.- Specified by:
groupByin interfaceIQueryRouter- Throws:
org.apache.iotdb.tsfile.exception.filter.QueryFilterOptimizationExceptionStorageEngineExceptionQueryProcessExceptionjava.io.IOException
-
getGroupByWithoutValueFilterDataSet
protected GroupByWithoutValueFilterDataSet getGroupByWithoutValueFilterDataSet(QueryContext context, GroupByTimePlan plan)
-
getGroupByWithValueFilterDataSet
protected GroupByWithValueFilterDataSet getGroupByWithValueFilterDataSet(QueryContext context, GroupByTimePlan plan)
-
fill
public org.apache.iotdb.tsfile.read.query.dataset.QueryDataSet fill(FillQueryPlan fillQueryPlan, QueryContext context) throws StorageEngineException, QueryProcessException, java.io.IOException
Description copied from interface:IQueryRouterExecute fill query.- Specified by:
fillin interfaceIQueryRouter- Throws:
StorageEngineExceptionQueryProcessExceptionjava.io.IOException
-
getFillExecutor
protected FillQueryExecutor getFillExecutor(FillQueryPlan plan)
-
groupByFill
public org.apache.iotdb.tsfile.read.query.dataset.QueryDataSet groupByFill(GroupByTimeFillPlan groupByFillPlan, QueryContext context) throws StorageEngineException, QueryProcessException
Description copied from interface:IQueryRouterExecute group by fill query- Specified by:
groupByFillin interfaceIQueryRouter- Throws:
StorageEngineExceptionQueryProcessException
-
lastQuery
public org.apache.iotdb.tsfile.read.query.dataset.QueryDataSet lastQuery(LastQueryPlan lastQueryPlan, QueryContext context) throws StorageEngineException, QueryProcessException, java.io.IOException
Description copied from interface:IQueryRouterExecute last query- Specified by:
lastQueryin interfaceIQueryRouter- Throws:
StorageEngineExceptionQueryProcessExceptionjava.io.IOException
-
getLastQueryExecutor
protected LastQueryExecutor getLastQueryExecutor(LastQueryPlan lastQueryPlan)
-
udtfQuery
public org.apache.iotdb.tsfile.read.query.dataset.QueryDataSet udtfQuery(UDTFPlan udtfPlan, QueryContext context) throws StorageEngineException, QueryProcessException, java.io.IOException, java.lang.InterruptedException
Description copied from interface:IQueryRouterExecute UDTF query- Specified by:
udtfQueryin interfaceIQueryRouter- Throws:
StorageEngineExceptionQueryProcessExceptionjava.io.IOExceptionjava.lang.InterruptedException
-
-