-
Notifications
You must be signed in to change notification settings - Fork 25.2k
Using competitive iterators in Filters agg is broken #126955
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Comments
Pinging @elastic/es-analytical-engine (Team:Analytics) |
Pinging @elastic/es-search (Team:Search) |
I THINK it has to do with the "intoBitSet" stuff. If it does regular iteration, everything works well, Once it does |
OK, I think I see the issue, I am not sure how to fix. The
, doing an
So, the docId stream we then get in the leaf collector is the set of docIds where the iterators overlap. However, we need to know which doc actually matches which doc (e.g. topList). So, I don't know how to handle that. It seems we need to handle this bitset iteration correctly (or bypass it somehow). Class in question: https://github.com/apache/lucene/blob/branch_10_2/lucene/core/src/java/org/apache/lucene/search/DenseConjunctionBulkScorer.java |
With the way that |
related: apache/lucene#14517 |
FYSA we also have #126939 tracking the stack trace that you shared in that lucene issue, @benwtrent |
I can think of two fixes:
|
Removing the blocker tag. We have disabled competitive iterators in filters agg. While we want to be able to recover performance, it is currently no longer a blocking bug as behavior is correct now. |
Elasticsearch Version
9.1.0
Installed Plugins
No response
Java Version
bundled
OS Version
any
Problem Description
When using a query & a filters aggregation, we may use a competitive iterator, with the Lucene 10.2 upgrade, this is now broken. This results in an indeterminable number of counts. The exact reasoning is still unknown
Steps to Reproduce
This has been replicated in a unit test and will be committed shortly.
Generally, the idea is you have terms that you are filtering on and doing a filters agg while also doing a term query.
Logs (if relevant)
No response
The text was updated successfully, but these errors were encountered: