CombineTypedFilters Logical Optimization¶
CombineTypedFilters
is a base logical optimization that <
CombineTypedFilters
is part of the Object Expressions Optimization fixed-point batch in the standard batches of the Logical Optimizer.
CombineTypedFilters
is simply a <Rule[LogicalPlan]
.
[source, scala]¶
scala> :type spark org.apache.spark.sql.SparkSession
// A query with two consecutive typed filters val q = spark.range(10).filter(_ % 2 == 0).filter(_ == 0) scala> q.queryExecution.optimizedPlan ... TRACE SparkOptimizer: === Applying Rule org.apache.spark.sql.catalyst.optimizer.CombineTypedFilters === TypedFilter
TRACE SparkOptimizer: Fixed point reached for batch Typed Filter Optimization after 2 iterations. DEBUG SparkOptimizer: === Result of Batch Typed Filter Optimization === TypedFilter
Executing Rule¶
apply(plan: LogicalPlan): LogicalPlan
apply
...FIXME
apply
is part of the Rule abstraction.