Skip to content
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

Do not remove from LB if not yet added #1171

Merged
merged 1 commit into from Aug 5, 2016
Merged

Do not remove from LB if not yet added #1171

merged 1 commit into from Aug 5, 2016

Conversation

@ssalinas
Copy link
Member

ssalinas commented Jul 25, 2016

In this order of events, we were submitting a LB ADD request after the REMOVE request, with the result that the presence of the REMOVE caused us to never properly remove the task from the LB:

  • deploy 1 running
  • deploy 2 starts
  • replacement task for deploy 1 enters TASK_RUNNING
  • deploy 2 tasks are healthy and LB ADD/REMOVE is triggered (but contains the replacement task above)
  • replacement task from deploy 1 becomes healthy and LB ADD is sent

This fixes the deploy logic to only issue the REMOVE as part of the deploy if the ADD is already present and successful. If the ADD completes after/during the deploy lb actions, the task will still be properly removed from the LB during cleanup since the LB REMOVE will not be present.

@ssalinas
Copy link
Member Author

ssalinas commented Aug 5, 2016

This tested well in each of our environments, merging the fix

@ssalinas ssalinas merged commit 2a35f51 into master Aug 5, 2016
2 checks passed
2 checks passed
continuous-integration/travis-ci/pr The Travis CI build passed
Details
continuous-integration/travis-ci/push The Travis CI build passed
Details
@ssalinas ssalinas deleted the lb_removal branch Aug 5, 2016
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Linked issues

Successfully merging this pull request may close these issues.

None yet

1 participant
You can’t perform that action at this time.