1
0
mirror of https://github.com/kubernetes-sigs/descheduler.git synced 2026-01-25 20:59:28 +01:00

Merge pull request #922 from jklaw90/remove-plugin

removing dupe plugin interface check
This commit is contained in:
Kubernetes Prow Robot
2022-08-25 12:48:08 -07:00
committed by GitHub
9 changed files with 7 additions and 17 deletions

View File

@@ -19,6 +19,7 @@ package nodeutilization
import (
"context"
"fmt"
v1 "k8s.io/api/core/v1"
"k8s.io/apimachinery/pkg/api/resource"
"k8s.io/apimachinery/pkg/runtime"
@@ -42,7 +43,6 @@ type HighNodeUtilization struct {
podFilter func(pod *v1.Pod) bool
}
var _ framework.Plugin = &HighNodeUtilization{}
var _ framework.BalancePlugin = &HighNodeUtilization{}
// NewHighNodeUtilization builds plugin from its arguments while passing a handle

View File

@@ -19,6 +19,7 @@ package nodeutilization
import (
"context"
"fmt"
v1 "k8s.io/api/core/v1"
"k8s.io/apimachinery/pkg/api/resource"
"k8s.io/apimachinery/pkg/runtime"
@@ -40,7 +41,6 @@ type LowNodeUtilization struct {
podFilter func(pod *v1.Pod) bool
}
var _ framework.Plugin = &LowNodeUtilization{}
var _ framework.BalancePlugin = &LowNodeUtilization{}
// NewLowNodeUtilization builds plugin from its arguments while passing a handle

View File

@@ -34,10 +34,7 @@ import (
const PluginName = "PodLifeTime"
var (
_ framework.Plugin = &PodLifeTime{}
_ framework.DeschedulePlugin = &PodLifeTime{}
)
var _ framework.DeschedulePlugin = &PodLifeTime{}
// PodLifeTime evicts pods on the node that violate the max pod lifetime threshold
type PodLifeTime struct {

View File

@@ -19,13 +19,14 @@ package removeduplicates
import (
"context"
"fmt"
metav1 "k8s.io/apimachinery/pkg/apis/meta/v1"
"math"
"reflect"
"sigs.k8s.io/descheduler/pkg/utils"
"sort"
"strings"
metav1 "k8s.io/apimachinery/pkg/apis/meta/v1"
"sigs.k8s.io/descheduler/pkg/utils"
v1 "k8s.io/api/core/v1"
"k8s.io/apimachinery/pkg/runtime"
"k8s.io/apimachinery/pkg/util/sets"
@@ -50,7 +51,6 @@ type RemoveDuplicates struct {
podFilter podutil.FilterFunc
}
var _ framework.Plugin = &RemoveDuplicates{}
var _ framework.BalancePlugin = &RemoveDuplicates{}
type podOwner struct {

View File

@@ -42,7 +42,6 @@ type RemoveFailedPods struct {
podFilter podutil.FilterFunc
}
var _ framework.Plugin = &RemoveFailedPods{}
var _ framework.DeschedulePlugin = &RemoveFailedPods{}
// New builds plugin from its arguments while passing a handle

View File

@@ -42,10 +42,7 @@ type RemovePodsHavingTooManyRestarts struct {
podFilter podutil.FilterFunc
}
var (
_ framework.Plugin = &RemovePodsHavingTooManyRestarts{}
_ framework.DeschedulePlugin = &RemovePodsHavingTooManyRestarts{}
)
var _ framework.DeschedulePlugin = &RemovePodsHavingTooManyRestarts{}
// New builds plugin from its arguments while passing a handle
func New(args runtime.Object, handle framework.Handle) (framework.Plugin, error) {

View File

@@ -42,7 +42,6 @@ type RemovePodsViolatingInterPodAntiAffinity struct {
podFilter podutil.FilterFunc
}
var _ framework.Plugin = &RemovePodsViolatingInterPodAntiAffinity{}
var _ framework.DeschedulePlugin = &RemovePodsViolatingInterPodAntiAffinity{}
// New builds plugin from its arguments while passing a handle

View File

@@ -39,7 +39,6 @@ type RemovePodsViolatingNodeAffinity struct {
podFilter podutil.FilterFunc
}
var _ framework.Plugin = &RemovePodsViolatingNodeAffinity{}
var _ framework.DeschedulePlugin = &RemovePodsViolatingNodeAffinity{}
// New builds plugin from its arguments while passing a handle

View File

@@ -42,7 +42,6 @@ type RemovePodsViolatingNodeTaints struct {
podFilter podutil.FilterFunc
}
var _ framework.Plugin = &RemovePodsViolatingNodeTaints{}
var _ framework.DeschedulePlugin = &RemovePodsViolatingNodeTaints{}
// New builds plugin from its arguments while passing a handle