[ZODB-Dev] Re: [Zope-DB] ZODB performance numbers

Christian Robottom Reis kiko at async.com.br
Tue Aug 24 20:07:52 EDT 2004


On Tue, Aug 24, 2004 at 09:57:13AM +0100, Chris Withers wrote:
> >>I've just stared experimenting with ZODB and ZEO and I've written a 
> >>test program that makes an object and adds it to a persistent list.  I 
> >>create an object with 3 parameters, add it to the PersistentList, and 
> >>commit my transaction.  If I run this in a loop of 10 or 100 objects, 
> >>it can only perform about 2 objects saves/transactions per second.  I 
> >>know that ZODB is supposed to be better for reads than for writes, but 
> >>only two writes per second seems very slow.  I'm using the file 
> >>storage for zodb, and connecting with zeo and ClientStorage.

The PersistentList is persisted as a single pickle. If the object you
are creating doesn't inherit from Persistent, it will be stored in that
same pickle; otherwise, it is stored separately. This causes the amount
of data that needs to be saved every time a PL is saved grow
proportionally to its size.

I imagine you might be seeing commits go slower as the amount of objects
it's storing grows. The general idiom is that PL isn't a scalable way to
store your objects -- you're much better off with one of the data
structures defined in the BTrees package.

Take care,
--
Christian Robottom Reis | http://async.com.br/~kiko/ | [+55 16] 3361 2331


More information about the ZODB-Dev mailing list