class PrepareDeltaScan extends Rule[LogicalPlan] with PrepareDeltaScanBase
- Alphabetic
- By Inheritance
- PrepareDeltaScan
- PrepareDeltaScanBase
- SubqueryTransformerHelper
- OptimizeMetadataOnlyDeltaQuery
- DeltaLogging
- DatabricksLogging
- DeltaProgressReporter
- PredicateHelper
- AliasHelper
- Rule
- Logging
- SQLConfHelper
- AnyRef
- Any
- Hide All
- Show All
- Public
- Protected
Instance Constructors
- new PrepareDeltaScan(spark: SparkSession)
Type Members
- case class DeltaColumnStat(min: Any, max: Any) extends Product with Serializable
Min and max values from Delta Log stats or partitionValues.
Min and max values from Delta Log stats or partitionValues.
- Definition Classes
- OptimizeMetadataOnlyDeltaQuery
- abstract class DeltaTableScan[FileIndexType <: FileIndex] extends AnyRef
- Definition Classes
- PrepareDeltaScanBase
Value Members
- object MetadataOptimizableAggregate
- Definition Classes
- OptimizeMetadataOnlyDeltaQuery
- final def !=(arg0: Any): Boolean
- Definition Classes
- AnyRef → Any
- final def ##: Int
- Definition Classes
- AnyRef → Any
- final def ==(arg0: Any): Boolean
- Definition Classes
- AnyRef → Any
- def apply(_plan: LogicalPlan): LogicalPlan
- Definition Classes
- PrepareDeltaScanBase → Rule
- final def asInstanceOf[T0]: T0
- Definition Classes
- Any
- def buildBalancedPredicate(expressions: Seq[Expression], op: (Expression, Expression) => Expression): Expression
- Attributes
- protected
- Definition Classes
- PredicateHelper
- def canEvaluate(expr: Expression, plan: LogicalPlan): Boolean
- Attributes
- protected
- Definition Classes
- PredicateHelper
- def canEvaluateWithinJoin(expr: Expression): Boolean
- Attributes
- protected
- Definition Classes
- PredicateHelper
- def clone(): AnyRef
- Attributes
- protected[lang]
- Definition Classes
- AnyRef
- Annotations
- @throws(classOf[java.lang.CloneNotSupportedException]) @native()
- def conf: SQLConf
- Definition Classes
- SQLConfHelper
- def deltaAssert(check: => Boolean, name: String, msg: String, deltaLog: DeltaLog = null, data: AnyRef = null, path: Option[Path] = None): Unit
Helper method to check invariants in Delta code.
Helper method to check invariants in Delta code. Fails when running in tests, records a delta assertion event and logs a warning otherwise.
- Attributes
- protected
- Definition Classes
- DeltaLogging
- final def eq(arg0: AnyRef): Boolean
- Definition Classes
- AnyRef
- def equals(arg0: AnyRef): Boolean
- Definition Classes
- AnyRef → Any
- def extractPredicatesWithinOutputSet(condition: Expression, outputSet: AttributeSet): Option[Expression]
- Attributes
- protected
- Definition Classes
- PredicateHelper
- def filesForScan(scanGenerator: DeltaScanGenerator, limitOpt: Option[Int], filters: Seq[Expression], delta: LogicalRelation): DeltaScan
Scan files using the given
filtersand returnDeltaScan.Scan files using the given
filtersand returnDeltaScan.Note: when
limitOptis non empty,filtersmust contain only partition filters. Otherwise, it can contain arbitrary filters. SeeDeltaTableScanfor more details.- Attributes
- protected
- Definition Classes
- PrepareDeltaScanBase
- def finalize(): Unit
- Attributes
- protected[lang]
- Definition Classes
- AnyRef
- Annotations
- @throws(classOf[java.lang.Throwable])
- def findExpressionAndTrackLineageDown(exp: Expression, plan: LogicalPlan): Option[(Expression, LogicalPlan)]
- Definition Classes
- PredicateHelper
- def getAliasMap(exprs: Seq[NamedExpression]): AttributeMap[Alias]
- Attributes
- protected
- Definition Classes
- AliasHelper
- def getAliasMap(plan: Aggregate): AttributeMap[Alias]
- Attributes
- protected
- Definition Classes
- AliasHelper
- def getAliasMap(plan: Project): AttributeMap[Alias]
- Attributes
- protected
- Definition Classes
- AliasHelper
- final def getClass(): Class[_ <: AnyRef]
- Definition Classes
- AnyRef → Any
- Annotations
- @native()
- def getCommonTags(deltaLog: DeltaLog, tahoeId: String): Map[TagDefinition, String]
- Definition Classes
- DeltaLogging
- def getDeltaScanGenerator(index: TahoeLogFileIndex): DeltaScanGenerator
Gets the DeltaScanGenerator for the given log, which will be used to generate DeltaScans.
Gets the DeltaScanGenerator for the given log, which will be used to generate DeltaScans. Every time this method is called on a log within the lifetime of this rule (i.e., the lifetime of the query for which this rule was instantiated), the returned generator will read a snapshot that is pinned on the first access for that log.
Internally, it will use the snapshot of the file index, the snapshot of the active transaction (if any), or the latest snapshot of the given log.
- Attributes
- protected
- Definition Classes
- PrepareDeltaScanBase → OptimizeMetadataOnlyDeltaQuery
- def getErrorData(e: Throwable): Map[String, Any]
- Definition Classes
- DeltaLogging
- def getPreparedIndex(preparedScan: DeltaScan, fileIndex: TahoeLogFileIndex): PreparedDeltaFileIndex
Helper method to generate a PreparedDeltaFileIndex
Helper method to generate a PreparedDeltaFileIndex
- Attributes
- protected
- Definition Classes
- PrepareDeltaScanBase
- def hashCode(): Int
- Definition Classes
- AnyRef → Any
- Annotations
- @native()
- def initializeLogIfNecessary(isInterpreter: Boolean, silent: Boolean): Boolean
- Attributes
- protected
- Definition Classes
- Logging
- def initializeLogIfNecessary(isInterpreter: Boolean): Unit
- Attributes
- protected
- Definition Classes
- Logging
- final def isInstanceOf[T0]: Boolean
- Definition Classes
- Any
- def isLikelySelective(e: Expression): Boolean
- Definition Classes
- PredicateHelper
- def isNullIntolerant(expr: Expression): Boolean
- Attributes
- protected
- Definition Classes
- PredicateHelper
- def isSubqueryRoot(plan: LogicalPlan): Boolean
Is the give plan a subquery root.
Is the give plan a subquery root.
- Definition Classes
- SubqueryTransformerHelper
- def isTraceEnabled(): Boolean
- Attributes
- protected
- Definition Classes
- Logging
- def log: Logger
- Attributes
- protected
- Definition Classes
- Logging
- def logConsole(line: String): Unit
- Definition Classes
- DatabricksLogging
- def logDebug(msg: => String, throwable: Throwable): Unit
- Attributes
- protected
- Definition Classes
- Logging
- def logDebug(msg: => String): Unit
- Attributes
- protected
- Definition Classes
- Logging
- def logError(msg: => String, throwable: Throwable): Unit
- Attributes
- protected
- Definition Classes
- Logging
- def logError(msg: => String): Unit
- Attributes
- protected
- Definition Classes
- Logging
- def logInfo(msg: => String, throwable: Throwable): Unit
- Attributes
- protected
- Definition Classes
- Logging
- def logInfo(msg: => String): Unit
- Attributes
- protected
- Definition Classes
- Logging
- def logName: String
- Attributes
- protected
- Definition Classes
- Logging
- def logTrace(msg: => String, throwable: Throwable): Unit
- Attributes
- protected
- Definition Classes
- Logging
- def logTrace(msg: => String): Unit
- Attributes
- protected
- Definition Classes
- Logging
- def logWarning(msg: => String, throwable: Throwable): Unit
- Attributes
- protected
- Definition Classes
- Logging
- def logWarning(msg: => String): Unit
- Attributes
- protected
- Definition Classes
- Logging
- final def ne(arg0: AnyRef): Boolean
- Definition Classes
- AnyRef
- final def notify(): Unit
- Definition Classes
- AnyRef
- Annotations
- @native()
- final def notifyAll(): Unit
- Definition Classes
- AnyRef
- Annotations
- @native()
- def optimizeGeneratedColumns(scan: LogicalPlan, preparedIndex: PreparedDeltaFileIndex, filters: Seq[Expression], limit: Option[Int], delta: LogicalRelation): LogicalPlan
- Attributes
- protected
- Definition Classes
- PrepareDeltaScanBase
- def optimizeQueryWithMetadata(plan: LogicalPlan): LogicalPlan
- Definition Classes
- OptimizeMetadataOnlyDeltaQuery
- def outputWithNullability(output: Seq[Attribute], nonNullAttrExprIds: Seq[ExprId]): Seq[Attribute]
- Attributes
- protected
- Definition Classes
- PredicateHelper
- def prepareDeltaScan(plan: LogicalPlan): LogicalPlan
Prepares delta scans sequentially.
Prepares delta scans sequentially.
- Attributes
- protected
- Definition Classes
- PrepareDeltaScanBase
- def prepareDeltaScanWithoutFileSkipping(plan: LogicalPlan): LogicalPlan
- Attributes
- protected
- Definition Classes
- PrepareDeltaScanBase
- def recordDeltaEvent(deltaLog: DeltaLog, opType: String, tags: Map[TagDefinition, String] = Map.empty, data: AnyRef = null, path: Option[Path] = None): Unit
Used to record the occurrence of a single event or report detailed, operation specific statistics.
Used to record the occurrence of a single event or report detailed, operation specific statistics.
- path
Used to log the path of the delta table when
deltaLogis null.
- Attributes
- protected
- Definition Classes
- DeltaLogging
- def recordDeltaOperation[A](deltaLog: DeltaLog, opType: String, tags: Map[TagDefinition, String] = Map.empty)(thunk: => A): A
Used to report the duration as well as the success or failure of an operation on a
deltaLog.Used to report the duration as well as the success or failure of an operation on a
deltaLog.- Attributes
- protected
- Definition Classes
- DeltaLogging
- def recordDeltaOperationForTablePath[A](tablePath: String, opType: String, tags: Map[TagDefinition, String] = Map.empty)(thunk: => A): A
Used to report the duration as well as the success or failure of an operation on a
tahoePath.Used to report the duration as well as the success or failure of an operation on a
tahoePath.- Attributes
- protected
- Definition Classes
- DeltaLogging
- def recordEvent(metric: MetricDefinition, additionalTags: Map[TagDefinition, String] = Map.empty, blob: String = null, trimBlob: Boolean = true): Unit
- Definition Classes
- DatabricksLogging
- def recordFrameProfile[T](group: String, name: String)(thunk: => T): T
- Attributes
- protected
- Definition Classes
- DeltaLogging
- def recordOperation[S](opType: OpType, opTarget: String = null, extraTags: Map[TagDefinition, String], isSynchronous: Boolean = true, alwaysRecordStats: Boolean = false, allowAuthTags: Boolean = false, killJvmIfStuck: Boolean = false, outputMetric: MetricDefinition = METRIC_OPERATION_DURATION, silent: Boolean = true)(thunk: => S): S
- Definition Classes
- DatabricksLogging
- def recordProductEvent(metric: MetricDefinition with CentralizableMetric, additionalTags: Map[TagDefinition, String] = Map.empty, blob: String = null, trimBlob: Boolean = true): Unit
- Definition Classes
- DatabricksLogging
- def recordProductUsage(metric: MetricDefinition with CentralizableMetric, quantity: Double, additionalTags: Map[TagDefinition, String] = Map.empty, blob: String = null, forceSample: Boolean = false, trimBlob: Boolean = true, silent: Boolean = false): Unit
- Definition Classes
- DatabricksLogging
- def recordUsage(metric: MetricDefinition, quantity: Double, additionalTags: Map[TagDefinition, String] = Map.empty, blob: String = null, forceSample: Boolean = false, trimBlob: Boolean = true, silent: Boolean = false): Unit
- Definition Classes
- DatabricksLogging
- def replaceAlias(expr: Expression, aliasMap: AttributeMap[Alias]): Expression
- Attributes
- protected
- Definition Classes
- AliasHelper
- def replaceAliasButKeepName(expr: NamedExpression, aliasMap: AttributeMap[Alias]): NamedExpression
- Attributes
- protected
- Definition Classes
- AliasHelper
- lazy val ruleId: RuleId
- Attributes
- protected
- Definition Classes
- Rule
- val ruleName: String
- Definition Classes
- Rule
- val spark: SparkSession
- Attributes
- protected
- def splitConjunctivePredicates(condition: Expression): Seq[Expression]
- Attributes
- protected
- Definition Classes
- PredicateHelper
- def splitDisjunctivePredicates(condition: Expression): Seq[Expression]
- Attributes
- protected
- Definition Classes
- PredicateHelper
- final def synchronized[T0](arg0: => T0): T0
- Definition Classes
- AnyRef
- def toString(): String
- Definition Classes
- AnyRef → Any
- def transformWithSubqueries(plan: LogicalPlan)(rule: PartialFunction[LogicalPlan, LogicalPlan]): LogicalPlan
Transform all nodes matched by the rule in the query plan rooted at given
plan.Transform all nodes matched by the rule in the query plan rooted at given
plan. It traverses the tree starting from the leaves, whenever a SubqueryExpression expression is encountered, given rule is applied to the subquery planplanin SubqueryExpression starting from theplanroot until leaves.This is slightly different behavior compared to QueryPlan.transformUpWithSubqueries or QueryPlan.transformDownWithSubqueries
It requires that the given plan already gone through OptimizeSubqueries and the root node denoting a subquery is removed and optimized appropriately.
- Definition Classes
- SubqueryTransformerHelper
- def trimAliases(e: Expression): Expression
- Attributes
- protected
- Definition Classes
- AliasHelper
- def trimNonTopLevelAliases[T <: Expression](e: T): T
- Attributes
- protected
- Definition Classes
- AliasHelper
- final def wait(): Unit
- Definition Classes
- AnyRef
- Annotations
- @throws(classOf[java.lang.InterruptedException])
- final def wait(arg0: Long, arg1: Int): Unit
- Definition Classes
- AnyRef
- Annotations
- @throws(classOf[java.lang.InterruptedException])
- final def wait(arg0: Long): Unit
- Definition Classes
- AnyRef
- Annotations
- @throws(classOf[java.lang.InterruptedException]) @native()
- def withStatusCode[T](statusCode: String, defaultMessage: String, data: Map[String, Any] = Map.empty)(body: => T): T
Report a log to indicate some command is running.
Report a log to indicate some command is running.
- Definition Classes
- DeltaProgressReporter
- object DeltaTableScan extends PrepareDeltaScan.DeltaTableScan[TahoeLogFileIndex]
This is an extractor object.
This is an extractor object. See https://docs.scala-lang.org/tour/extractor-objects.html.
- Definition Classes
- PrepareDeltaScanBase