Lucene - Core
  1. Lucene - Core
  2. LUCENE-3606

Make IndexReader really read-only in Lucene 4.0

    Details

    • Type: Task Task
    • Status: Closed
    • Priority: Major Major
    • Resolution: Fixed
    • Affects Version/s: 4.0-ALPHA
    • Fix Version/s: 3.6, 4.0-ALPHA
    • Component/s: core/index
    • Labels:
      None
    • Lucene Fields:
      New

      Description

      As we change API completely in Lucene 4.0 we are also free to remove read-write access and commits from IndexReader. This code is so hairy and buggy (as investigated by Robert and Mike today) when you work on SegmentReader level but forget to flush in the DirectoryReader, so its better to really make IndexReaders readonly.

      Currently with IndexReader you can do things like:

      • delete/undelete Documents -> Can be done by with IndexWriter, too (using deleteByQuery)
      • change norms -> this is a bad idea in general, but when we remove norms at all and replace by DocValues this is obsolete already. Changing DocValues should also be done using IndexWriter in trunk (once it is ready)
      1. LUCENE-3606-hideMethodAgain.patch
        3 kB
        Uwe Schindler
      2. LUCENE-3606-deprecations3x.patch
        26 kB
        Uwe Schindler
      3. LUCENE-3606-deprecations3x.patch
        28 kB
        Uwe Schindler
      4. LUCENE-3606-deprecations3x.patch
        31 kB
        Uwe Schindler
      5. LUCENE-3606.patch
        541 kB
        Uwe Schindler

        Issue Links

          Activity

          Uwe Schindler created issue -
          Uwe Schindler made changes -
          Field Original Value New Value
          Assignee Uwe Schindler [ thetaphi ]
          Uwe Schindler made changes -
          Link This issue incorporates LUCENE-3620 [ LUCENE-3620 ]
          Uwe Schindler made changes -
          Attachment LUCENE-3606.patch [ 12506640 ]
          Uwe Schindler made changes -
          Fix Version/s 4.0 [ 12314025 ]
          Uwe Schindler made changes -
          Attachment LUCENE-3606-hideMethodAgain.patch [ 12506717 ]
          Uwe Schindler made changes -
          Attachment LUCENE-3606-deprecations3x.patch [ 12506721 ]
          Uwe Schindler made changes -
          Attachment LUCENE-3606-deprecations3x.patch [ 12506724 ]
          Uwe Schindler made changes -
          Attachment LUCENE-3606-deprecations3x.patch [ 12506757 ]
          Uwe Schindler made changes -
          Status Open [ 1 ] Resolved [ 5 ]
          Resolution Fixed [ 1 ]
          Uwe Schindler made changes -
          Fix Version/s 3.6 [ 12319070 ]
          Uwe Schindler made changes -
          Status Resolved [ 5 ] Closed [ 6 ]

            People

            • Assignee:
              Uwe Schindler
              Reporter:
              Uwe Schindler
            • Votes:
              0 Vote for this issue
              Watchers:
              0 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved:

                Development