Can we move SortField.Type.SCORE/DOC to singleton SortField instances instead...? [LUCENE-4722]
- Dominant language
- Java
- Stars
- 3.6k
- Forks
- 1.4k
- Avg merge
- 2d 11h
- Merged PRs (30d)
- 88
Description
It's ... weird that you can do eg new SortField("myfield", SortField.Type.SCORE).
We already have dedicated SortField.FIELD_SCORE and FIELD_DOC ... so I think apps should use those and never make a new SortField for them?
---
Migrated from [LUCENE-4722](https://issues.apache.org/jira/browse/LUCENE-4722) by Michael McCandless (@mikemccand), updated May 09 2016
Contributor guide
Research direction
Start by inspecting SortField.Type.SCORE and DOC alongside the existing SortField.FIELD_SCORE and FIELD_DOC entry points. Determine the compatibility implications of discouraging or removing construction with those types, then verify that the dedicated singleton instances cover the intended uses and update the relevant tests if they are found.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- java
- Domain
- search
- Issue type
- Refactor
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 30/100