I have just noticed that I subscribed the wrong list. I meant to
subscribe and email the Java User List.
Sorry
Nuno Seco wrote:
Hello.
I'm struggling with the following exception:
Exception in thread "Lucene Merge Thread #1037"
org.apache.lucene.index.MergePolicy$MergeException:
java.io.FileNotFoundException:
/home/plopes/aktwise/server-commons/data/lucenedata/_80c.tii (Too many
open files)
at
org.apache.lucene.index.ConcurrentMergeScheduler.handleMergeException(ConcurrentMergeScheduler.java:309)
at
org.apache.lucene.index.ConcurrentMergeScheduler$MergeThread.run(ConcurrentMergeScheduler.java:286)
Caused by: java.io.FileNotFoundException:
/home/plopes/aktwise/server-commons/data/lucenedata/_80c.tii (Too many
open files)
I have only one indexwriter instantiated, and every time i update the
index (add or remove a document), i commit the indexwriter and run the
following code in order to make the searcher aware of the new documents:
private synchronized void refreshSearcher() throws
CorruptIndexException, IOException
{
try
{
IndexReader reader =
searcher.getIndexReader().reopen();
searcher.close();
searcher = new IndexSearcher(reader);
if (reader != searcher.getIndexReader())
searcher.getIndexReader().close();
}
catch (Exception e)
{
e.printStackTrace();
}
}
I have tried lowering the merge factor and the number of threads by
executing the following:
((ConcurrentMergeScheduler)writer.getMergeScheduler()).setMaxThreadCount(1);
writer.setMergeFactor(3);
I am using lucene 2.4.0 and there is only one thread manipulating the
index.
any help would be appreciated.
Nuno Seco
---------------------------------------------------------------------
To unsubscribe, e-mail: java-dev-unsubscr...@lucene.apache.org
For additional commands, e-mail: java-dev-h...@lucene.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: java-dev-unsubscr...@lucene.apache.org
For additional commands, e-mail: java-dev-h...@lucene.apache.org