dongjoon-hyun opened a new pull request, #60312:
URL: https://github.com/apache/spark/pull/60312

   ### What changes were proposed in this pull request?
   
   This PR aims to enable `spark.sql.optimizer.datasourceV2JoinPushdown` in 
tests by changing its default value from `false` to `Utils.isTesting`. The 
default value stays `false` outside of tests.
   
   ### Why are the changes needed?
   
   DSv2 join pushdown has been available since [Apache Spark 4.1.0 
(2025-12-11)](https://github.com/apache/spark/releases/tag/v4.1.0) via 
SPARK-52187. Currently, only the JDBC data source implements 
`SupportsPushDownJoin`, for the H2, PostgreSQL, MySQL, SQL Server and Oracle 
dialects.
   
   Since this configuration is disabled by default, the join pushdown code path 
runs only in the test cases that enable it explicitly. SPARK-59710 fixed a 
wrong `AVG` result and a failure with `partitionColumn` only recently. With 
this PR, every test that joins two tables of the same JDBC catalog runs the 
join pushdown code path. This gives the feature more test coverage before we 
consider enabling it by default.
   
   ### Does this PR introduce _any_ user-facing change?
   
   No. The default value remains `false` outside of tests.
   
   ### How was this patch tested?
   
   Pass the CIs.
   
   In addition, the following JDBC and DSv2 test suites (45 suites, 1,660 
tests) passed locally with this configuration enabled.
   
   ```
   $ build/sbt 'sql/testOnly org.apache.spark.sql.jdbc.* 
org.apache.spark.sql.execution.datasources.v2.* 
org.apache.spark.sql.connector.DataSourceV2Suite 
org.apache.spark.sql.connector.DataSourceV2TableSampleSuite 
org.apache.spark.sql.connector.DataSourceV2SQLSuite*'
   ...
   [info] Tests: succeeded 1660, failed 0, canceled 77, ignored 2, pending 0
   [info] All tests passed.
   ```
   
   The Docker integration suites (`*JoinPushdownIntegrationSuite`) already 
enable this configuration explicitly.
   
   ### Was this patch authored or co-authored using generative AI tooling?
   
   Generated-by: Claude Opus 5.5
   


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

Reply via email to