autoscaler

package
v1.1.0 Latest Latest
Warning

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

Go to latest
Published: Apr 7, 2021 License: Apache-2.0 Imports: 6 Imported by: 0

Documentation

Overview

Package autoscaler provides methods for scaling a resource - by triggering metric gathering, feeding these metrics to an evaluation and using this evaluation to scale the resource.

Index

Constants

View Source
const RunType = "scaler"

RunType autoscaler marks the metric gathering/evaluation as running during a scale

Variables

This section is empty.

Functions

This section is empty.

Types

type Scaler

type Scaler struct {
	Scaler          scale.Scaler
	Client          resourceclient.Client
	Config          *config.Config
	GetMetricer     metric.GetMetricer
	GetEvaluationer evaluate.GetEvaluationer
}

Scaler handles scaling up/down the resource being managed; triggering metric gathering and feeding an evaluator these metrics, before taking the results and using them to interact with Kubernetes to scale up/down

func (*Scaler) Scale

func (s *Scaler) Scale() error

Scale gets the managed resource, gathers metrics, evaluates these metrics and finally if a change is required then it scales the resource

Jump to

Keyboard shortcuts

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