Package org.apache.drill.exec.planner.index
package org.apache.drill.exec.planner.index
-
ClassDescriptionAbstract base class for Index collection (collection of Index descriptors)Abstract base class for an Index descriptorConvert a logicalExpression to RexNode, notice the inputRel could be in an old plan, but newRowType is the newly built rowType that the new RexNode will be applied upon, so when reference fields, use newRowType, when need cluster, plannerSetting, etc, use old inputRelA visitor class that analyzes a filter condition (typically an index condition) and a supplied input collation and determines what the output collation would be after applying the filter.FunctionalIndexInfo is to collect Functional fields in IndexDescriptor, derive information needed for index plan, e.g.The filter expressions that could be indexed Other than SchemaPaths, which represent columns of a table and could be indexed, we consider only function expressions, and specifically, CAST function.Interface used to describe an index collectionTypes of an index collections: NATIVE_SECONDARY_INDEX_COLLECTION, EXTERNAL_SECONDARY_INDEX_COLLECTIONTop level interface used to define an index.Types of an index: PRIMARY_KEY_INDEX, NATIVE_SECONDARY_INDEX, EXTERNAL_SECONDARY_INDEXIndexDefinition + functions to access materialized index(index table/scan, etc)SchemaFactory of a storage plugin that can used to store index tables should expose this interface to allow IndexDiscovers discovering the index table without adding dependency to the storage plugin.IndexDiscoverBase is the layer to read index configurations of tables on storage plugins, then based on the properties it collected, get the StoragePlugin from StoragePluginRegistry, together with indexes information, build an IndexCollectionWith this factory, we allow user to load a different indexDiscover class to obtain index informationEncapsulates one or more IndexProperties representing (non)covering or intersecting indexes.IndexProperties encapsulates the various metrics of a single index that are related to the current query.IndexProperties encapsulates the various metrics of a single index that are related to the current query.An InvalidIndexDefinitionException may be thrown if Drill does not recognize the type or expression of the index during the index discovery phaseClass PathInExpr is to recursively analyze a expression trees with a map of indexed expression collected from indexDescriptor, e.g.This class is an enhanced version for DrillOptiq, 1, it can convert expressions in one more layer(project that have expression) above project-scan, while DrillOptiq can only convert expressions directly reference scan's row type, 2, it can record the generated LogicalExpression of each rexNode in the rexNode tree for future reference this result can serve future rewrite that need to locate particular LogicalExpressionsRewrite RexNode with these policies: 1) field renamed.This class go through the RexNode, collect all the fieldNames, mark starting positions(RexNode) of fields so this information can be used later e,.g.