client

package
v1.0.7 Latest Latest
Warning

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

Go to latest
Published: Sep 28, 2021 License: MIT Imports: 14 Imported by: 0

Documentation

Index

Constants

View Source
const (
	DefaultQPS   float32 = 20
	DefaultBurst int     = 30
)

Variables

This section is empty.

Functions

This section is empty.

Types

type Interface

type Interface interface {
	GetResource(ctx context.Context, resource Resource) (runtime.Object, error)
	CreateResource(ctx context.Context, resource Resource, body runtime.Object, options *metav1.CreateOptions) (runtime.Object, error)
	DeleteResource(ctx context.Context, resource Resource, options *metav1.DeleteOptions) error
	PatchResource(ctx context.Context, resource Resource, pt types.PatchType, data []byte, options *metav1.PatchOptions) (runtime.Object, error)
	UpdateResource(ctx context.Context, resource Resource, body runtime.Object, options *metav1.UpdateOptions) (runtime.Object, error)

	ListResources(ctx context.Context, resourceList ResourceList, options *metav1.ListOptions) (runtime.Object, error)
	WatchResources(ctx context.Context, resourceList ResourceList, options *metav1.ListOptions) (watch.Interface, error)
}

func NewForConfig

func NewForConfig(inConfig *rest.Config, clientNegotiator client_negotiator.ExtendedClientNegotiator) (Interface, error)

NewForConfig creates a new dynamic client or returns an error.

type Resource

type Resource interface {
	ResourceList
	Name() string
}

type ResourceList

type ResourceList interface {
	GroupVersionResource() *schema.GroupVersionResource
	Namespace() (namespace string, scoped bool)
}

Jump to

Keyboard shortcuts

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