Skip to content

Conversation

@reta
Copy link
Member

@reta reta commented Nov 17, 2021

Signed-off-by: Andriy Redko [email protected]

Description

The TopScoreDocCollector::createSharedManager should use ScoreDoc instead of FieldDoc as a type of after argument. The FieldDoc is really needed only in case of TopFieldCollector but now its usage is mandated by TopScoreDocCollector and leads to unnecessary conversion tricks.

Solution

Relax after argument type from FieldDoc to ScoreDoc

Tests

The functionality is covered by existing tests. Since FieldDoc is a subclass of ScoreDoc, the change is fully compatible and non breaking.

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 created a Jira issue and added the issue ID to my pull request title.
  • 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.

…e ScoreDoc instead of FieldDoc

Signed-off-by: Andriy Redko <[email protected]>
@jpountz jpountz merged commit 6bd5c14 into apache:main Nov 18, 2021
jpountz pushed a commit that referenced this pull request Nov 18, 2021
…e ScoreDoc instead of FieldDoc (#450)

Signed-off-by: Andriy Redko <[email protected]>
@reta
Copy link
Member Author

reta commented Nov 18, 2021

Thank you @jpountz !

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.

2 participants