[Zope-dev] newTransaction not called in transaction.get
Tres Seaver
tseaver at palladion.com
Mon Sep 22 09:22:54 EDT 2008
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1
Jürgen kartnaller wrote:
> I just run into a with transaction manager and synchronizers.
>
> If transaction.get implicitily creates a new transaction the synchronizers
> are not called. This is not problem as long as no savepoints are used. If
> savepoints are used the DataManagers created by synchronizers are not
> present. Because savepoints are requested from the DataManagers it doesn't
> work.
Can you elaborate on how your patch interacts with this comment (in
transaction._manager)?
# Call the ISynchronizer newTransaction() method on every element of
# WeakSet synchs.
# A transaction manager needs to do this whenever begin() is called.
# Since it would be good if tm.get() returned the new transaction while
# newTransaction() is running, calling this has to be delayed until
# after
# the transaction manager has done whatever it needs to do to make its
# get() return the new txn.
In other words, is there any cases there TM.get() will be called when it
is "too early" to call '_new_transaction'?
> I already created a branch with a fix (transaction/branches/synchfix).
>
> If one with more knowledge about the transaction manager can approve my
> change I will add tests and merge the change into trunk.
It would help to see the tests with the rest of the patch: they often
help illustrate the motivation.
Tres.
- --
===================================================================
Tres Seaver +1 540-429-0999 tseaver at palladion.com
Palladion Software "Excellence by Design" http://palladion.com
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.6 (GNU/Linux)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org
iD8DBQFI15wu+gerLs4ltQ4RAiA8AJ9hLInfO/5c5633rgqY784YdBjsTgCgoMjM
gAA7c5VH4jhy+wTVt+uXztk=
=rMB8
-----END PGP SIGNATURE-----
More information about the Zope-Dev
mailing list