[ZODB-Dev] Re: ZODB Benchmarks

Roché Compaan roche at upfrontsystems.co.za
Wed Mar 5 07:12:48 EST 2008


On Tue, 2008-03-04 at 23:00 +0100, Bernd Dorn wrote:
> On 04.03.2008, at 22:16, Shane Hathaway wrote:
> 
> > Lennart Regebro wrote:
> >> On Tue, Mar 4, 2008 at 9:27 PM, Shane Hathaway  
> >> <shane at hathawaymix.org> wrote:
> >>> - Did you use optimal methods of retrieval in Postgres?  It is
> >>> frequently not necessary to pull the data into the application.   
> >>> Copying
> >>> to another table could be faster than fetching rows.
> >> But is that relevant in this case? Retrieval must reasonably really
> >> retrieve the data, not just move it around. :)
> >
> > Not if you're only retrieving intermediate information.  When you  
> > write an application against a relational database, a lot of the  
> > intermediate information does not need to be exposed to Python,  
> > helping performance significantly.
> 
> yes this is the major benefit when using a relational database over  
> zodb, because zodb has no server side query language,

This certainly makes some queries faster in an RDBMS. My first goal was
to determine the speed of the most basic operation like insert and
lookup.

>  so the whole  
> lookup insert comparison does not reflect real world issues.

I disagree. It certainly tests some real world use cases. Most notably
the use case where you have a very large user base inserting content at
a very high rate into the ZODB. I think what is unknown at this stage is
what the penalty would be when using ZEO. But you can only know this if
you know how fast direct interaction with the ZODB is. Not all
applications require ZEO either.

> for example in one of our applications we have to calculate neighbours  
> of users, based on books they have in their bookshelfs. with about  
> 10000 users and each of them having an average of 100-500 books out of  
> ca. 1 million, the calculation of the neighbours takes seconds when  
> you have to calculate this on the client, by getting all indexes etc.  
> we switched to sql and wrote a single sql statement that does exactly  
> the same comparison which now takes about 300ms.
> 
> your comparisons would only be accurate if comparing relstorage with  
> filestorage over zeo, because in this case there is no server side  
> query possible on object attributes . it would be interesting to look  
> at performance when having 4-10 zodb clients and then compare zeo/ 
> filestorage against relstorage with postgres.

Hopefully the tests are accurate in comparing the speed for basic
operations like insertion and lookup. They might be more *relevant* if
one performs the same tests using ZEO.

-- 
Roché Compaan
Upfront Systems                   http://www.upfrontsystems.co.za



More information about the ZODB-Dev mailing list