[v17.06] Cherry-pick "Adding new Task Status REMOVE"#2463
Merged
anshulpundir merged 1 commit intoDec 1, 2017
Conversation
Set task desired state to REMOVE for service removal and scale down. Tasks in REMOVE state can be deleted after they are reported SHUTDOWN. Avoids a race conditions where network resources are freed before the running task has shut down fully. Add unit tests for Task state REMOVE behavior. Started by Nishant Totla <nishanttotla@gmail>, finished by Drew Erny <drew.erny@docker.com>. Signed-off-by: Nishant Totla <nishanttotla@gmail.com> Signed-off-by: Drew Erny <drew.erny@docker.com> Backports moby#2461 to 17.06. Cherry pick did not apply cleanly (cherry picked from commit b9e2c2f) Signed-off-by: Drew Erny <drew.erny@docker.com>
Collaborator
Author
|
lol whoops title. |
anshulpundir
approved these changes
Nov 29, 2017
| // shutting them down. Once the agent has shut down tasks with desired state | ||
| // REMOVE, the task reaper is responsible for removing them. | ||
| TaskStateRemove TaskState = 800 | ||
| // TaskStateOrphaned is used to free up resources associated with service |
Contributor
There was a problem hiding this comment.
Did you mean to pick these changes too ? They were part of a different comment.
| // shutting them down. Once the agent has shut down tasks with desired state | ||
| // REMOVE, the task reaper is responsible for removing them. | ||
| REMOVE = 800 [(gogoproto.enumvalue_customname)="TaskStateRemove"]; | ||
| // TaskStateOrphaned is used to free up resources associated with service |
Contributor
There was a problem hiding this comment.
Did you mean to pick these changes too ? They were part of a different comment.
Collaborator
Author
There was a problem hiding this comment.
Were they? I think this was just a reword of the comment for orphaned that i did
There was a problem hiding this comment.
@anshulpundir those were reworded in b9e2c2f
|
LGTM assuming tests pass. |
Codecov Report
@@ Coverage Diff @@
## bump_v17.06 #2463 +/- ##
===============================================
+ Coverage 59.83% 61.09% +1.26%
===============================================
Files 120 120
Lines 25131 23825 -1306
===============================================
- Hits 15037 14557 -480
+ Misses 8754 7937 -817
+ Partials 1340 1331 -9 |
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
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
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.
Set task desired state to REMOVE for service removal and scale down. Tasks in
REMOVE state can be deleted after they are reported SHUTDOWN. Avoids a race
conditions where network resources are freed before the running task has
shut down fully.
Add unit tests for Task state REMOVE behavior.
Started by Nishant Totla nishanttotla@gmail, finished by Drew Erny
drew.erny@docker.com.
Signed-off-by: Nishant Totla nishanttotla@gmail.com
Signed-off-by: Drew Erny drew.erny@docker.com
Backports #2461 to 17.06. Cherry pick did not apply cleanly
(cherry picked from commit b9e2c2f)
Signed-off-by: Drew Erny drew.erny@docker.com