zopefoundation / transaction

Generic transaction implementation for Python.
Other
70 stars 31 forks source link

Changed the implementation of ThreadTransactionManager #68

Closed jimfulton closed 6 years ago

jimfulton commented 6 years ago

Changed the implementation of ThreadTransactionManager to be a thread.local that wraps a TransactionManager rather than a thread.local that inherits from TransactionManager. It now exposes a manager attribute that allows access to the wrapped transaction manager to allow cross thread calls. ZODB will use this to call unregisterSynch when a connection is closed from a main thread.

This is needed to fix the issue https://github.com/zopefoundation/ZODB/issues/208

jimfulton commented 6 years ago

I'll add interface tests.

Thanks for the review!

jimfulton commented 6 years ago

Added interface verification tests for managers

icemac commented 6 years ago

@jimfulton Is this PR ready to merge? I'd like to include the fix for zopefoundation/ZODB#208 into the next Zope release. (Is there anything else to be done to fix that issue?) The Plone developers want the Zope 4b7 release before the conference in Tokyo to be able to make a Plone alpha release based on Python 3.

jimfulton commented 6 years ago

Sorry, I'm just terribly time challenged. It would be great if someone else had time to make a release.

jamadden commented 6 years ago

2.4.0 has been pushed to PyPI.

jimfulton commented 6 years ago

Thanks! And thanks for the release note!