[Zope-dev] ZPatterns Design Issue

Roch'e Compaan roche@upfrontsystems.co.za
Tue, 24 Apr 2001 15:01:57 +0200


Hi Everybody

We are porting a desktop application to Zope using Interbase and ZPattern=
s.
In this application objects like Vintage, Farm, Vineyard, Block and Panel
form a hierarchy and are displayed with the Zope tree widget.  To build t=
he
hierarchy we use a method called getChildrenFor() on each level to retrie=
ve
the children for the object at hand.  Behind getChildrenFor() lies a ZSQL
Method on their respective racks to retrieve the result set.

Building the tree leads to a whole bunch of queries to the database that
really slows thing down ie. besides the queries that retrieve children,
select queries to retrieve individual instances is called by getItem thro=
ugh
SkinScript for each item in the tree.

I haven't been able to figure out a way to get some performance back with=
out
talking to the database directly through ZSQL Methods but this defies the
whole point of using ZPatterns.

Some guidance/pointers would really be appreciated.

Roch=E9