Package org.apache.drill.exec.store.sys
Class SystemTableScan
java.lang.Object
org.apache.drill.exec.physical.base.AbstractBase
org.apache.drill.exec.physical.base.AbstractGroupScan
org.apache.drill.exec.store.sys.SystemTableScan
- All Implemented Interfaces:
Iterable<PhysicalOperator>,GraphValue<PhysicalOperator>,FragmentLeaf,GroupScan,HasAffinity,Leaf,PhysicalOperator,Scan,SubScan
-
Field Summary
FieldsFields inherited from class org.apache.drill.exec.physical.base.AbstractBase
INIT_ALLOCATION, initialAllocation, MAX_ALLOCATION, maxAllocation, userNameFields inherited from interface org.apache.drill.exec.physical.base.GroupScan
ALL_COLUMNS -
Constructor Summary
ConstructorsConstructorDescriptionSystemTableScan(SystemTable table, int maxRecordsToRead, StoragePluginRegistry engineRegistry) SystemTableScan(SystemTable table, int maxRecordsToRead, SystemTablePlugin plugin) SystemTableScan(SystemTable table, SystemTablePlugin plugin) -
Method Summary
Modifier and TypeMethodDescriptionvoidapplyAssignments(List<CoordinationProtos.DrillbitEndpoint> endpoints) applyLimit(int maxRecords) By default, return null to indicate row count based prune is not supported.clone(List<SchemaPath> columns) Returns a clone of GroupScan instance, except that the new GroupScan will use the provided list of columns .clone(SystemTableScan systemTableScan, int maxRecordsToRead) Returns a list of columns scanned by this group scanExample: SystemTableScan [table=OPTION, distributed=false, maxRecordsToRead=1]Get distribution affinity which describes the parallelization strategy of the operator.longlongintintintAt minimum, the GroupScan requires these many fragments to run.getNewWithChildren(List<PhysicalOperator> children) Regenerate with this node with a new set of children.If distributed, the scan needs to happen on every node.System tables do not need stats.getSpecificScan(int minorFragmentId) getTable()booleanDefault is not to support limit pushdown.Methods inherited from class org.apache.drill.exec.physical.base.AbstractGroupScan
accept, applyFilter, canPushdownProjects, enforceWidth, getAnalyzeInfoProvider, getColumnValueCount, getFiles, getFilter, getMetadataProvider, getPartitionColumns, getScanStats, getScanStats, getSelectionRoot, getTableMetadata, hasFiles, isDistributed, isExecutable, iterator, supportsFilterPushDown, supportsPartitionFilterPushdown, usedMetastoreMethods inherited from class org.apache.drill.exec.physical.base.AbstractBase
accept, getCost, getOperatorId, getSVMode, getUserName, isBufferedOperator, setCost, setMaxAllocation, setOperatorIdMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface org.apache.drill.common.graph.GraphValue
acceptMethods inherited from interface java.lang.Iterable
forEach, iterator, spliteratorMethods inherited from interface org.apache.drill.exec.physical.base.PhysicalOperator
accept, getCost, getOperatorId, getSVMode, getUserName, isBufferedOperator, isExecutable, setCost, setMaxAllocation, setOperatorId
-
Field Details
-
OPERATOR_TYPE
- See Also:
-
-
Constructor Details
-
SystemTableScan
public SystemTableScan(SystemTable table, int maxRecordsToRead, StoragePluginRegistry engineRegistry) throws ExecutionSetupException - Throws:
ExecutionSetupException
-
SystemTableScan
-
SystemTableScan
-
-
Method Details
-
getScanStats
System tables do not need stats.- Overrides:
getScanStatsin classAbstractGroupScan- Returns:
- a trivial stats table
-
getNewWithChildren
Description copied from interface:PhysicalOperatorRegenerate with this node with a new set of children. This is used in the case of materialization or optimization.- Specified by:
getNewWithChildrenin interfacePhysicalOperator- Parameters:
children-
-
applyAssignments
- Specified by:
applyAssignmentsin interfaceGroupScan
-
getColumns
Description copied from interface:GroupScanReturns a list of columns scanned by this group scan- Specified by:
getColumnsin interfaceGroupScan- Overrides:
getColumnsin classAbstractGroupScan
-
getSpecificScan
- Specified by:
getSpecificScanin interfaceGroupScan
-
getMaxParallelizationWidth
public int getMaxParallelizationWidth()- Specified by:
getMaxParallelizationWidthin interfaceGroupScan
-
getMinParallelizationWidth
public int getMinParallelizationWidth()Description copied from interface:GroupScanAt minimum, the GroupScan requires these many fragments to run. Currently, this is used inSimpleParallelizer- Specified by:
getMinParallelizationWidthin interfaceGroupScan- Overrides:
getMinParallelizationWidthin classAbstractGroupScan- Returns:
- the minimum number of fragments that should run
-
getInitialAllocation
public long getInitialAllocation()- Specified by:
getInitialAllocationin interfacePhysicalOperator- Overrides:
getInitialAllocationin classAbstractGroupScan- Returns:
- The memory to preallocate for this operator
-
getMaxAllocation
public long getMaxAllocation()- Specified by:
getMaxAllocationin interfacePhysicalOperator- Overrides:
getMaxAllocationin classAbstractGroupScan- Returns:
- The maximum memory this operator can allocate
-
getDigest
Example: SystemTableScan [table=OPTION, distributed=false, maxRecordsToRead=1] -
getOperatorType
- Specified by:
getOperatorTypein interfacePhysicalOperator- Overrides:
getOperatorTypein classAbstractGroupScan
-
getOperatorAffinity
If distributed, the scan needs to happen on every node. Since width is enforced, the number of fragments equals number of Drillbits. And here we set, each endpoint as mandatory assignment required to ensure every Drillbit executes a fragment.- Specified by:
getOperatorAffinityin interfaceHasAffinity- Overrides:
getOperatorAffinityin classAbstractGroupScan- Returns:
- the Drillbit endpoint affinities
-
getDistributionAffinity
Description copied from interface:HasAffinityGet distribution affinity which describes the parallelization strategy of the operator.- Specified by:
getDistributionAffinityin interfaceHasAffinity- Overrides:
getDistributionAffinityin classAbstractGroupScan
-
clone
Description copied from interface:GroupScanReturns a clone of GroupScan instance, except that the new GroupScan will use the provided list of columns .- Specified by:
clonein interfaceGroupScan- Overrides:
clonein classAbstractGroupScan
-
clone
-
supportsLimitPushdown
public boolean supportsLimitPushdown()Description copied from class:AbstractGroupScanDefault is not to support limit pushdown.- Specified by:
supportsLimitPushdownin interfaceGroupScan- Overrides:
supportsLimitPushdownin classAbstractGroupScan
-
applyLimit
Description copied from class:AbstractGroupScanBy default, return null to indicate row count based prune is not supported. Each group scan subclass should override, if it supports row count based prune.- Specified by:
applyLimitin interfaceGroupScan- Overrides:
applyLimitin classAbstractGroupScan- Parameters:
maxRecords- : the number of rows requested from group scan.- Returns:
- a new instance of group scan if the prune is successful. null when either if row-based prune is not supported, or if prune is not successful.
-
getTable
-
getMaxRecordsToRead
public int getMaxRecordsToRead() -
getPlugin
-