asg

package
v16.1.1 Latest Latest
Warning

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

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

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func IsInvalidConfig

func IsInvalidConfig(err error) bool

IsInvalidConfig asserts invalidConfigError.

func IsNoASG

func IsNoASG(err error) bool

IsNoASG asserts noASGError.

func IsNoDrainable

func IsNoDrainable(err error) bool

IsNoDrainable asserts noDrainableError.

Types

type ASG

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

func New

func New(config Config) (*ASG, error)

func (*ASG) Drainable

func (a *ASG) Drainable(ctx context.Context, obj interface{}) (string, error)

type Config

type Config struct {
	Stack        string
	TagKey       string
	TagValueFunc func(cr key.LabelsGetter) string
}

type Interface

type Interface interface {
	// Drainable returns any drainable ASG name found. When using this method the
	// returned ASG name will be the first one found having an active lifecycle
	// hook configured. E.g. when using an implementation configured for HA
	// Masters. Note that there may be one or three masters.
	Drainable(ctx context.Context, obj interface{}) (string, error)
}

Interface describes how implementations should behave when providing information about ASGs. Note that when caching enabled the returned results stay consistently the same throughout a reconciliation loop.

Directories

Path Synopsis
internal

Jump to

Keyboard shortcuts

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