[Zope] SQLSession and Performance issues

Timothy Grant tjg@avalongroup.net
Thu, 02 Mar 2000 14:57:00 -0800


Hung Jung Lu wrote:

> I don't have an answer... maybe you could describe first
> what database you are using (Gadfly on the same machine?
> remote database?), do you do many retrievals and updates?

PostgreSQL running on the same box as ZServer.
 
> In the code SQLSession.py, there is a 'caching' variable.
> SQLSession seems to cache variables that are already
> retrieved or are recently updated. Try to set 'caching'
> to 1 and see if that helps.

Thanks for this input. I will go and take a look at it. I did not know
it was there.
 
> As Pavlos Christoforou said, another strategy is to
> have a single session data variable (a dictionary,
> for instance), and then retrieve it, say, in your
> standard_html_header and store it in your standard_html_footer
> (or their equivalents.) This way you only need to access
> the database twice per request.

Now this in an interesting idea, but all my attempts to computationally
build a dictionary within Zope have gone to naught. I would love any
advice on this as I believe it could very well be the key to this
problem.


-- 
Stand Fast,
    tjg.

Chief Technology Officer              tjg@exceptionalminds.com
Red Hat Certified Engineer            www.exceptionalminds.com
Avalon Technology Group, Inc.                   (503) 246-3630
>>>>>>>>>>>>Linux...Because rebooting isn't normal<<<<<<<<<<<<