You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@lucenenet.apache.org by Robert Stewart <Ro...@epam.com> on 2011/06/16 16:17:16 UTC

[Lucene.Net] alternatives to FSDirectory for multi-threaded search performance

What are the recommended best practices for using FSDirectory vs. RamDirectory, etc. for use in multi-threaded search?

In a previous version of Lucene.Net (1.9) I used a modified FSDirectory implementation which used a pool of open FileStream objects for each segment file, and handed them out in round-robin fashion from the Clone() method.  That way multiple threads could read most segment files in parallel.  It definitely increased multithreaded search performance quite a bit.  My indexes are quite large (100+ million docs) and I can not load entire segments in to RAM using RamDirectory.

My question is what is the best practice here?  Is using a pool of descriptors as described above the best idea?

Thanks
Bob