[Zope-dev] KeywordIndex performance / multiunion

Seb Bacon seb at jamkit.com
Thu Nov 6 14:11:55 EST 2003


A simple query for ["A" or "B" or "C"] against a KeywordIndex containing 
27k objects is taking about 7 seconds on a Celeron 1.6Ghz, which seems 
an absurdly long time to me.

The bit of the operation that is taking the time is the part of the 
index which does a union of the results of each of the 3 query 
parameters.  Reproducing this BTree union operation outside Zope in a 
unit test takes milliseconds.  Very occasionally it takes milliseconds 
inside the KeywordIndex too.  Something to do with memory usage perhaps? 
  I'll continue looking into it.

But main the reason I'm posting is to wonder if there any reason not to 
use the multiunion operator instead of the union operator in 
UnIndex.py... it should be faster, right?  It seems a touch faster in 
some informal tests.


Seb




More information about the Zope-Dev mailing list