lucene-java-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Michael McCandless <luc...@mikemccandless.com>
Subject Re: IOException: Access is denied from IndexWriter.Optimize
Date Tue, 05 Dec 2006 10:38:53 GMT
trond.lindanger@dkdigital.no wrote:
> Forgot something...
> Also I got this exception, which may be related:
> 
> java.io.IOException: Cannot delete C:\dknewscenter\2\_5d.cfs
>         at 
> org.apache.lucene.store.FSDirectory.create(FSDirectory.java:319)
>         at 
> org.apache.lucene.store.FSDirectory.getDirectory(FSDirectory.java:208)
>         at 
> org.apache.lucene.store.FSDirectory.getDirectory(FSDirectory.java:131)
>         at 
> org.apache.lucene.index.IndexWriter.<init>(IndexWriter.java:200)
>         at 
> de.nava.informa.search.ChannelIndexer.indexItems(ChannelIndexer.java:126)
>         at 
> de.nava.informa.search.ChannelIndexer.indexChannels(ChannelIndexer.java:94)
> 
> This exception is given repeatedly, while the last exception is given 
> once.

This particular exception looks like your are sending "create=true"
when instantiating your IndexWriter, while a reader is still using the
index.  Plus you are on Windows.  Does that sound right?

If so, this case is not well handled by the current releases of
Lucene.

On the trunk (and in the next release) it is correctly handled in that
if the delete fails, Lucene will just try again later (just like other
places where Lucene deletes files, eg segments that were merged).

Mike


---------------------------------------------------------------------
To unsubscribe, e-mail: java-user-unsubscribe@lucene.apache.org
For additional commands, e-mail: java-user-help@lucene.apache.org


Mime
View raw message