Avoid race condition in deploy to unpause #1088

Merged
merged 3 commits into from Jun 21, 2016

Conversation

Projects
None yet
1 participant
@ssalinas
Member

ssalinas commented Jun 14, 2016

If the request status is not updated to DEPLOY_TO_UNPAUSE before the deploy is saved. It is possible that the deploy checker can run the first check of the deploy while the request is still in the paused state. This code path also left the deploy in a waiting state with no message.

Changes here move the request state update before the deploy save, and will also be sure to complete the deploy with a failure when hitting the code path where request state is not valid to proceed with the deploy

@ssalinas

This comment has been minimized.

Show comment
Hide comment
@ssalinas

ssalinas Jun 21, 2016

Member

This one is gtg, going to merge

Member

ssalinas commented Jun 21, 2016

This one is gtg, going to merge

@ssalinas ssalinas merged commit b13ea17 into master Jun 21, 2016

1 of 2 checks passed

continuous-integration/travis-ci/pr The Travis CI build could not complete due to an error
Details
continuous-integration/travis-ci/push The Travis CI build passed
Details

@ssalinas ssalinas deleted the deploy_to_unpause branch Jun 21, 2016

@ssalinas ssalinas added this to the 0.9.0 milestone Jul 29, 2016

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment