You are viewing a plain text version of this content. The canonical link for it is here.
Posted to java-user@lucene.apache.org by ik...@axsone.com on 2013/07/30 23:04:09 UTC

deleting documents

Hello,
In Lucene 4.x is there a way to get the number of documents that were deleted from calling IndexWriter. deleteDocuments(Query)?

Another question, if we call IndexWriter. tryDeleteDocument(Reader, docId) utilizing a near-real-time reader, what is the appropriate order to close the reader and writer. Also, if I decide to rollback the deleted documents I assume I call IndexWriter.rollback() to close the writer without committing the changes, but where in the rollback process do I close the reader (before or after I call IndexWriter.rollback())?

Thanks,
Ian Koelliker