zhuqi-lucas opened a new pull request, #21457:
URL: https://github.com/apache/datafusion/pull/21457

   ## Which issue does this PR close?
   
   Closes #21433
   
   ## Rationale for this change
   
   As noted by @alamb in 
https://github.com/apache/datafusion/pull/21182#discussion_r3039838330, 
`file_scan_config.rs` has grown large after the sort pushdown optimization. 
This PR extracts the sort pushdown helpers into their own module to improve 
readability and maintainability.
   
   ## What changes are included in this PR?
   
   Move sort pushdown logic from `file_scan_config.rs` (3591 → 3066 lines) into 
a new `sort_pushdown.rs` module (576 lines):
   
   - `rebuild_with_source`, `try_sort_file_groups_by_statistics`
   - `sort_files_within_groups_by_statistics`, 
`any_file_has_nulls_in_sort_columns`
   - `validate_orderings`, `is_ordering_valid_for_file_groups`
   - `get_projected_output_ordering`, `ordered_column_indices_from_projection`
   - `SortedFileGroups` struct
   
   `try_pushdown_sort` stays in the `DataSource` impl — it calls into the new 
module.
   
   ## Are these changes tested?
   
   Pure refactor, all existing tests pass (120 passed).
   
   ## Are there any user-facing changes?
   
   No.


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