Skip to content

Conversation

@surajnayak
Copy link

Bugfix - BitmapIndexQuery and BitmapDocValuesQuery to support both +ve and -ve values in same query. also add test cases for negative set of bitmaps.

Description

  • Changes BitmapIndexQuery to use bitmap.getSignedIntIterator() instead of bitmap.getIntIterator()
  • Changes BitmapDocValuesQuery to set max with unsigned int representation of signed integer. and adds 2^32 if the value is < 0 in matches method

Related Issues

Resolves #18422

Check List

  • Functionality includes testing.
  • API changes companion pull request created, if applicable.
  • Public documentation issue/PR created, if applicable.

By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license.
For more information on following Developer Certificate of Origin and signing off your commits, please check here.

…set of both +ve and -ve values in same query. also add test cases for negative set of bitmaps.

Signed-off-by: Suraj Nayak <[email protected]>
Signed-off-by: Suraj Nayak <[email protected]>
@github-actions
Copy link
Contributor

github-actions bot commented Oct 4, 2025

❌ Gradle check result for 5ddd8bf: null

Please examine the workflow log, locate, and copy-paste the failure(s) below, then iterate to green. Is the failure a flaky test unrelated to your change?

@opensearch-trigger-bot
Copy link
Contributor

This PR is stalled because it has been open for 30 days with no activity.

@opensearch-trigger-bot opensearch-trigger-bot bot added the stalled Issues that have stalled label Nov 3, 2025
@github-actions
Copy link
Contributor

github-actions bot commented Nov 3, 2025

❌ Gradle check result for 5ddd8bf: FAILURE

Please examine the workflow log, locate, and copy-paste the failure(s) below, then iterate to green. Is the failure a flaky test unrelated to your change?

@msfroh
Copy link
Contributor

msfroh commented Nov 3, 2025

@surajnayak -- Are the negative values here behaving like positive integers greater than Integer.MAX_VALUE?

On #18422, I was thinking that we should just disallow negative values for these filters. If/when we add an unsigned_int field type, we could support values between 2^31 and 2^32 - 1.

@opensearch-trigger-bot opensearch-trigger-bot bot removed the stalled Issues that have stalled label Nov 4, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

bug Something isn't working discuss Issues intended to help drive brainstorming and decision making lucene Search:Query Capabilities

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[BUG] Bitmap filtering inconsistent behaviour for unsigned integer values greater than Integer.MAX_VALUE

2 participants