[Zope] For the record

Peter Bengtsson peter at fry-it.com
Tue Mar 18 13:38:32 EDT 2008

I wanted to see how much faster brain.getObject() would be if the
returned object was located in a BTreeFolder versus a normal folder so
I wrote a benchmark that created about 10,000 light simple objects in
two distinctly different containers and each with a ZCatalog that has
a PathIndex.

I would expect the BTreeFolder parenting calls of brain.getObject() to
be much faster but I found that there was NO DIFFERENCE. wtf?!

The benchmark is too messy to share right now but how come this could
have happened? getObject() basically does a
parent.restrictedTraverse(path_splitted[-1]) which should be some sort
of getattr() on the container right?

Is there something obvious I've missed?

Peter Bengtsson,
work www.fry-it.com
home www.peterbe.com
hobby www.issuetrackerproduct.com

More information about the Zope mailing list