scaling

package
v0.0.0-...-82cf001 Latest Latest
Warning

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

Go to latest
Published: Feb 3, 2024 License: Unlicense Imports: 4 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func DecToInt64

func DecToInt64(value *inf.Dec) int64

truncates fractional digits and converts `value` to `int64`

func Horizontal

func Horizontal(s *strategy.State) (*strategy.ScalingDecision, error)

Horizontal recommends a new number of replicas based on the following calculation For each resource of cpu and memory it calculates the desired number of replicas as `desired = ceil(current * currentUtilization / targetUtilization)` (same formula as `HPA`) if picks the maximum of both values and compares that to the minimum and maximum allowed replicas the result will be max(min(desired, maxReplicas), minReplicas)

func Hybrid

func Hybrid(s *strategy.State, cpuLimitsToRequestsRatio, memoryLimitsToRequestsRatio *inf.Dec) (*strategy.ScalingDecision, error)

Recommends vertical and horizontal scaling

func Vertical

func Vertical(s *strategy.State, cpuLimitsToRequestsRatio, memoryLimitsToRequestsRatio *inf.Dec) (*strategy.ScalingDecision, error)

Recommends new resource requests and limits keeping ratios between both and each container's share of the pod's resources

Types

This section is empty.

Jump to

Keyboard shortcuts

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