mirror of
https://github.com/k3s-io/kubernetes.git
synced 2025-07-22 19:31:44 +00:00
fix: update run filter plugin for consistency
This commit is contained in:
parent
feb64858aa
commit
859cac0595
@ -312,13 +312,12 @@ func (f *framework) RunPrefilterPlugins(
|
||||
// Meanwhile, the failure message and status are set for the given node.
|
||||
func (f *framework) RunFilterPlugins(pc *PluginContext,
|
||||
pod *v1.Pod, nodeName string) *Status {
|
||||
|
||||
for _, p := range f.filterPlugins {
|
||||
status := p.Filter(pc, pod, nodeName)
|
||||
for _, pl := range f.filterPlugins {
|
||||
status := pl.Filter(pc, pod, nodeName)
|
||||
if !status.IsSuccess() {
|
||||
if status.Code() != Unschedulable {
|
||||
errMsg := fmt.Sprintf("RunFilterPlugins: error while running %s filter plugin for pod %s: %s",
|
||||
p.Name(), pod.Name, status.Message())
|
||||
errMsg := fmt.Sprintf("RunFilterPlugins: error while running %v filter plugin for pod %v: %v",
|
||||
pl.Name(), pod.Name, status.Message())
|
||||
klog.Error(errMsg)
|
||||
return NewStatus(Error, errMsg)
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user