Chris Withers wrote at 2004-8-16 13:42 +0200:
Dieter Maurer wrote:
I never felt that the current way is wrong in any way.
You may get a few extra connections but unless you litter your site with redundant DA instances, that should not make a big problem.
They're not redundant if you have a policy that means different departments use different subtrees of aZODB,
Maybe, they should comminicate how to use resources in their common Zope efficiently...
and they each connect to different databases on different database servers.
You cannot pool connections when they go to different databases or servers.
Zope's current method is a cheap attempt at connection pooling without doing real connection pooling,
It is reusing the existing ZODB connection pool. Reusing rather than reinventing is not so bad ;-)
and one that uses _v_ variables in a very dodgy fashion...
The only problem with "_v_" variables is that they can disappear at subtransaction boundaries. A long time ago, I posted a "_p_sticky" patch to "zodb-dev" that allows this to control. Unfortunately, the patch did not yet go into the ZODB core (and I fear, it will not happen at all). -- Dieter