adriangb commented on code in PR #15566:
URL: https://github.com/apache/datafusion/pull/15566#discussion_r2029875884


##########
datafusion/datasource/src/source.rs:
##########
@@ -79,8 +82,20 @@ pub trait DataSource: Send + Sync + Debug {
         &self,
         _projection: &ProjectionExec,
     ) -> datafusion_common::Result<Option<Arc<dyn ExecutionPlan>>>;
+    /// Push down filters from parent execution plans to this data source.
+    /// This is expected to return Ok(None) if the filters cannot be pushed 
down.
+    /// If they can be pushed down it should return a [`FilterPushdownResult`] 
containing the new
+    /// data source and the support level for each filter (exact or inexact).
+    fn push_down_filters(
+        &self,
+        _filters: &[PhysicalExprRef],
+    ) -> datafusion_common::Result<Option<DataSourceFilterPushdownResult>> {

Review Comment:
   Yep makes sense, happy to do that. The important bit is that you can cheaply 
return the `NotPushed` variant without having to clone yourself, etc.



-- 
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