@@ -44,10 +44,10 @@ use datafusion_physical_expr::{
4444 aggregate:: AggregateExprBuilder , conjunction, Partitioning ,
4545} ;
4646use datafusion_physical_expr_common:: physical_expr:: fmt_sql;
47- use datafusion_physical_optimizer:: push_down_filter :: PushdownFilter ;
47+ use datafusion_physical_optimizer:: filter_pushdown :: FilterPushdown ;
4848use datafusion_physical_optimizer:: PhysicalOptimizerRule ;
4949use datafusion_physical_plan:: filter_pushdown:: {
50- FilterPushdownPropagation , FilterPushdowns ,
50+ FilterPushdownPropagation , PredicateSupports ,
5151} ;
5252use datafusion_physical_plan:: {
5353 aggregates:: { AggregateExec , AggregateMode , PhysicalGroupBy } ,
@@ -153,7 +153,7 @@ impl FileSource for TestSource {
153153
154154 fn try_pushdown_filters (
155155 & self ,
156- filters : & [ Arc < dyn PhysicalExpr > ] ,
156+ filters : Vec < Arc < dyn PhysicalExpr > > ,
157157 config : & ConfigOptions ,
158158 ) -> Result < FilterPushdownPropagation < Arc < dyn FileSource > > > {
159159 let mut all_filters = filters. iter ( ) . map ( Arc :: clone) . collect :: < Vec < _ > > ( ) ;
@@ -167,8 +167,8 @@ impl FileSource for TestSource {
167167 statistics : self . statistics . clone ( ) , // should be updated in reality
168168 } ) ;
169169 Ok ( FilterPushdownPropagation {
170- parent_filter_result : FilterPushdowns :: all_supported ( & all_filters) ,
171- new_node : Some ( new_node) ,
170+ filters : PredicateSupports :: all_supported ( all_filters) ,
171+ updated_node : Some ( new_node) ,
172172 } )
173173 } else {
174174 Ok ( FilterPushdownPropagation :: unsupported ( filters) )
@@ -196,7 +196,7 @@ fn test_pushdown_into_scan() {
196196
197197 // expect the predicate to be pushed down into the DataSource
198198 insta:: assert_snapshot!(
199- OptimizationTest :: new( plan, PushdownFilter { } , true ) ,
199+ OptimizationTest :: new( plan, FilterPushdown { } , true ) ,
200200 @r"
201201 OptimizationTest:
202202 input:
@@ -220,7 +220,7 @@ fn test_pushdown_into_scan_with_config_options() {
220220 insta:: assert_snapshot!(
221221 OptimizationTest :: new(
222222 Arc :: clone( & plan) ,
223- PushdownFilter { } ,
223+ FilterPushdown { } ,
224224 false
225225 ) ,
226226 @r"
@@ -239,7 +239,7 @@ fn test_pushdown_into_scan_with_config_options() {
239239 insta:: assert_snapshot!(
240240 OptimizationTest :: new(
241241 plan,
242- PushdownFilter { } ,
242+ FilterPushdown { } ,
243243 true
244244 ) ,
245245 @r"
@@ -264,7 +264,7 @@ fn test_filter_collapse() {
264264 let plan = Arc :: new ( FilterExec :: try_new ( predicate2, filter1) . unwrap ( ) ) ;
265265
266266 insta:: assert_snapshot!(
267- OptimizationTest :: new( plan, PushdownFilter { } , true ) ,
267+ OptimizationTest :: new( plan, FilterPushdown { } , true ) ,
268268 @r"
269269 OptimizationTest:
270270 input:
@@ -294,7 +294,7 @@ fn test_filter_with_projection() {
294294
295295 // expect the predicate to be pushed down into the DataSource but the FilterExec to be converted to ProjectionExec
296296 insta:: assert_snapshot!(
297- OptimizationTest :: new( plan, PushdownFilter { } , true ) ,
297+ OptimizationTest :: new( plan, FilterPushdown { } , true ) ,
298298 @r"
299299 OptimizationTest:
300300 input:
@@ -318,7 +318,7 @@ fn test_filter_with_projection() {
318318 . unwrap ( ) ,
319319 ) ;
320320 insta:: assert_snapshot!(
321- OptimizationTest :: new( plan, PushdownFilter { } , true ) ,
321+ OptimizationTest :: new( plan, FilterPushdown { } , true ) ,
322322 @r"
323323 OptimizationTest:
324324 input:
@@ -347,7 +347,7 @@ fn test_push_down_through_transparent_nodes() {
347347
348348 // expect the predicate to be pushed down into the DataSource
349349 insta:: assert_snapshot!(
350- OptimizationTest :: new( plan, PushdownFilter { } , true ) ,
350+ OptimizationTest :: new( plan, FilterPushdown { } , true ) ,
351351 @r"
352352 OptimizationTest:
353353 input:
@@ -411,7 +411,7 @@ fn test_no_pushdown_through_aggregates() {
411411
412412 // expect the predicate to be pushed down into the DataSource
413413 insta:: assert_snapshot!(
414- OptimizationTest :: new( plan, PushdownFilter { } , true ) ,
414+ OptimizationTest :: new( plan, FilterPushdown { } , true ) ,
415415 @r"
416416 OptimizationTest:
417417 input:
0 commit comments