File tree Expand file tree Collapse file tree 2 files changed +8
-3
lines changed Expand file tree Collapse file tree 2 files changed +8
-3
lines changed Original file line number Diff line number Diff line change 2121//! 1. **Optimizer Asks Parent for a Filter Pushdown Plan**: The optimizer calls [`ExecutionPlan::gather_filters_for_pushdown`]
2222//! on the parent node, passing in parent predicates and phase. The parent node creates a [`FilterDescription`]
2323//! by inspecting its logic and children's schemas, determining which filters can be pushed to each child.
24- //! 2. **Optimizer Executes Pushdown**: The optimizer recursively calls [ `push_down_filters`] on each child,
24+ //! 2. **Optimizer Executes Pushdown**: The optimizer recursively calls `push_down_filters` in this module on each child,
2525//! passing the appropriate filters (`Vec<Arc<dyn PhysicalExpr>>`) for that child.
2626//! 3. **Optimizer Gathers Results**: The optimizer collects [`FilterPushdownPropagation`] results from children,
2727//! containing information about which filters were successfully pushed down vs. unsupported.
2828//! 4. **Parent Responds**: The optimizer calls [`ExecutionPlan::handle_child_pushdown_result`] on the parent,
2929//! passing a [`ChildPushdownResult`] containing the aggregated pushdown outcomes. The parent decides
3030//! how to handle filters that couldn't be pushed down (e.g., keep them as FilterExec nodes).
31+ //!
32+ //! [`FilterDescription`]: datafusion_physical_plan::filter_pushdown::FilterDescription
3133
3234use std:: sync:: Arc ;
3335
Original file line number Diff line number Diff line change 1818//! Filter Pushdown Optimization Process
1919//!
2020//! The filter pushdown mechanism involves four key steps:
21- //! 1. **Optimizer Asks Parent for a Filter Pushdown Plan**: The optimizer calls `ExecutionPlan::gather_filters_for_pushdown`
21+ //! 1. **Optimizer Asks Parent for a Filter Pushdown Plan**: The optimizer calls [ `ExecutionPlan::gather_filters_for_pushdown`]
2222//! on the parent node, passing in parent predicates and phase. The parent node creates a [`FilterDescription`]
2323//! by inspecting its logic and children's schemas, determining which filters can be pushed to each child.
2424//! 2. **Optimizer Executes Pushdown**: The optimizer recursively pushes down filters for each child,
2525//! passing the appropriate filters (`Vec<Arc<dyn PhysicalExpr>>`) for that child.
2626//! 3. **Optimizer Gathers Results**: The optimizer collects [`FilterPushdownPropagation`] results from children,
2727//! containing information about which filters were successfully pushed down vs. unsupported.
28- //! 4. **Parent Responds**: The optimizer calls `ExecutionPlan::handle_child_pushdown_result` on the parent,
28+ //! 4. **Parent Responds**: The optimizer calls [ `ExecutionPlan::handle_child_pushdown_result`] on the parent,
2929//! passing a [`ChildPushdownResult`] containing the aggregated pushdown outcomes. The parent decides
3030//! how to handle filters that couldn't be pushed down (e.g., keep them as FilterExec nodes).
31+ //!
32+ //! [`ExecutionPlan::gather_filters_for_pushdown`]: crate::ExecutionPlan::gather_filters_for_pushdown
33+ //! [`ExecutionPlan::handle_child_pushdown_result`]: crate::ExecutionPlan::handle_child_pushdown_result
3134//!
3235//! See also datafusion/physical-optimizer/src/filter_pushdown.rs.
3336
You can’t perform that action at this time.
0 commit comments