Class UDTFPlan
- java.lang.Object
-
- org.apache.iotdb.db.qp.physical.PhysicalPlan
-
- org.apache.iotdb.db.qp.physical.crud.QueryPlan
-
- org.apache.iotdb.db.qp.physical.crud.RawDataQueryPlan
-
- org.apache.iotdb.db.qp.physical.crud.UDTFPlan
-
- All Implemented Interfaces:
org.apache.iotdb.consensus.common.request.IConsensusRequest,UDFPlan
- Direct Known Subclasses:
UDAFPlan
public class UDTFPlan extends RawDataQueryPlan implements UDFPlan
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from class org.apache.iotdb.db.qp.physical.PhysicalPlan
PhysicalPlan.Factory, PhysicalPlan.PhysicalPlanType
-
-
Field Summary
Fields Modifier and Type Field Description protected java.util.Map<java.lang.Integer,java.lang.Integer>datasetOutputIndexToResultColumnIndexprotected java.util.Map<java.lang.String,java.lang.Integer>pathNameToReaderIndexprotected UDTFContextudtfContext-
Fields inherited from class org.apache.iotdb.db.qp.physical.crud.QueryPlan
paths, resultColumns, WITHOUT_NULL_FILTER_ERROR_MESSAGE, withoutNullColumnsIndex
-
Fields inherited from class org.apache.iotdb.db.qp.physical.PhysicalPlan
canBeSplit, index
-
-
Constructor Summary
Constructors Constructor Description UDTFPlan(java.time.ZoneId zoneId)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description voidconstructUdfExecutors(java.util.List<ResultColumn> resultColumns)Build the execution plan of the executors.voiddeduplicate(PhysicalGenerator physicalGenerator)voidfinalizeUDFExecutors(long queryId)Call UDF finalization methods and release computing resources.java.util.List<org.apache.iotdb.commons.path.PartialPath>getAuthPaths()Used to check whether a user has the permission to execute the plan with these paths.java.lang.IntegergetReaderIndexByExpressionName(java.lang.String expressionName)ResultColumngetResultColumnByDatasetOutputIndex(int datasetOutputIndex)UDTFContextgetUdtfContext()java.util.List<org.apache.iotdb.tsfile.file.metadata.enums.TSDataType>getWideQueryHeaders(java.util.List<java.lang.String> respColumns, java.util.List<java.lang.String> respSgColumns, boolean isJdbcQuery, java.util.BitSet aliasList)protected voidsetDatasetOutputIndexToResultColumnIndex(int datasetOutputIndex, java.lang.Integer originalIndex)-
Methods inherited from class org.apache.iotdb.db.qp.physical.crud.RawDataQueryPlan
addDeduplicatedPaths, addFilterPathInDeviceToMeasurements, convertSpecialClauseValues, getAllMeasurementsInDevice, getDeduplicatedDataTypes, getDeduplicatedPaths, getDeviceToMeasurements, getExpression, groupVectorPaths, setDeduplicatedPaths, setDeduplicatedPathsAndUpdate, setDeduplicatedVectorPaths, setExpression, transformToVector, updateDeviceMeasurementsUsingExpression
-
Methods inherited from class org.apache.iotdb.db.qp.physical.crud.QueryPlan
getColumnForDisplay, getColumnForReaderFromPath, getDataTypes, getPaths, getPathToIndex, getResultColumns, getRowLimit, getRowOffset, getTSExecuteStatementResp, getWithoutNullColumnsIndex, hasLimit, isAlignByTime, isAscending, isEnableRedirect, isEnableTracing, isGroupByLevel, isWithoutAllNull, isWithoutAnyNull, setAlignByTime, setAscending, setColumnNameToDatasetOutputIndex, setEnableRedirect, setEnableTracing, setPaths, setResultColumns, setRowLimit, setRowOffset, setWithoutAllNull, setWithoutAnyNull
-
Methods inherited from class org.apache.iotdb.db.qp.physical.PhysicalPlan
canBeSplit, checkIntegrity, deserialize, deserialize, getAggregations, getIndex, getLoginUserName, getOperatorName, getOperatorType, isAuthenticationRequired, isDebug, isPrefixMatch, isQuery, isSelectInto, putString, putString, putStrings, putStrings, readString, readStrings, serialize, serialize, serializeImpl, serializeToByteBuffer, setDebug, setIndex, setLoginUserName, setOperatorType, setPrefixMatch, setQuery
-
-
-
-
Field Detail
-
udtfContext
protected final UDTFContext udtfContext
-
datasetOutputIndexToResultColumnIndex
protected final java.util.Map<java.lang.Integer,java.lang.Integer> datasetOutputIndexToResultColumnIndex
-
pathNameToReaderIndex
protected final java.util.Map<java.lang.String,java.lang.Integer> pathNameToReaderIndex
-
-
Method Detail
-
deduplicate
public void deduplicate(PhysicalGenerator physicalGenerator) throws org.apache.iotdb.commons.exception.MetadataException
- Overrides:
deduplicatein classRawDataQueryPlan- Throws:
org.apache.iotdb.commons.exception.MetadataException
-
getWideQueryHeaders
public java.util.List<org.apache.iotdb.tsfile.file.metadata.enums.TSDataType> getWideQueryHeaders(java.util.List<java.lang.String> respColumns, java.util.List<java.lang.String> respSgColumns, boolean isJdbcQuery, java.util.BitSet aliasList)- Overrides:
getWideQueryHeadersin classQueryPlan
-
setDatasetOutputIndexToResultColumnIndex
protected void setDatasetOutputIndexToResultColumnIndex(int datasetOutputIndex, java.lang.Integer originalIndex)
-
getAuthPaths
public java.util.List<org.apache.iotdb.commons.path.PartialPath> getAuthPaths()
Description copied from class:PhysicalPlanUsed to check whether a user has the permission to execute the plan with these paths.- Overrides:
getAuthPathsin classPhysicalPlan
-
constructUdfExecutors
public void constructUdfExecutors(java.util.List<ResultColumn> resultColumns)
Description copied from interface:UDFPlanBuild the execution plan of the executors. This method will not create any UDF instances, nor will it execute user-defined logic.- Specified by:
constructUdfExecutorsin interfaceUDFPlan
-
finalizeUDFExecutors
public void finalizeUDFExecutors(long queryId)
Description copied from interface:UDFPlanCall UDF finalization methods and release computing resources.- Specified by:
finalizeUDFExecutorsin interfaceUDFPlan
-
getResultColumnByDatasetOutputIndex
public ResultColumn getResultColumnByDatasetOutputIndex(int datasetOutputIndex)
-
getReaderIndexByExpressionName
public java.lang.Integer getReaderIndexByExpressionName(java.lang.String expressionName)
-
getUdtfContext
public UDTFContext getUdtfContext()
-
-