Description
Rough summary. Basically, FSDirectory tracks references to FSDirectory and when IndexReader.reopen shares a Directory with a created IndexReader and closeDirectory is true, FSDirectory's ref management will see two decrements for one increment. You can end up getting an AlreadyClosed exception on the Directory when the IndexReader is open.
I have a test I'll put up. A solution seems fairly straightforward (at least in what needs to be accomplished).
Attachments
Attachments
Issue Links
- is part of
-
LUCENE-1672 Deprecate all String/File ctors/opens in IndexReader/IndexWriter/IndexSearcher
- Closed
- is related to
-
LUCENE-1658 Absorb NIOFSDirectory into FSDirectory
- Closed