Documentation ¶
Overview ¶
Package loadvariationriskbalancing plugin attempts to balance the risk in load variation across the cluster. Risk is expressed as the sum of average and standard deviation of the measured load on a node. Typical load balancing involves only the average load. Here, we consider the variation in load as well, hence resulting in a safer balance.
Index ¶
- Constants
- func New(obj runtime.Object, handle framework.Handle) (framework.Plugin, error)
- type Collector
- type LoadVariationRiskBalancing
- func (pl *LoadVariationRiskBalancing) Name() string
- func (pl *LoadVariationRiskBalancing) NormalizeScore(context.Context, *framework.CycleState, *v1.Pod, framework.NodeScoreList) *framework.Status
- func (pl *LoadVariationRiskBalancing) Score(ctx context.Context, cycleState *framework.CycleState, pod *v1.Pod, ...) (int64, *framework.Status)
- func (pl *LoadVariationRiskBalancing) ScoreExtensions() framework.ScoreExtensions
Constants ¶
const (
// Name : name of plugin
Name = "LoadVariationRiskBalancing"
)
Variables ¶
This section is empty.
Functions ¶
Types ¶
type Collector ¶
type Collector struct {
// contains filtered or unexported fields
}
Collector : get data from load watcher, encapsulating the load watcher and its operations
Currently, the Collector owns its own load watcher and is used solely by the LoadVariationRiskBalancing plugin. Other Trimaran plugins, such as the TargetLoadPacking, have their own load watchers. The reason being that the Trimaran plugins have different, potentially conflicting, objectives. Thus, it is recommended not to enable them concurrently. As such, they are currently designed to each have its own load-watcher. If a need arises in the future to enable multiple Trimaran plugins, a restructuring to have a single Collector, serving the multiple plugins, may be beneficial for performance reasons.
type LoadVariationRiskBalancing ¶
type LoadVariationRiskBalancing struct {
// contains filtered or unexported fields
}
LoadVariationRiskBalancing : scheduler plugin
func (*LoadVariationRiskBalancing) Name ¶
func (pl *LoadVariationRiskBalancing) Name() string
Name : name of plugin
func (*LoadVariationRiskBalancing) NormalizeScore ¶
func (pl *LoadVariationRiskBalancing) NormalizeScore(context.Context, *framework.CycleState, *v1.Pod, framework.NodeScoreList) *framework.Status
NormalizeScore : normalize scores
func (*LoadVariationRiskBalancing) Score ¶
func (pl *LoadVariationRiskBalancing) Score(ctx context.Context, cycleState *framework.CycleState, pod *v1.Pod, nodeName string) (int64, *framework.Status)
Score : evaluate score for a node
func (*LoadVariationRiskBalancing) ScoreExtensions ¶
func (pl *LoadVariationRiskBalancing) ScoreExtensions() framework.ScoreExtensions
ScoreExtensions : an interface for Score extended functionality