lucene-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Michael McCandless (JIRA)" <>
Subject [jira] Commented: (LUCENE-2759) We should never open an IndexInput when an IndexOutput is still open
Date Mon, 15 Nov 2010 14:17:13 GMT


Michael McCandless commented on LUCENE-2759:

bq. In the LUCENE-2312 patch the doc stores are being flushed on get reader and the doc stores
read successfully.

Flushed by not closed?  And that works fine on Windows?  That's fascinating to me :)

Ie, that our dir impls are able to get an IndexInput when there's still an IndexOutput writing
to it.

But for RT this will be necessary.  I had thought that we'd have to extend Directory to explicitly
add eg an IndexInputOutput, ie designed for full read/write.

> We should never open an IndexInput when an IndexOutput is still open
> --------------------------------------------------------------------
>                 Key: LUCENE-2759
>                 URL:
>             Project: Lucene - Java
>          Issue Type: Bug
>          Components: Index
>            Reporter: Michael McCandless
>            Assignee: Michael McCandless
>             Fix For: 2.9.4, 3.0.3, 3.1, 4.0
>         Attachments: LUCENE-2759.patch
> I modified MockDirWrapper to assert this (except for
> segments_N/segments.gen, where it's expected), and, it uncovered a
> couple of places involving NRT readers where we open a shared doc
> store file that's still open for writing.
> First, if you install a merged segment warmer, we were failing to
> force the merge of the doc stores in this case, thus potentially
> opening the same doc stores that are also still open for writing.
> Second, if you're actively adding docs in other threads when you call
> IW.getReader(), the other threads could sneak in and flush new
> segments sharing the doc stores.  The returned reader then opens the
> doc store files that are still open for writing.

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:
For additional commands, e-mail:

View raw message