initializer

package
v0.3.1 Latest Latest
Warning

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

Go to latest
Published: Apr 13, 2017 License: Apache-2.0 Imports: 5 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	ErrSkip = fmt.Errorf("This initializer will not process this resource")
)

Functions

func AddFinalizer

func AddFinalizer(dst Object, additions ...string)

func AddInitializer

func AddInitializer(dst Object, additions ...string)

func HasFinalizer

func HasFinalizer(obj Object, name string) bool

func HasInitializer

func HasInitializer(obj Object, names ...string) bool

True if it has any one of them

func RemoveFinalizer

func RemoveFinalizer(dst Object, removals ...string)

func RemoveInitializer

func RemoveInitializer(dst Object, removals ...string)

Types

type Initializer

type Initializer interface {
	Token() string
	Initialize(Object) (Object, error, bool)
	Finalize(Object) (Object, error, bool)
}

type InitializerManager

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

func NewInitializerManager

func NewInitializerManager(list []Initializer, kubeClient clientset.Interface) (im *InitializerManager, err error)

func (*InitializerManager) Finalize

func (im *InitializerManager) Finalize(obj Object) (updatedObj Object, err error, retry bool)

func (*InitializerManager) FinalizeAll

func (im *InitializerManager) FinalizeAll(obj Object) (updatedObj Object, err error, retry bool)

func (*InitializerManager) Initialize

func (im *InitializerManager) Initialize(obj Object) (updatedObj Object, err error, retry bool)

type InitializerMap

type InitializerMap map[string]Initializer

type Object

type Object interface {
	runtime.Object

	GetInitializers() []string
	SetInitializers([]string)

	GetFinalizers() []string
	SetFinalizers([]string)
}

Jump to

Keyboard shortcuts

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