On Oct 5, 2005, at 9:03 PM, Cyril Barlow wrote:



I'm getting :

 java.io.IOException: The handle is invalid at
java.io.RandomAccessFile.seek(Native Method) at


Did you perhaps close the IndexSearcher somewhere along the way?

     Erik



No, but I'm now creating new IndexSearchers every servlet doPost method and not closing them. It works without the caching probems for some reason and it's much quicker?? I'm hoping the garbage collector sorts the cleaning up
though..

Creating an IndexSearcher for every request goes against how to use Lucene best. A _single_ IndexSearcher for all searches is optimum.

You really ought to look into using a single instance.

    Erik


---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to