autoscaler

package
v1.9.0 Latest Latest
Warning

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

Go to latest
Published: Nov 15, 2024 License: Apache-2.0 Imports: 14 Imported by: 0

Documentation

Overview

Package autoscaler implements logic to poll the k8s apiserver for cluster status, and update the replicas number of a deployment/rc/rs based on current status.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type AutoScaler

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

AutoScaler determines the number of replicas to run

func NewAutoScaler

func NewAutoScaler(c *options.AutoScalerConfig) (*AutoScaler, error)

NewAutoScaler returns a new AutoScaler

func (*AutoScaler) Run

func (s *AutoScaler) Run()

Run periodically counts the number of nodes and cores, estimates the expected number of replicas, compares them to the actual replicas, and updates the target resource with the expected replicas if necessary.

type HealthServer

type HealthServer interface {
	Start()
}

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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