lucene-java-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Michael McCandless <>
Subject Re: Loading less terms in memory
Date Fri, 06 Nov 2009 09:36:41 GMT
2.9 has fixed this bug (IndexReader.reopen failing to carry over the
index divisor to newly opened segments).

One workaround is to simply use reopen(), knowing that for the new
segments it's loading all your terms, but realizing that the new
segments are usually very small so the added memory usage is minor?
The problem is, on a large merge the new segments are not small.

Alternatively, if you can sneak code into the oal.index package, you
could call MultiSegmentReader.getSubReaders() and set the index
divisor yourself?  Any segment that's already loaded it terms index
will throw an IllegalStateException, which you can catch and suppress,
while the new segments will allow the call.


On Thu, Nov 5, 2009 at 5:46 AM, Ganesh <> wrote:
> Hello all,
> Due to some constraint in memory, I want to load less terms in memory. In case of Lucene
2.4.1, IndexDivisor is not working when we do reopen. Is there any other way out to achieve
> Regards
> Ganesh
> Send instant messages to your online friends
> ---------------------------------------------------------------------
> To unsubscribe, e-mail:
> For additional commands, e-mail:

To unsubscribe, e-mail:
For additional commands, e-mail:

View raw message