Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Z
ZODB
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
Nicolas Wavrant
ZODB
Commits
891519cf
Commit
891519cf
authored
Apr 26, 2005
by
Tim Peters
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Merged rev 30192 from 3.4 branch.
Trimmed trailing whitespace.
parent
8fdd6fdb
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
11 additions
and
11 deletions
+11
-11
src/transaction/_transaction.py
src/transaction/_transaction.py
+11
-11
No files found.
src/transaction/_transaction.py
View file @
891519cf
...
...
@@ -268,7 +268,7 @@ class Transaction(object):
except
:
self
.
_cleanup
(
self
.
_resources
)
self
.
_saveCommitishError
()
# reraises!
if
self
.
_last_savepoint
is
not
None
:
savepoint
.
previous
=
self
.
_last_savepoint
self
.
_last_savepoint
.
next
=
savepoint
...
...
@@ -326,7 +326,7 @@ class Transaction(object):
# TODO depricate subtransactions
self
.
savepoint
(
1
)
return
if
self
.
status
is
Status
.
COMMITFAILED
:
self
.
_prior_operation_failed
()
# doesn't return
...
...
@@ -437,7 +437,7 @@ class Transaction(object):
return
self
.
_invalidate_last_savepoint
()
self
.
_synchronizers
.
map
(
lambda
s
:
s
.
beforeCompletion
(
self
))
tb
=
None
...
...
@@ -452,7 +452,7 @@ class Transaction(object):
if
self
.
_manager
:
self
.
_manager
.
free
(
self
)
self
.
_synchronizers
.
map
(
lambda
s
:
s
.
afterCompletion
(
self
))
self
.
log
.
debug
(
"abort"
)
...
...
@@ -576,7 +576,7 @@ class DataManagerAdapter(object):
# We don't do anything here because ZODB4-style data managers
# didn't have a separate tpc_begin step
pass
def
tpc_abort
(
self
,
transaction
):
self
.
_datamanager
.
abort
(
transaction
)
...
...
@@ -594,7 +594,7 @@ class Savepoint:
Transaction savepoints coordinate savepoints for data managers
participating in a transaction.
"""
interface
.
implements
(
interfaces
.
ISavepoint
)
...
...
@@ -614,17 +614,17 @@ class Savepoint:
savepoint
=
NoRollbackSavepoint
(
datamanager
)
else
:
savepoint
=
savepoint
()
savepoints
.
append
(
savepoint
)
def
join
(
self
,
datamanager
):
# A data manager has joined a transaction *after* a savepoint
# was created. A couple of things are different in this case:
# 1. We need to add it's savepoint to all previous savepoints.
# so that if they are rolled back, we roll this was back too.
# 2. We don't actualy need to ask it for a savepoint. Because
# is just joining, then we can abort it if there is an error,
# so we use an AbortSavepoint.
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment