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()
}
Click to show internal directories.
Click to hide internal directories.