Skip to content

Bug-16563: Imposed an ordering on the filter expressions while checking for equality and hashCode of spark scans.#16570

Open
ahshahid wants to merge 4 commits into
apache:mainfrom
ahshahid:Bug16563
Open

Bug-16563: Imposed an ordering on the filter expressions while checking for equality and hashCode of spark scans.#16570
ahshahid wants to merge 4 commits into
apache:mainfrom
ahshahid:Bug16563

Conversation

@ahshahid
Copy link
Copy Markdown

@ahshahid ahshahid commented May 26, 2026

Impose order on filter expressions ( runtime as well as data) while checking for equality and hashCode of Spark Scans, so that structurally same scans do not mismatch. This is critical for re-use of exchange to happen , where the pushdown of filters may differ in order, due to spark code using Set type collection for collecting filters for pushdown, resulting in unpredictable ordering of filters when pushed.
The change involves flattening the expressions and then ordering them based, on each Predicate's string representation.

Once this code patch is reviewed, same modifications may be done in other spark versions too, if required backport for older versions.

…ions while checking for equality and hashCode so that structurally same scans do not mismatch. This is critical for re-use of exchange to happen , where the pushdown of filters may differ in order, due to spark code using Set type collection for collecting filters for pushdown, resulting in unpredictable ordering of filters when pushed
@github-actions github-actions Bot added the spark label May 26, 2026
@ahshahid ahshahid changed the title Bug-16563: Imposed an ordering on the filter expressions while checking for equality and hashCode of spark scans. [WIP]: Bug-16563: Imposed an ordering on the filter expressions while checking for equality and hashCode of spark scans. May 26, 2026
@ahshahid
Copy link
Copy Markdown
Author

Once the tests suite completes, will remove the WIP

@ahshahid ahshahid changed the title [WIP]: Bug-16563: Imposed an ordering on the filter expressions while checking for equality and hashCode of spark scans. Bug-16563: Imposed an ordering on the filter expressions while checking for equality and hashCode of spark scans. May 26, 2026
@ahshahid ahshahid marked this pull request as draft May 26, 2026 19:43
@ahshahid ahshahid marked this pull request as ready for review May 26, 2026 19:46
ahshahid added 3 commits May 26, 2026 13:13
…ing reordering causing assertion failures. Instead of doing full string matches, matching individual filter string
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant