Michael, https://issues.apache.org/jira/browse/LUCENE-1429
Thanks mate. I'll try and work out the client handling policy of the IndexWriter calls. I see that flush now aborts the transaction as well...
cheers, jed. Michael McCandless wrote:
Woops, you're right: this is a bug. I'll open an issue, fold in your nice test case & fix it. Thanks Jed! On hitting OOM, IndexWriter marks that its internal state (buffered documents, deletions) may be corrupt and so it rollsback to the last commit instead of flushing a new segment. To workaround this, on catching an OOME on any of IndexWriter's methods, you should 1) forcibly remove the write lock (IndexWriter.unlock static method) and then 2) not call any methods on the old writer. Even if the old writer has concurrent merges running, they will refuse to commit on seeing that an OOM had occurred. Mike
--------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]