lucene-java-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Reg <>
Subject TrackingIndexWriter.tryDeleteDocument(IndexReader, int) vs deleteDocuments(Query)
Date Tue, 07 May 2013 01:05:59 GMT
Hi all,

It seems tryDeleteDocument(IndexReader, int) doesn't work with NRTManager
while deleteDocuments(Query) works.

Here are some sample code snippets:

TrackingIndexWriter mgrWriter = new NRTManager.TrackingIndexWriter(writer);

ReferenceManager<IndexSearcher> mgr = new NRTManager(mgrWriter, new
SearcherFactory(), true);

mgrWriter.tryDeleteDocument(, true), 0);


IndexSearcher searcher = mgr.acquire();, collector);

The deleted doc with id 0 is still returned in collector, but I don't see
such issues if I change to mgrWriter.deleteDocuments(Query).

Any ideas?

  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message