[Xapian-devel] Something to think about

James Aylett james-xapian at tartarus.org
Sun Oct 14 14:22:41 BST 2007


On Sun, Oct 14, 2007 at 02:15:59PM +0100, Olly Betts wrote:

> > If the db is opened each time, the document ids aren't guaranteed to
> > be consistent anyway, so does that case actually matter?
> 
> I'm not sure I follow.  For a single database or fixed collection of
> databases, the docids of existing documents won't change between
> searches, unless you mean that some documents may have been deleted.

But with any method for interleaving or sequentially assigning docids
out of multiple dbs, they won't change unless one or more of those dbs
is changed between searches. So I still think it's an edge case. I
think there's something I'm missing here...

> Obviously that doesn't apply if you reindex from scratch, or if the
> initial document has been deleted and you run xapian-compact without
> --no-renumber, but in the common case of databases being updated, the
> docids are stable with the interleaving scheme.
> 
> And for things like marking documents for relevance feedback, stability
> of docids between searches is pretty much essential, which is why
> we originally chose the interleaving scheme.

Umm, okay. So we need to think about how to assign the gap to retain
that for a little longer. That's harder, but could be a hint on
multi-db open or something. Not ideal, though :-(

J

-- 
/--------------------------------------------------------------------------\
  James Aylett                                                  xapian.org
  james at tartarus.org                               uncertaintydivision.org



More information about the Xapian-devel mailing list