Skip to content

[v17.06.5] Cherry-pick "Fix task reaper not cleaning up COMPLETE tasks"#2475

Merged
stevvooe merged 1 commit into
moby:bump_v17.06.5from
dperny:bump_v17.06.5-cherry-pick-2473
Dec 19, 2017
Merged

[v17.06.5] Cherry-pick "Fix task reaper not cleaning up COMPLETE tasks"#2475
stevvooe merged 1 commit into
moby:bump_v17.06.5from
dperny:bump_v17.06.5-cherry-pick-2473

Conversation

@dperny
Copy link
Copy Markdown
Collaborator

@dperny dperny commented Dec 18, 2017

Tasks in the complete state were not cleaned up because the task reaper
was only looking at task.Status.State >= api.TaskStateShutdown, but the
COMPLETE state (api.TaskStateCompleted) is the actual "first" terminal
state.

Added a test for the initialization stage of the task repear. This runs
the logic of which tasks to clean up through its paces, but doesn't test
the run-time logic of the task reaper (it's ability to respond to
updates to tasks).

Cherry-pick of #2473

Cherry pick does not apply cleanly. In addition, cherry pick requires
changes to manager/orchestrator/taskreaper/task_reaper_test.go,
because of a difference in the API of the task reaper.

(cherry picked from commit e5b3107)
Signed-off-by: Drew Erny drew.erny@docker.com

Tasks in the complete state were not cleaned up because the task reaper
was only looking at task.Status.State >= api.TaskStateShutdown, but the
COMPLETE state (api.TaskStateCompleted) is the actual "first" terminal
state.

Added a test for the initialization stage of the task repear. This runs
the logic of which tasks to clean up through its paces, but doesn't test
the run-time logic of the task reaper (it's ability to respond to
updates to tasks).

Cherry-pick of moby#2473

Cherry pick does not apply cleanly. In addition, cherry pick requires
changes to `manager/orchestrator/taskreaper/task_reaper_test.go`,
because of a difference in the API of the task reaper.

(cherry picked from commit e5b3107)
Signed-off-by: Drew Erny <drew.erny@docker.com>
@stevvooe
Copy link
Copy Markdown
Contributor

LGTM

@codecov
Copy link
Copy Markdown

codecov Bot commented Dec 18, 2017

Codecov Report

Merging #2475 into bump_v17.06.5 will decrease coverage by 3.76%.
The diff coverage is 50%.

@@                Coverage Diff                @@
##           bump_v17.06.5    #2475      +/-   ##
=================================================
- Coverage           64.5%   60.74%   -3.77%     
=================================================
  Files                 59      121      +62     
  Lines               8762    20124   +11362     
=================================================
+ Hits                5652    12224    +6572     
- Misses              2534     6552    +4018     
- Partials             576     1348     +772

@stevvooe stevvooe merged commit c49ee94 into moby:bump_v17.06.5 Dec 19, 2017
@dperny dperny deleted the bump_v17.06.5-cherry-pick-2473 branch May 3, 2019 18:51
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants