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

[Feature Request] Optimize UnsignedLong range queries to convert to MatchNoDocsQuery when lower > upper bounds #14404

Closed
harshavamsi opened this issue Jun 17, 2024 · 0 comments · Fixed by #14416 or #14483
Labels
enhancement Enhancement or improvement to existing feature or request good first issue Good for newcomers Search:Performance v2.16.0 Issues and PRs related to version 2.16.0 v3.0.0 Issues and PRs related to version 3.0.0

Comments

@harshavamsi
Copy link
Contributor

harshavamsi commented Jun 17, 2024

Is your feature request related to a problem? Please describe

Coming from apache/lucene#13425, we see that most number fields can take advantage of the optimization when lower value > upper value when doing a range query by default. However, UnsignedLong uses its own implementation of SortedUnsignedLongDocValuesRangeQuery that could be optimized with the same change.

Describe the solution you'd like

In

public static Query unsignedLongRangeQuery(
we should check if lower > upper and return a MatchNoDocsQuery if so.

Related component

Search:Performance

Describe alternatives you've considered

No response

Additional context

No response

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement Enhancement or improvement to existing feature or request good first issue Good for newcomers Search:Performance v2.16.0 Issues and PRs related to version 2.16.0 v3.0.0 Issues and PRs related to version 3.0.0
Projects
Archived in project
2 participants