mirror of
https://github.com/k3s-io/kubernetes.git
synced 2025-07-28 05:57:25 +00:00
Return when removePod failed
This commit is contained in:
parent
6ff3b68d72
commit
6410ac3173
4
pkg/scheduler/internal/cache/cache.go
vendored
4
pkg/scheduler/internal/cache/cache.go
vendored
@ -407,7 +407,9 @@ func (cache *schedulerCache) AddPod(pod *v1.Pod) error {
|
|||||||
// The pod was added to a different node than it was assumed to.
|
// The pod was added to a different node than it was assumed to.
|
||||||
klog.Warningf("Pod %v was assumed to be on %v but got added to %v", key, pod.Spec.NodeName, currState.pod.Spec.NodeName)
|
klog.Warningf("Pod %v was assumed to be on %v but got added to %v", key, pod.Spec.NodeName, currState.pod.Spec.NodeName)
|
||||||
// Clean this up.
|
// Clean this up.
|
||||||
cache.removePod(currState.pod)
|
if err = cache.removePod(currState.pod); err != nil {
|
||||||
|
klog.Errorf("removing pod error: %v", err)
|
||||||
|
}
|
||||||
cache.addPod(pod)
|
cache.addPod(pod)
|
||||||
}
|
}
|
||||||
delete(cache.assumedPods, key)
|
delete(cache.assumedPods, key)
|
||||||
|
Loading…
Reference in New Issue
Block a user