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

Avoid looping over merge segments in best merge selection

    XMLWordPrintableJSON

Details

    • Improvement
    • Status: Closed
    • Trivial
    • Resolution: Fixed
    • None
    • trunk, 7.1
    • core/index
    • None
    • New

    Description

      With java 8 we can trivially avoid looping over merge segments to be merged, switching from

      for(SegmentCommitInfo info : merge.segments) {
        toBeMerged.add(info);
      }
      

      to :

      toBeMerged.addAll(merge.segments);
      

      Attachments

        Activity

          People

            teofili Tommaso Teofili
            teofili Tommaso Teofili
            Votes:
            0 Vote for this issue
            Watchers:
            6 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: