lucene-java-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Mindaugas Žakšauskas" <min...@gmail.com>
Subject Runtime exception when creating IndexSearcher
Date Wed, 29 Oct 2008 12:42:53 GMT
Hi,

We're using Lucene 2.4.0 on Linux. Java version is 1.6.0_06.

Is there any reason why Lucene would be throwing this error:

org.apache.lucene.store.AlreadyClosedException: this Directory is closed
	at org.apache.lucene.store.Directory.ensureOpen(Directory.java:220)
	at org.apache.lucene.store.FSDirectory.fileExists(FSDirectory.java:326)
	at org.apache.lucene.index.SegmentInfos$FindSegmentsFile.run(SegmentInfos.java:680)
	at org.apache.lucene.index.DirectoryIndexReader.open(DirectoryIndexReader.java:111)
	at org.apache.lucene.index.IndexReader.open(IndexReader.java:316)
	at org.apache.lucene.index.IndexReader.open(IndexReader.java:206)
	at org.apache.lucene.search.IndexSearcher.<init>(IndexSearcher.java:47)
        <..our own code which calls new IndexSearcher( String ) ..>

If the index would be corrupted I'd expect
org.apache.lucene.index.CorruptIndexException; similar for
java.io.IOException, however this is something different.
Obviously, AlreadyClosedException is a runtime exception and doesn't
have to be declared in constructor javadoc, however, the problem is a
bit scary as it leaves me in a position with no choice.
Thanks is advance.

Regards,
Mindaugas

---------------------------------------------------------------------
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