jayzhan211 commented on code in PR #15685:
URL: https://github.com/apache/datafusion/pull/15685#discussion_r2040452282


##########
datafusion/physical-expr/src/expressions/dynamic_filters.rs:
##########
@@ -36,16 +36,8 @@ use super::Column;
 /// A dynamic [`PhysicalExpr`] that can be updated by anyone with a reference 
to it.
 #[derive(Debug)]
 pub struct DynamicFilterPhysicalExpr {
-    /// The original children of this PhysicalExpr, if any.
-    /// This is necessary because the dynamic filter may be initialized with a 
placeholder (e.g. `lit(true)`)
-    /// and later remapped to the actual expressions that are being filtered.
-    /// But we need to know the children (e.g. columns referenced in the 
expression) ahead of time to evaluate the expression correctly.
-    // columns: Vec<Arc<dyn PhysicalExpr>>,
-    // /// If any of the children were remapped / modified (e.g. to adjust for 
projections) we need to keep track of the new children
-    // /// so that when we update `current()` in subsequent iterations we can 
re-apply the replacements.
-    remapped_schema: Option<SchemaRef>,
     /// The source of dynamic filters.
-    inner: Arc<RwLock<PhysicalExprRef>>,
+    inner: PhysicalExprRef,

Review Comment:
   I think we don't need it. Given a source filter, you create snapshot with 
the schema. Then you evaluate based on the remapped filter. When you need a new 
source filter, instead of updating it, just create a new one



-- 
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: github-unsubscr...@datafusion.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: github-unsubscr...@datafusion.apache.org
For additional commands, e-mail: github-h...@datafusion.apache.org

Reply via email to