Merge pull request #307 from thaJeztah/18.09_bump_swarmkit
[18.09] bump swarmkit to 142a73731c850daf24d32001aa2358b6ffe36eab (bump_v18.09)
This commit is contained in:
commit
af1b34f4fc
2 changed files with 17 additions and 6 deletions
|
@ -130,7 +130,7 @@ github.com/containerd/ttrpc 2a805f71863501300ae1976d29f0454ae003e85a
|
||||||
github.com/gogo/googleapis 08a7655d27152912db7aaf4f983275eaf8d128ef
|
github.com/gogo/googleapis 08a7655d27152912db7aaf4f983275eaf8d128ef
|
||||||
|
|
||||||
# cluster
|
# cluster
|
||||||
github.com/docker/swarmkit 19e791fd6dc76e8e894cbc99b77f946b7d00ebb9 # bump_v18.09 branch
|
github.com/docker/swarmkit 142a73731c850daf24d32001aa2358b6ffe36eab # bump_v18.09 branch
|
||||||
github.com/gogo/protobuf v1.0.0
|
github.com/gogo/protobuf v1.0.0
|
||||||
github.com/cloudflare/cfssl 1.3.2
|
github.com/cloudflare/cfssl 1.3.2
|
||||||
github.com/fernet/fernet-go 1b2437bc582b3cfbb341ee5a29f8ef5b42912ff2
|
github.com/fernet/fernet-go 1b2437bc582b3cfbb341ee5a29f8ef5b42912ff2
|
||||||
|
|
21
vendor/github.com/docker/swarmkit/manager/controlapi/node.go
generated
vendored
21
vendor/github.com/docker/swarmkit/manager/controlapi/node.go
generated
vendored
|
@ -265,12 +265,23 @@ func orphanNodeTasks(tx store.Tx, nodeID string) error {
|
||||||
return err
|
return err
|
||||||
}
|
}
|
||||||
for _, task := range tasks {
|
for _, task := range tasks {
|
||||||
task.Status = api.TaskStatus{
|
// this operation must occur within the same transaction boundary. If
|
||||||
Timestamp: gogotypes.TimestampNow(),
|
// we cannot accomplish this task orphaning in the same transaction, we
|
||||||
State: api.TaskStateOrphaned,
|
// could crash or die between transactions and not get a chance to do
|
||||||
Message: "Task belonged to a node that has been deleted",
|
// this. however, in cases were there is an exceptionally large number
|
||||||
|
// of tasks for a node, this may cause the transaction to exceed the
|
||||||
|
// max message size.
|
||||||
|
//
|
||||||
|
// therefore, we restrict updating to only tasks in a non-terminal
|
||||||
|
// state. Tasks in a terminal state do not need to be updated.
|
||||||
|
if task.Status.State < api.TaskStateCompleted {
|
||||||
|
task.Status = api.TaskStatus{
|
||||||
|
Timestamp: gogotypes.TimestampNow(),
|
||||||
|
State: api.TaskStateOrphaned,
|
||||||
|
Message: "Task belonged to a node that has been deleted",
|
||||||
|
}
|
||||||
|
store.UpdateTask(tx, task)
|
||||||
}
|
}
|
||||||
store.UpdateTask(tx, task)
|
|
||||||
}
|
}
|
||||||
return nil
|
return nil
|
||||||
}
|
}
|
||||||
|
|
Loading…
Add table
Reference in a new issue