Christian Heimes wrote:
Tim Peters wrote:
Nesting savepoints works according to your test and I really believe you
that they work in real live. Honestly! :)
But there is some evil code in transaction/ that is destroying
savepoints for my use case. Committing a subtransaction using the old
and deprecated transaction.commit(1) syntax is invalidating all
savepoints. The invalidation would be harmless but the zcatalog has a
nasty feature. It is committing a subtransaction + GC cleanup after
cataloging n object in a transaction. IIRC n=10,000 by default which
might be reached much earlier than one can imagine.
subtransactions != savepoints
There is *no* promise of nestability with subtransactions.
Committing a subtransaction invalidates prior savepoints by
design. This is necessary to maintain backward compatibility.
If you don't like this behavior, don't
use subtransactions. A good community project would be
to convert all of the subtransaction calls in Zope to
Jim Fulton mailto:[EMAIL PROTECTED] Python Powered!
CTO (540) 361-1714 http://www.python.org
Zope Corporation http://www.zope.com http://www.zope.org
For more information about ZODB, see the ZODB Wiki:
ZODB-Dev mailing list - ZODB-Dev@zope.org