-
-
Notifications
You must be signed in to change notification settings - Fork 782
Make update_execution() atomic #5358
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Merged
cognifloyd
merged 16 commits into
StackStorm:master
from
khushboobhatia01:bkhushboo/race_condition
Oct 5, 2021
Merged
Changes from all commits
Commits
Show all changes
16 commits
Select commit
Hold shift + click to select a range
14cf46c
Make update_execution() atomic
khushboobhatia01 20045dc
Black reformat
khushboobhatia01 5fa3ecd
Merge branch 'master' into bkhushboo/race_condition
arm4b a33c319
Fix chunk 2 test cases
khushboobhatia01 4250e23
Merge branch 'bkhushboo/race_condition' of github.com:khushboobhatia0…
khushboobhatia01 7c42aad
Fix chunk 2 unit test cases
khushboobhatia01 1d12cfe
Retrigger CI
khushboobhatia01 67cc829
Retrigger CI
khushboobhatia01 ba3ad95
Merge branch 'master' into bkhushboo/race_condition
khushboobhatia01 d6a999c
Retrigger CI
khushboobhatia01 3ce5819
Retrigger CI
khushboobhatia01 4eb19d5
Fix test case
khushboobhatia01 44f691e
Reformat
khushboobhatia01 7b365f1
Merge branch 'master' into bkhushboo/race_condition
khushboobhatia01 2944aed
Merge branch 'master' into bkhushboo/race_condition
cognifloyd ec52b89
add changelog entry
cognifloyd File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Could we add a prefix to this to scope the change just to this block? Or are there other places already using this the live action id as the lock name that you also want to block?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@cognifloyd No, get_lock() is not being used anywhere else.
And to answer why tests are failing, https://github.com/StackStorm/st2/blob/master/st2actions/tests/unit/test_workflow_engine.py#L155-L159 mocks get_lock() to return
ToozConnectionError(to testst2/st2common/st2common/services/workflows.py
Line 941 in 007beed
Because of the above mocking, action execution update calls will fail with my changes and cause the test assertions to fail. I'm working on the fix for this.