2011/4/1 Yogesh Dabhi <yda...@asite.com>: > Hi > > Concurrently 5 user access same lucene directory for searching document > > That time I got bellow exception > > org.apache.lucene.store.AlreadyClosedException: this IndexReader is > closed > > is there a way to handle such error
Use a ReentrantReaderWriterLock around the process of re-opening your IndexReader and re-creating your IndexSearcher (or closing your reader, if that's all you're doing), and the process of using your IndexSearcher for searching. --dho > Thanks & Regards > > Yogesh > > --------------------------------------------------------------------- To unsubscribe, e-mail: java-user-unsubscr...@lucene.apache.org For additional commands, e-mail: java-user-h...@lucene.apache.org