kclient

package
v0.0.0-...-540bb61 Latest Latest
Warning

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

Go to latest
Published: Jun 25, 2023 License: Apache-2.0 Imports: 36 Imported by: 0

Documentation

Index

Constants

View Source
const (
	DefaultQPS   = rest.DefaultQPS * 3
	DefaultBurst = rest.DefaultBurst * 3
)
View Source
const Kubeconfig util.EnvironmentVariable = "KUBECONFIG"

Variables

This section is empty.

Functions

func GetDefaultRateLimiter

func GetDefaultRateLimiter() flowcontrol.RateLimiter

func GetRateLimiter

func GetRateLimiter(name string) flowcontrol.RateLimiter

func GetUnattachedRateLimiter

func GetUnattachedRateLimiter() flowcontrol.RateLimiter

func SetDefaultBurst

func SetDefaultBurst(q int)

func SetDefaultQPS

func SetDefaultQPS(q float32)

Types

type Client

type Client interface {
	Kubernetes() kubernetes.Interface
	KubernetesExtensions() apiextensionsclient.Interface
	Arango() versioned.Interface
	Monitoring() monitoring.Interface

	Name() string

	Config() *rest.Config
}

func NewFakeClient

func NewFakeClient() Client

func NewFakeClientWithVersion

func NewFakeClientWithVersion(version *version.Info) Client

func NewStaticClient

func NewStaticClient(kubernetes kubernetes.Interface, kubernetesExtensions apiextensionsclient.Interface, arango versioned.Interface, monitoring monitoring.Interface) Client

type ConfigGetter

type ConfigGetter func() (*rest.Config, string, error)

func NewStaticConfigGetter

func NewStaticConfigGetter(f func() (*rest.Config, error)) ConfigGetter

type Factory

type Factory interface {
	SetKubeConfigGetter(getter ConfigGetter)
	Refresh() error
	SetClient(c Client)

	Name() string

	Client() (Client, bool)
}

func GetDefaultFactory

func GetDefaultFactory() Factory

func GetFactory

func GetFactory(name string) Factory

func GetUnattachedFactory

func GetUnattachedFactory() Factory

type FakeClientBuilder

type FakeClientBuilder interface {
	Add(objects ...runtime.Object) FakeClientBuilder

	Version(version *version.Info) FakeClientBuilder

	Client() Client
}

func NewFakeClientBuilder

func NewFakeClientBuilder() FakeClientBuilder

type FakeDataInput

type FakeDataInput struct {
	Namespace string

	Pods            map[string]*core.Pod
	Secrets         map[string]*core.Secret
	Services        map[string]*core.Service
	PVCS            map[string]*core.PersistentVolumeClaim
	ServiceAccounts map[string]*core.ServiceAccount
	PDBSV1          map[string]*policy.PodDisruptionBudget
	ServiceMonitors map[string]*monitoring.ServiceMonitor
	ArangoMembers   map[string]*api.ArangoMember
	Nodes           map[string]*core.Node
	ACS             map[string]*api.ArangoClusterSynchronization
	AT              map[string]*api.ArangoTask
}

func (FakeDataInput) Client

func (f FakeDataInput) Client() Client

type ModInterface

type ModInterface interface {
	Secrets() secretv1.ModInterface
	Pods() podv1.ModInterface
	Services() servicev1.ModInterface
	ServiceAccounts() serviceaccountv1.ModInterface
	PersistentVolumeClaims() persistentvolumeclaimv1.ModInterface
	PodDisruptionBudgets() poddisruptionbudgetv1.ModInterface
	ServiceMonitors() servicemonitorv1.ModInterface
	ArangoMembers() arangomemberv1.ModInterface
}

func NewModInterface

func NewModInterface(client Client, namespace string) ModInterface

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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