Skip to content

Commit 1068f39

Browse files
committed
fix: cargo fmt, clippy clone_on_ref_ptr, update configs.md
1 parent ae2a0b8 commit 1068f39

File tree

3 files changed

+3
-4
lines changed

3 files changed

+3
-4
lines changed

datafusion/physical-expr/src/expression_analyzer/default.rs

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -70,7 +70,6 @@ impl DefaultExpressionAnalyzer {
7070
_ => None,
7171
}
7272
}
73-
7473
}
7574

7675
impl ExpressionAnalyzer for DefaultExpressionAnalyzer {

datafusion/physical-plan/src/filter.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2658,7 +2658,7 @@ mod tests {
26582658
schema.clone(),
26592659
));
26602660
// (a = 42 OR b = 5): OR is not expressible as a single interval
2661-
let predicate = Arc::new(BinaryExpr::new(
2661+
let predicate: Arc<dyn PhysicalExpr> = Arc::new(BinaryExpr::new(
26622662
Arc::new(BinaryExpr::new(
26632663
Arc::new(Column::new("a", 0)),
26642664
Operator::Eq,
@@ -2673,7 +2673,7 @@ mod tests {
26732673
));
26742674

26752675
// Without ExpressionAnalyzer: default 20% selectivity -> 200 rows
2676-
let filter = Arc::new(FilterExec::try_new(predicate.clone(), input as _)?);
2676+
let filter = Arc::new(FilterExec::try_new(Arc::clone(&predicate), input as _)?);
26772677
let stats = filter.partition_statistics(None)?;
26782678
assert_eq!(stats.num_rows, Precision::Inexact(200));
26792679

docs/source/user-guide/configs.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -145,7 +145,7 @@ The following configuration settings are available:
145145
| datafusion.optimizer.enable_join_dynamic_filter_pushdown | true | When set to true, the optimizer will attempt to push down Join dynamic filters into the file scan phase. |
146146
| datafusion.optimizer.enable_aggregate_dynamic_filter_pushdown | true | When set to true, the optimizer will attempt to push down Aggregate dynamic filters into the file scan phase. |
147147
| datafusion.optimizer.enable_dynamic_filter_pushdown | true | When set to true attempts to push down dynamic filters generated by operators (TopK, Join & Aggregate) into the file scan phase. For example, for a query such as `SELECT * FROM t ORDER BY timestamp DESC LIMIT 10`, the optimizer will attempt to push down the current top 10 timestamps that the TopK operator references into the file scans. This means that if we already have 10 timestamps in the year 2025 any files that only have timestamps in the year 2024 can be skipped / pruned at various stages in the scan. The config will suppress `enable_join_dynamic_filter_pushdown`, `enable_topk_dynamic_filter_pushdown` & `enable_aggregate_dynamic_filter_pushdown` So if you disable `enable_topk_dynamic_filter_pushdown`, then enable `enable_dynamic_filter_pushdown`, the `enable_topk_dynamic_filter_pushdown` will be overridden. |
148-
| datafusion.optimizer.use_expression_analyzer | false | When set to true, the pluggable `ExpressionAnalyzerRegistry` from `SessionState` is injected into exec nodes that use expression-level statistics (`FilterExec`, `ProjectionExec`, `AggregateExec`, join nodes) and re-injected after each physical optimizer rule so rebuilt nodes always carry it. Custom analyzers then influence `partition_statistics` in those operators. |
148+
| datafusion.optimizer.use_expression_analyzer | false | When set to true, the pluggable `ExpressionAnalyzerRegistry` from `SessionState` is used for expression-level statistics estimation (NDV, selectivity, min/max, null fraction) in physical plan operators. |
149149
| datafusion.optimizer.filter_null_join_keys | false | When set to true, the optimizer will insert filters before a join between a nullable and non-nullable column to filter out nulls on the nullable side. This filter can add additional overhead when the file format does not fully support predicate push down. |
150150
| datafusion.optimizer.repartition_aggregations | true | Should DataFusion repartition data using the aggregate keys to execute aggregates in parallel using the provided `target_partitions` level |
151151
| datafusion.optimizer.repartition_file_min_size | 10485760 | Minimum total files size in bytes to perform file scan repartitioning. |

0 commit comments

Comments
 (0)