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

Revert "Evict pods w/o rate-limit when cloud says node is gone." #22297

Merged
merged 1 commit into from
Mar 1, 2016
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
21 changes: 2 additions & 19 deletions pkg/controller/node/nodecontroller.go
Original file line number Diff line number Diff line change
Expand Up @@ -479,26 +479,9 @@ func (nc *NodeController) monitorNodeStatus() error {
continue
}
if remaining {
// Immediately evict pods (skip rate-limited evictor)
// queue eviction of the pods on the node
glog.V(2).Infof("Deleting node %s is delayed while pods are evicted", node.Name)
go func(nodeName string) {
nc.evictorLock.Lock()
defer nc.evictorLock.Unlock()
remaining, err := nc.deletePods(nodeName)
if err != nil {
glog.Errorf("Unable to evict pods from node %s: %v", nodeName, err)
nc.podEvictor.Add(nodeName)
return
}
if !remaining {
return
}
// Immediately terminate pods.
if _, _, err := nc.terminatePods(nodeName, time.Now()); err != nil {
glog.Errorf("Unable to terminate pods on node %s: %v", nodeName, err)
nc.terminationEvictor.Add(nodeName)
}
}(node.Name)
nc.evictPods(node.Name)
continue
}

Expand Down