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

be more precise about IOContext for reads

    XMLWordPrintableJSON

Details

    • Improvement
    • Status: Resolved
    • Minor
    • Resolution: Fixed
    • None
    • 4.5.1, 4.6, 6.0
    • None
    • None
    • New, Patch Available

    Description

      Set the context as IOContext.READ / IOContext.READONCE where applicable


      Motivation:

      Custom PostingsFormat may want to check the context on SegmentReadState and branch differently, but for this to work properly the context has to be specified correctly up the stack.

      For example, DirectPostingsFormat only loads postings into memory if the context != MERGE. However a better condition would be context == Context.READ && !context.readOnce.

      Attachments

        1. LUCENE-4998.patch
          4 kB
          Shikhar Bhushan

        Activity

          People

            mikemccand Michael McCandless
            shikhar Shikhar Bhushan
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: