Documentation ¶
Index ¶
- Constants
- type AvailabilityNodePriority
- func (pl *AvailabilityNodePriority) Name() string
- func (pl *AvailabilityNodePriority) NormalizeScore(ctx context.Context, states *state.State, scores state.PodScoreList) *state.Status
- func (pl *AvailabilityNodePriority) Score(ctx context.Context, args interface{}, states *state.State, ...) (uint64, *state.Status)
- func (pl *AvailabilityNodePriority) ScoreExtensions() state.ScoreExtensions
Constants ¶
View Source
const ( ErrReasonInvalidArg = "invalid arguments" ErrReasonNoResource = "node does not exist" )
View Source
const Name = state.AvailabilityNodePriority
Name of the plugin
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type AvailabilityNodePriority ¶
type AvailabilityNodePriority struct { }
AvailabilityNodePriority is a score plugin that favors pods that create an even spread of resources across nodes for HA
func (*AvailabilityNodePriority) Name ¶
func (pl *AvailabilityNodePriority) Name() string
Name returns name of the plugin
func (*AvailabilityNodePriority) NormalizeScore ¶
func (pl *AvailabilityNodePriority) NormalizeScore(ctx context.Context, states *state.State, scores state.PodScoreList) *state.Status
NormalizeScore invoked after scoring all pods.
func (*AvailabilityNodePriority) Score ¶
func (pl *AvailabilityNodePriority) Score(ctx context.Context, args interface{}, states *state.State, feasiblePods []int32, key types.NamespacedName, podID int32) (uint64, *state.Status)
Score invoked at the score extension point. The "score" returned in this function is higher for nodes that create an even spread across nodes.
func (*AvailabilityNodePriority) ScoreExtensions ¶
func (pl *AvailabilityNodePriority) ScoreExtensions() state.ScoreExtensions
ScoreExtensions of the Score plugin.
Click to show internal directories.
Click to hide internal directories.