lucene-java-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Uwe Schindler <>
Subject Re: index size doubling / optimization (Lucene 3.0.3)
Date Fri, 11 Feb 2011 23:05:35 GMT

That is as expected. When IndexReader or IndexSearcher are open, the snapshot of this index
is preserved until you reopen it, as all readers only see the index in the state when it was
opened, so disk space is still acquired and on windows you even see the files. For optimize
(what you should really do only when you deleted lots of documents) this triples the required
space. This is even part of Javadocs.

When you are finished with updating the index you have to reopen your readers.

Uwe Schindler
H.-H.-Meier-Allee 63, 28213 Bremen

Phil Herold <> schrieb:

New information: it appears that the index size increasing (not always doubling but going
up significantly) occurs when I search the index while building it. Calling indexWriter.optimize(1,
true); when I'm done adding documents sometimes reduces the index down to size, but not always.
Has anyone else seen this? 

  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message