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

LUCENE-10555: fix NumericComparator#iteratorCost initial logic error #878

Merged
merged 1 commit into from
May 11, 2022

Conversation

wjp719
Copy link
Contributor

@wjp719 wjp719 commented May 11, 2022

#864 judges if NumericComparator#iteratorCost is -1 or not to determine whether to set NumericComparator#iteratorCost in NumericComparator#setScorer, but NumericComparator#iteratorCost is set as maxDoc in NumericComparator construction method, So #864 does not work normally.

this pr fix this logic error

Checklist

Please review the following and check all that apply:

  • I have reviewed the guidelines for How to Contribute and my code conforms to the standards described there to the best of my ability.
  • I have given Lucene maintainers access to contribute to my PR branch. (optional but recommended)
  • I have developed this patch against the main branch.
  • I have run ./gradlew check.
  • I have added tests for my changes.

@wjp719
Copy link
Contributor Author

wjp719 commented May 11, 2022

@jpountz Hi, I see your commit 8476ac1f6ac5258052f93e85278f70770fe3dfd5 solves tests TestSortOptimization error, maybe is caused by #864, this pr fix it, please help to review, thanks.

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.

Sorry for putting you on the wrong track previously!

@jpountz jpountz merged commit 6c6bb00 into apache:main May 11, 2022
@wjp719 wjp719 deleted the feature/repeated_set_scorer branch May 11, 2022 06:40
wjp719 added a commit to wjp719/lucene that referenced this pull request May 11, 2022
* main:
  LUCENE-10555: fix iteratorCost initial logic error (apache#878)
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.

None yet

2 participants