On Sun, Oct 29, 2006 at 03:19:28PM -0300, Fernando Nemec
wrote:> another question about Xapian. Does anyone know how the search time's
> behavior as I increase the number of documents indexed? For instance,
> is it correct to say if Xapian takes x seconds to search n documents,
> then it takes about 2*x to search 2*n documents on the same machine?
The relationship isn't a simple one, because the matcher uses various
tricks to terminate early when it knows it won't find any better
results. So the time taken depends on the queries and the nature of the
corpus of documents being searched.
Eventually I/O will dominate search time if you continue increasing the
number of documents while keeping the RAM size fixed, but you only need
a few percent of the database blocks cached to keep things working well
so you need a very large database with a typical modern server.
Cheers,
Olly