/usr/share/pyshared/ZODB/subtransactions.txt is in python-zodb 1:3.9.7-2.
This file is owned by root:root, with mode 0o644.
The actual contents of the file can be viewed below.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 | =========================
Subtransactions in ZODB 3
=========================
ZODB 3 provides limited support for subtransactions. Subtransactions
are nested to *one* level. There are top-level transactions and
subtransactions. When a transaction is committed, a flag is passed
indicating whether it is a subtransaction or a top-level transaction.
Consider the following exampler commit calls:
- ``commit()``
A regular top-level transaction is committed.
- ``commit(1)``
A subtransaction is committed. There is now one subtransaction of
the current top-level transaction.
- ``commit(1)``
A subtransaction is committed. There are now two subtransactions of
the current top-level transaction.
- ``abort(1)``
A subtransaction is aborted. There are still two subtransactions of
the current top-level transaction; work done since the last
``commit(1)`` call is discarded.
- ``commit()``
We now commit a top-level transaction. The work done in the previous
two subtransactions *plus* work done since the last ``abort(1)`` call
is saved.
- ``commit(1)``
A subtransaction is committed. There is now one subtransaction of
the current top-level transaction.
- ``commit(1)``
A subtransaction is committed. There are now two subtransactions of
the current top-level transaction.
- ``abort()``
We now abort a top-level transaction. We discard the work done in
the previous two subtransactions *plus* work done since the last
``commit(1)`` call.
|