Uploaded image for project: 'Lucene - Core'
  1. Lucene - Core
  2. LUCENE-7063

NumericUtils vs LegacyNumericUtils chaos with 6.0

    XMLWordPrintableJSON

    Details

    • Type: Bug
    • Status: Resolved
    • Priority: Major
    • Resolution: Fixed
    • Affects Version/s: None
    • Fix Version/s: 6.0
    • Component/s: None
    • Labels:
      None
    • Lucene Fields:
      New

      Description

      Old prefix-coded terms helper functions are still available in LegacyNumericUtils, but its confusing when upgrading because NumericUtils and LegacyNumericUtils have overlaps in the APIs.

      One issue is they share some exact methods that are completely unrelated to this encoding (e.g. floatToSortableInt). The method is just duplication and worst, most lucene code is still calling it from LegacyNumericUtils, even stuff like faceting code using it with docvalues.

      Another issue is the new NumericUtils methods (which use full byte range) have vague names, no javadocs, expose helper methods as public unnecessarily, and cause general confusion.

      I don't think NumericUtils and LegacyNumericUtils should overlap. LegacyNumericUtils should only contain legacy stuff!

        Attachments

        1. LUCENE-7063.patch
          107 kB
          Robert Muir
        2. LUCENE-7063.patch
          81 kB
          Robert Muir

          Activity

            People

            • Assignee:
              Unassigned
              Reporter:
              rcmuir Robert Muir
            • Votes:
              0 Vote for this issue
              Watchers:
              3 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: