Skip to content

Commit 9ebd872

Browse files
committed
Explicitly declare the interfaces for extension points
This make it easier to catch the issue during the compilation, also, this also align with other plugins, i.e. plugin of "InterPodAffinity". Signed-off-by: Dave Chen <[email protected]>
1 parent 53f3699 commit 9ebd872

File tree

2 files changed

+2
-0
lines changed

2 files changed

+2
-0
lines changed

pkg/scheduler/framework/plugins/defaultpodtopologyspread/default_pod_topology_spread.go

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -33,6 +33,7 @@ type DefaultPodTopologySpread struct {
3333
handle framework.FrameworkHandle
3434
}
3535

36+
var _ framework.PreScorePlugin = &DefaultPodTopologySpread{}
3637
var _ framework.ScorePlugin = &DefaultPodTopologySpread{}
3738

3839
const (

pkg/scheduler/framework/plugins/nodeports/node_ports.go

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -28,6 +28,7 @@ import (
2828
// NodePorts is a plugin that checks if a node has free ports for the requested pod ports.
2929
type NodePorts struct{}
3030

31+
var _ framework.PreFilterPlugin = &NodePorts{}
3132
var _ framework.FilterPlugin = &NodePorts{}
3233

3334
const (

0 commit comments

Comments
 (0)