[Xapian-discuss] Deleted documents not deleted

Jean-Francois Dockes jean-francois.dockes at wanadoo.fr
Thu Jun 21 06:56:11 BST 2007


Olly Betts writes:
 > On Wed, Jun 20, 2007 at 11:18:20PM +0200, Jean-Francois Dockes wrote:
 > > Yes, the problem seems to be gone. Any idea why I was apparently the only
 > > one to trigger it ? 
 > 
 > I suspect most people don't delete non-existent documents very often.

I suppose that documents move or go away more frequently in a desktop than
in a www context. 

The purge code in recoll was lifted from omega, so the problem was probably
visible there too (except if I'm missing some difference).

When walking the 'updated' array, you're bound to trigger DocNotFound
errors, if any docs were deleted during previous indexing passes.

 > The problem was that any exception in delete_document() was causing
 > pending changes to be discarded.  That's a reasonable plan for
 > unexpected exceptions, as the unflushed state is likely to be
 > inconsistent after an unexpected exception.  But DocNotFoundError is
 > expected in the case of a document which doesn't exist.

Might this have also caused document additions to be lost if a flush() was
not performed before the purge pass ? I had had the 'feeling' at some point
that this sometimes happened ...

jf




More information about the Xapian-discuss mailing list