estimator

package
v1.4.1 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Feb 26, 2024 License: Apache-2.0 Imports: 8 Imported by: 0

Documentation

Index

Constants

View Source
const (

	// DefaultMilliCPURequest defines default milli cpu request number.
	DefaultMilliCPURequest int64 = 250 // 0.25 core
	// DefaultMemoryRequest defines default memory request size.
	DefaultMemoryRequest int64 = 200 * 1024 * 1024 // 200 MB
)

Variables

View Source
var Estimators = map[string]FactoryFn{
	// contains filtered or unexported fields
}

Functions

This section is empty.

Types

type DefaultEstimator

type DefaultEstimator struct {
	// contains filtered or unexported fields
}

func (*DefaultEstimator) EstimateNode added in v1.3.0

func (e *DefaultEstimator) EstimateNode(node *corev1.Node) (corev1.ResourceList, error)

func (*DefaultEstimator) EstimatePod added in v1.3.0

func (e *DefaultEstimator) EstimatePod(pod *corev1.Pod) (map[corev1.ResourceName]int64, error)

func (*DefaultEstimator) Name

func (e *DefaultEstimator) Name() string

type Estimator

type Estimator interface {
	Name() string
	EstimatePod(pod *corev1.Pod) (map[corev1.ResourceName]int64, error)
	EstimateNode(node *corev1.Node) (corev1.ResourceList, error)
}

func NewDefaultEstimator

func NewDefaultEstimator(args *config.LoadAwareSchedulingArgs, handle framework.Handle) (Estimator, error)

func NewEstimator

func NewEstimator(args *config.LoadAwareSchedulingArgs, handle framework.Handle) (Estimator, error)

type FactoryFn

type FactoryFn func(args *config.LoadAwareSchedulingArgs, handle framework.Handle) (Estimator, error)

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL