Skip to content
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

count() in BooleanQuery could be early quit #11895

Merged
merged 3 commits into from
Nov 15, 2022

Conversation

LuXugang
Copy link
Member

@LuXugang LuXugang commented Nov 2, 2022

Since all queries are pure disjunctional, we could quit early and make the logic much simpler?

@LuXugang LuXugang requested a review from jpountz November 2, 2022 10:58
Copy link
Contributor

@jpountz jpountz left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks @LuXugang this change makes sense to me.

@jpountz
Copy link
Contributor

jpountz commented Nov 7, 2022

This makes me think that we could also enhance this logic to count queries that have a mix of SHOULD and MUST_NOT clauses, in case this is something you are interested in looking into in a follow-up.

@LuXugang LuXugang merged commit e5426db into apache:main Nov 15, 2022
@LuXugang
Copy link
Member Author

This makes me think that we could also enhance this logic to count queries that have a mix of SHOULD and MUST_NOT clauses, in case this is something you are interested in looking into in a follow-up.

Thanks @jpountz I would like to look into it later.

LuXugang added a commit that referenced this pull request Nov 24, 2022
* Count() in BooleanQuery could be early quit if queries are pure disjunctional
@rmuir rmuir added this to the 9.5.0 milestone Jan 17, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants