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

core

package
v0.11.0 Latest Latest
Warning

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

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

Documentation

Overview

Package core contains structs and functions to aggregate built-in kube clients for use elsewhere

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func InitializeClients

func InitializeClients(ctx context.Context, logger logging.Logger, clients ...Initializable) error

InitializeClients initializes a list of clients, collecting all errors.

Types

type Clients

type Clients struct {
	Dynamic   dynamic.Interface
	Discovery discovery.DiscoveryInterface
	Tree      *xrm.Client

	// Kube is the generated, typed clientset. Most of this tool works in
	// Unstructured because it deals in arbitrary user-defined GVKs, but a few
	// built-in APIs have a fixed shape that is worth having checked at compile
	// time -- SelfSubjectAccessReview (see kubernetes.AccessChecker) is one,
	// where an untyped round-trip meant hand-writing the request's keys and
	// reading the response back with NestedBool/NestedString.
	Kube kubeclient.Interface
}

Clients aggregates the root level of built-in kube clients that we use to initialize our wrapper interfaces.

func NewClients

func NewClients(config *rest.Config) (*Clients, error)

NewClients initializes a bundle of built-in kube clients using the given rest config.

type Initializable

type Initializable interface {
	Initialize(ctx context.Context) error
}

Initializable is an interface for any client that can be initialized.

Jump to

Keyboard shortcuts

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