zhuqi-lucas opened a new pull request, #27940: URL: https://github.com/apache/datafusion/pull/27940
## Which issue does this PR close? - Backport of #27892 to `branch-56`, for #24463. - Closes #27891 for the 56 line. ## Rationale for this change On 56.0.0, `LimitPushdown` drops a limit above a custom leaf that still returns `true` from the deprecated `supports_limit_pushdown`: the default `limit_behavior` passes the limit to its children, and a leaf has none, so the query can return too many rows. #27892 fixed this on `main`. ## What changes are included in this PR? A cherry-pick of #27892 (`c75bc57`) with `-x`. It applied cleanly. ## What is the testing strategy for this PR? The tests from #27892 in `limit_pushdown.rs` pass on this branch, along with the rest of the physical optimizer integration tests and the sqllogictests. ## Are there any user-facing changes? A custom leaf that passes limits now gets the limit instead of losing it. Built-in leaves don't pass limits, so their plans don't change. No public API changes. -- 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]
