Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Rawlink a callback on transaction completion#224

Closed
harlowja wants to merge 4 commits into
python-zk:masterfrom
harlowja:fix-transaction-complete
Closed

Rawlink a callback on transaction completion#224
harlowja wants to merge 4 commits into
python-zk:masterfrom
harlowja:fix-transaction-complete

Conversation

@harlowja
Copy link
Copy Markdown
Contributor

Instead of assuming that a transaction will
correctly complete before it actually does we
should be smarter about this and inspect the
result to determine if it actually did and only
if it did should we set the committed flag.

Fixes issue #222

harlowja added 4 commits July 19, 2014 16:32
Instead of assuming that a transaction will
correctly complete before it actually does we
should be smarter about this and inspect the
result to determine if it actually did and only
if it did should we set the committed flag.

Fixes issue 222
openstack-gerrit pushed a commit to openstack/taskflow that referenced this pull request Aug 30, 2014
To ensure we reliably handle when a transaction fails
we should use the checked_commit() helper function instead
of the currently not fully exception handling kazoo
transaction commit function.

This should be addressed in the future with:

- python-zk/kazoo#224
- python-zk/kazoo#225

Those have not merged yet (or been released) so we need
to use a similar function in the meantime.

Change-Id: Icf83b7d4955c11227e733287170a7bd3ab372bd2
openstack-gerrit pushed a commit to openstack/openstack that referenced this pull request Aug 30, 2014
Project: openstack/taskflow  70d9199ea374b558a9918089de94af0b6c76811b

Use checked_commit() around consume() and abandon()

To ensure we reliably handle when a transaction fails
we should use the checked_commit() helper function instead
of the currently not fully exception handling kazoo
transaction commit function.

This should be addressed in the future with:

- python-zk/kazoo#224
- python-zk/kazoo#225

Those have not merged yet (or been released) so we need
to use a similar function in the meantime.

Change-Id: Icf83b7d4955c11227e733287170a7bd3ab372bd2
@damz
Copy link
Copy Markdown

damz commented Sep 2, 2014

👍 on the principle. This fixes a related issue that Transaction.commit cannot be retried using the classic pattern:

client.retry(transaction.commit)

@bbangert
Copy link
Copy Markdown
Member

Please re-open to rebase and update as needed.

@bbangert bbangert closed this May 31, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants