Documentation ¶
Index ¶
- Constants
- Variables
- func New(_ runtime.Object, h framework.SchedulerFrameworkHandle) (framework.Plugin, error)
- type NodeAffinity
- func (pl *NodeAffinity) Filter(ctx context.Context, state *framework.CycleState, pod *v1.Pod, ...) *framework.Status
- func (pl *NodeAffinity) Name() string
- func (pl *NodeAffinity) NormalizeScore(ctx context.Context, state *framework.CycleState, pod *v1.Pod, ...) *framework.Status
- func (a *NodeAffinity) PreFilter(ctx context.Context, state *framework.CycleState, pod *v1.Pod) *framework.Status
- func (a *NodeAffinity) PreFilterExtensions() framework.PreFilterExtensions
- func (pl *NodeAffinity) Score(ctx context.Context, state *framework.CycleState, pod *v1.Pod, nodeName string) (int64, *framework.Status)
- func (pl *NodeAffinity) ScoreExtensions() framework.ScoreExtensions
Constants ¶
View Source
const (
// Name is the name of the plugin used in the plugin registry and configurations.
Name = "NodeAffinity"
)
Variables ¶
Functions ¶
Types ¶
type NodeAffinity ¶
type NodeAffinity struct {
// contains filtered or unexported fields
}
NodeAffinity is a plugin that checks if a pod node selector matches the node label.
func (*NodeAffinity) Filter ¶
func (pl *NodeAffinity) Filter(ctx context.Context, state *framework.CycleState, pod *v1.Pod, nodeInfo framework.NodeInfo) *framework.Status
Filter invoked at the filter extension point.
func (*NodeAffinity) Name ¶
func (pl *NodeAffinity) Name() string
Name returns name of the plugin. It is used in logs, etc.
func (*NodeAffinity) NormalizeScore ¶
func (pl *NodeAffinity) NormalizeScore(ctx context.Context, state *framework.CycleState, pod *v1.Pod, scores framework.NodeScoreList) *framework.Status
NormalizeScore invoked after scoring all nodes.
func (*NodeAffinity) PreFilter ¶
func (a *NodeAffinity) PreFilter(ctx context.Context, state *framework.CycleState, pod *v1.Pod) *framework.Status
func (*NodeAffinity) PreFilterExtensions ¶
func (a *NodeAffinity) PreFilterExtensions() framework.PreFilterExtensions
func (*NodeAffinity) Score ¶
func (pl *NodeAffinity) Score(ctx context.Context, state *framework.CycleState, pod *v1.Pod, nodeName string) (int64, *framework.Status)
Score invoked at the Score extension point.
func (*NodeAffinity) ScoreExtensions ¶
func (pl *NodeAffinity) ScoreExtensions() framework.ScoreExtensions
ScoreExtensions of the Score plugin.
Click to show internal directories.
Click to hide internal directories.