Version: v0.19.0 Latest Latest

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

Go to latest
Published: Aug 26, 2022 License: Apache-2.0 Imports: 5 Imported by: 0




This section is empty.


This section is empty.


This section is empty.


type Informer added in v0.13.0

type Informer interface {
	Start(stopCh <-chan struct{})
	WaitForCacheSync(stopCh <-chan struct{}) map[reflect.Type]bool

Informer is the subset of SharedInformerFactory needed for starting an informer cache and waiting for it to sync.

type Runner

type Runner func(context.Context)

Runner is something that can be run such as a series of controllers. Blocks until context is canceled.

type RunnerBuilder

type RunnerBuilder func(context.Context) (Runner, error)

RunnerBuilder is a function that can be used to construct a Runner. It is expected to be called in the main go routine since the construction can fail.

func Prepare

func Prepare(controllers Runner, controllersWrapper RunnerWrapper, informers ...Informer) RunnerBuilder

Prepare returns RunnerBuilder that, when called: 1.) Starts all provided informers and waits for them sync (and fails if they hang), and 2.) Returns a Runner that combines the Runner and RunnerWrapper passed into Prepare.

type RunnerWrapper

type RunnerWrapper func(context.Context, Runner)

RunnerWrapper takes a Runner and wraps its execution with other logic. Blocks until context is canceled. RunnerWrapper is responsible for the lifetime of the passed in Runner.

Jump to

Keyboard shortcuts

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