ESQL: Fix lookup join filter pushdown to use semantic equality#136818
Merged
elasticsearchmachine merged 4 commits intoelastic:mainfrom Oct 22, 2025
Merged
Conversation
Collaborator
|
Pinging @elastic/es-analytical-engine (Team:Analytics) |
alex-spies
approved these changes
Oct 22, 2025
Contributor
alex-spies
left a comment
There was a problem hiding this comment.
This is great, thanks @kanoshiou !
Cc @julian-elastic , it's interesting to run the test query and see why this bug happened on current main.
I think we should also backport this to 9.2.
x-pack/plugin/esql/qa/testFixtures/src/main/resources/lookup-join.csv-spec
Outdated
Show resolved
Hide resolved
…ter-dedup-semantic-equals
Contributor
|
@elasticsearchmachine test this please |
Contributor
|
@elasticsearchmachine test this please |
Collaborator
💔 Backport failed
You can use sqren/backport to manually backport by running |
Contributor
💚 All backports created successfully
Questions ?Please refer to the Backport tool documentation |
alex-spies
pushed a commit
to alex-spies/elasticsearch
that referenced
this pull request
Oct 23, 2025
…ic#136818) Previously, when pushing down filters to the right side of a lookup join, we used simple equality (contains) to check for duplicate filters. This could result in semantically equivalent filters being added multiple times if they were different object instances. This commit changes the duplicate check to use `semanticEquals()` instead, ensuring that filters with the same semantic meaning are properly deduplicated regardless of object identity. Closes elastic#136599 (cherry picked from commit f54987f) # Conflicts: # x-pack/plugin/esql/qa/server/src/main/java/org/elasticsearch/xpack/esql/qa/rest/generative/GenerativeRestTest.java # x-pack/plugin/esql/src/main/java/org/elasticsearch/xpack/esql/action/EsqlCapabilities.java
elasticsearchmachine
pushed a commit
that referenced
this pull request
Oct 23, 2025
…) (#136999) Previously, when pushing down filters to the right side of a lookup join, we used simple equality (contains) to check for duplicate filters. This could result in semantically equivalent filters being added multiple times if they were different object instances. This commit changes the duplicate check to use `semanticEquals()` instead, ensuring that filters with the same semantic meaning are properly deduplicated regardless of object identity. Closes #136599 (cherry picked from commit f54987f) # Conflicts: # x-pack/plugin/esql/qa/server/src/main/java/org/elasticsearch/xpack/esql/qa/rest/generative/GenerativeRestTest.java # x-pack/plugin/esql/src/main/java/org/elasticsearch/xpack/esql/action/EsqlCapabilities.java Co-authored-by: kanoshiou <uiaao@tuta.io>
fzowl
pushed a commit
to voyage-ai/elasticsearch
that referenced
this pull request
Nov 3, 2025
…ic#136818) Previously, when pushing down filters to the right side of a lookup join, we used simple equality (contains) to check for duplicate filters. This could result in semantically equivalent filters being added multiple times if they were different object instances. This commit changes the duplicate check to use `semanticEquals()` instead, ensuring that filters with the same semantic meaning are properly deduplicated regardless of object identity. Closes elastic#136599
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Previously, when pushing down filters to the right side of a lookup join, we used simple equality (contains) to check for duplicate filters. This could result in semantically equivalent filters being added multiple times if they were different object instances.
This commit changes the duplicate check to use
semanticEquals()instead, ensuring that filters with the same semantic meaning are properly deduplicated regardless of object identity.Closes #136599