Help us shape the future of Go! Take the 2026 Go Developer Survey

client

package
v1.18.8 Latest Latest
Warning

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

Go to latest
Published: Oct 21, 2026 License: Apache-2.0 Imports: 12 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	LoopFactoryCache = loop.New[loops.EventClient](16)
)

Functions

This section is empty.

Types

type Client

type Client[T meta.Resource] struct {
	// contains filtered or unexported fields
}

func New

func New[T meta.Resource](opts Options[T]) *Client[T]

func (*Client[T]) CacheLoop

func (c *Client[T]) CacheLoop()

func (*Client[T]) Handle

func (c *Client[T]) Handle(ctx context.Context, event loops.EventClient) error

func (*Client[T]) Run

func (c *Client[T]) Run(ctx context.Context) error

type Options

type Options[T meta.Resource] struct {
	EventCh        <-chan *informer.Event[T]
	CancelWatch    context.CancelFunc
	Stream         sender.Interface
	Namespace      string
	KubeClient     client.Client
	ProcessSecrets func(context.Context, *T, string, client.Client) error
	// Filter, when set, drops any event for which it returns false before it is
	// enqueued or streamed. Used to forward only the resources that belong to the
	// connecting app.
	Filter func(T) bool
}

Jump to

Keyboard shortcuts

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