lucene-java-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Yonik Seeley" <>
Subject Re: open file descriptors for deleted index files
Date Tue, 04 Sep 2007 20:07:32 GMT
On 9/4/07, Tony Qian <> wrote:
> We run a servlet inside Tomcat. We transfer index files to search server
> every 5 minutes using rsync with --delete option. Also, we schedule a
> TimeTask inside servlet to check if index files are updated. If yes, create
> a new IndexSearcher object and assign it to searcher (IndexSearcher). I hope
> JVM will GC old IndexSearcher object along with file descriptors.
> Will closing old IndexSearcher solve this problem?

Yes... you can't really rely on GC to close open file descriptors (or
for GC to be called when descriptors are running low)

> The concern I have by
> closing old IndexSearcher is that the client will get exception if client is
> using old IndexSearcher object.

Solr uses reference counting to solve this problem.


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

View raw message