controller

package
v0.0.0-...-fc37f7f Latest Latest
Warning

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

Go to latest
Published: May 2, 2024 License: MIT Imports: 20 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func NewIndexerInformer

func NewIndexerInformer(prefix, kind, apiVersion, labelSelector string,
	queue workqueue.RateLimitingInterface, dynamicClient dynamic.Interface,
) (cache.Indexer, cache.Controller)

func Read

func Read(kube *rest.Config, cfg config.Config) (map[string]interface{}, error)

Types

type Controller

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

Controller demonstrates how to implement a controller with client-go.

func NewController

func NewController(queue workqueue.RateLimitingInterface,
	indexer map[string]cache.Indexer, informer map[string]cache.Controller,
) *Controller

NewController creates a new Controller.

func NewForConfig

func NewForConfig(config config.Config, restConfig *rest.Config) (*Controller, error)

func (*Controller) GetProcessChan

func (c *Controller) GetProcessChan() <-chan []byte

GetProcessChan returns the channel to which the processed data is sent.

func (*Controller) Run

func (c *Controller) Run(stopCh chan struct{})

Run begins watching and syncing.

func (*Controller) SetDelay

func (c *Controller) SetDelay(d time.Duration)

SetDelay between consecutive syncs. Defaults to 1 second.

func (*Controller) SetRetries

func (c *Controller) SetRetries(r int)

SetRetries sets the number of retries before dropping an item out of the queue.

Jump to

Keyboard shortcuts

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