adriangb commented on code in PR #20142:
URL: https://github.com/apache/datafusion/pull/20142#discussion_r2761815407
##########
datafusion/physical-plan/src/joins/hash_join/exec.rs:
##########
@@ -479,12 +482,18 @@ pub struct HashJoinExec {
/// Set when dynamic filter pushdown is detected in
handle_child_pushdown_result.
/// HashJoinExec also needs to keep a shared bounds accumulator for
coordinating updates.
dynamic_filter: Option<HashJoinExecDynamicFilter>,
+ /// Temporary storage for per-partition DynamicFilters during filter
pushdown.
+ /// Set in gather_filters_for_pushdown, consumed in
handle_child_pushdown_result.
+ /// Uses Mutex because gather_filters_for_pushdown takes &self and may be
called
+ /// multiple times on the same node (e.g., when optimizations are re-run).
+ pending_partition_filters:
Mutex<Option<Vec<Arc<DynamicFilterPhysicalExpr>>>>,
Review Comment:
The alternative to this is to use the values passed into
`handle_child_pushdown_result` which *do* include the filters we are looking
for but it involves downcast matching through the CASE expression and then
cloning DynamicFilterPhysicalExpr
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]