moby / moby/swarmkit

Task reaper does not consider some tasks for removal

Open
#2,555 13 comments 2 reactions 1 assignee View on GitHub

@nishanttotla is already working on this.

Since Mar 13, 2018.

area/orchestration kind/bug
Dominant language
Go
Stars
3.7k
Forks
676
Avg merge
4d 9h
Merged PRs (30d)
6

Description

https://github.com/docker/swarmkit/pull/2461 looks at tasks with desired state REMOVE and only considers them for deletion if they have moved past COMPLETED:

		for _, t := range removeTasks {
			if t.Status.State >= api.TaskStateCompleted {
				tr.cleanup = append(tr.cleanup, t.ID)
			}
		}

This misses the case for when the service was removed and perhaps had some tasks that never got to run.

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.