[ZODB-Dev] [ZODB3.1] easily reproducible deadlock

Shane Hathaway shane at zope.com
Mon Dec 8 09:34:05 EST 2003


On Mon, 8 Dec 2003, Christian Robottom Reis wrote:

> This is a tough problem. The nice thing about most SQL databases is that
> when using a language binding you can just conjure a database connection
> out of thin air with an address and a username. This is not so with the
> ZEO.

This is because transactions are local to the SQL connections.  SQL
connections are transactionally independent.  ZEO tries to be smarter than
that, binding transactions to the thread instead of the database
connection.  If you just made ZEO dumber by eliminating the
get_transaction() global function, the deadlock issue would go away.  Or,
more precisely, the responsibility for maintaining integrity across
databases and connections would shift to application programmers.  I 
wonder which is the better policy.

Shane



More information about the ZODB-Dev mailing list