lucene-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Michael McCandless (JIRA)" <j...@apache.org>
Subject [jira] Commented: (LUCENE-2299) if you open an NRT reader while addIndexes* is running it may miss segments
Date Tue, 01 Jun 2010 09:16:37 GMT

    [ https://issues.apache.org/jira/browse/LUCENE-2299?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12873923#action_12873923
] 

Michael McCandless commented on LUCENE-2299:
--------------------------------------------

bq. So is in 3.1.

Yes.

> if you open an NRT reader while addIndexes* is running it may miss segments
> ---------------------------------------------------------------------------
>
>                 Key: LUCENE-2299
>                 URL: https://issues.apache.org/jira/browse/LUCENE-2299
>             Project: Lucene - Java
>          Issue Type: Bug
>          Components: Index
>    Affects Versions: 2.9.3, 3.0.2, 3.1, 4.0
>            Reporter: Michael McCandless
>            Assignee: Michael McCandless
>            Priority: Minor
>             Fix For: 2.9.3, 3.0.2, 3.1, 4.0
>
>         Attachments: LUCENE-2299.patch
>
>
> Earwin spotted this in pending ongoing refactoring of Dir/MultiReader, but I wanted to
open this separately just to make sure we fix it for 3.1...
> This is the fix:
> {code}
> Index: src/java/org/apache/lucene/index/DirectoryReader.java
> ===================================================================
> --- src/java/org/apache/lucene/index/DirectoryReader.java	(revision 919119)
> +++ src/java/org/apache/lucene/index/DirectoryReader.java	(working copy)
> @@ -145,7 +145,7 @@
>      for (int i=0;i<numSegments;i++) {
>        boolean success = false;
>        try {
> -        final SegmentInfo info = infos.info(upto);
> +        final SegmentInfo info = infos.info(i);
>          if (info.dir == dir) {
>            readers[upto++] = writer.readerPool.getReadOnlyClone(info, true, termInfosIndexDivisor);
>          }
> {code}

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@lucene.apache.org
For additional commands, e-mail: dev-help@lucene.apache.org


Mime
View raw message