Commit d7d2e914 authored by Jim Fulton's avatar Jim Fulton

Document why newTransaction is only called by begin.

parent 37459212
...@@ -22,12 +22,19 @@ class ITransactionManager(Interface): ...@@ -22,12 +22,19 @@ class ITransactionManager(Interface):
""" """
def begin(): def begin():
"""Begin a new transaction. """Explicitly begin a new transaction.
If an existing transaction is in progress, it will be aborted. If an existing transaction is in progress, it will be aborted.
The newTransaction() method of registered synchronizers is called, The ``newTransaction`` method of registered synchronizers is called,
passing the new transaction object. passing the new transaction object.
Note that transactions may be started implicitly without
calling ``begin``. In that case, ``newTransaction`` isn't
called because the transaction manager doesn't know when to
call it. The transaction is likely to have begin long before
the transaction manager is involved. (Conceivably 'commit' and
'abort' could call 'begin', but they don't.)
""" """
def get(): def get():
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment