client

package
v1.1.0 Latest Latest
Warning

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

Go to latest
Published: Sep 21, 2021 License: Apache-2.0 Imports: 18 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var CreateDryRunAll = DryRunAll

CreateDryRunAll sets the "dry run" option to "all".

Deprecated: Use DryRunAll

View Source
var DryRunAll = dryRunAll{}

DryRunAll sets the "dry run" option to "all", executing all validation, etc without persisting the change to storage.

View Source
var ForceOwnership = forceOwnership{}

ForceOwnership indicates that in case of conflicts with server-side apply, the client should acquire ownership of the conflicting field. Most controllers should use this.

View Source
var PatchDryRunAll = DryRunAll

PatchDryRunAll sets the "dry run" option to "all".

Deprecated: Use DryRunAll

View Source
var UpdateDryRunAll = DryRunAll

UpdateDryRunAll sets the "dry run" option to "all".

Deprecated: Use DryRunAll

Functions

func IgnoreNotFound

func IgnoreNotFound(err error) error

IgnoreNotFound returns nil on NotFound errors. All other values that are not NotFound errors or nil are returned unmodified.

Types

type Client

type Client interface {
	Reader
	Writer
	StatusClient
}

Client knows how to perform CRUD operations on Kubernetes objects.

type ClientCache

type ClientCache interface {
	GetObjMeta(obj runtime.Object) (*ObjMeta, error)
	GetResource(obj runtime.Object) (*ResourceMeta, error)
}

func NewClientCache

func NewClientCache(config *rest.Config, options Options) ClientCache

type Continue

type Continue string

Continue sets a continuation token to retrieve chunks of results when using limit. Continue does not implement DeleteAllOfOption interface because the server does not support setting it for deletecollection operations.

func (Continue) ApplyToList

func (c Continue) ApplyToList(opts *ListOptions)

ApplyToList applies this configuration to the given an List options.

type CreateOption

type CreateOption interface {
	// ApplyToCreate applies this configuration to the given create options.
	ApplyToCreate(*CreateOptions)
}

CreateOption is some configuration that modifies options for a create request.

type CreateOptions

type CreateOptions struct {
	// When present, indicates that modifications should not be
	// persisted. An invalid or unrecognized dryRun directive will
	// result in an error response and no further processing of the
	// request. Valid values are:
	// - All: all dry run stages will be processed
	DryRun []string

	// FieldManager is the name of the user or component submitting
	// this request.  It must be set with server-side apply.
	FieldManager string

	// URLOption ov
	URLOption *URLOptions

	Workspace *WorkspaceOptions

	// Raw represents raw CreateOptions, as passed to the API server.
	Raw *metav1.CreateOptions
}

CreateOptions contains options for create requests. It's generally a subset of metav1.CreateOptions.

func (*CreateOptions) ApplyOptions

func (o *CreateOptions) ApplyOptions(opts []CreateOption) *CreateOptions

ApplyOptions applies the given create options on these options, and then returns itself (for convenient chaining).

func (*CreateOptions) ApplyToCreate

func (o *CreateOptions) ApplyToCreate(co *CreateOptions)

ApplyToCreate implements CreateOption

func (*CreateOptions) AsCreateOptions

func (o *CreateOptions) AsCreateOptions() *metav1.CreateOptions

AsCreateOptions returns these options as a metav1.CreateOptions. This may mutate the Raw field.

type DeleteAllOfOption

type DeleteAllOfOption interface {
	// ApplyToDeleteAllOf applies this configuration to the given deletecollection options.
	ApplyToDeleteAllOf(*DeleteAllOfOptions)
}

DeleteAllOfOption is some configuration that modifies options for a delete request.

type DeleteAllOfOptions

type DeleteAllOfOptions struct {
	ListOptions
	DeleteOptions
}

DeleteAllOfOptions contains options for deletecollection (deleteallof) requests. It's just list and delete options smooshed together.

func (*DeleteAllOfOptions) ApplyOptions

func (o *DeleteAllOfOptions) ApplyOptions(opts []DeleteAllOfOption) *DeleteAllOfOptions

ApplyOptions applies the given deleteallof options on these options, and then returns itself (for convenient chaining).

func (*DeleteAllOfOptions) ApplyToDeleteAllOf

func (o *DeleteAllOfOptions) ApplyToDeleteAllOf(do *DeleteAllOfOptions)

ApplyToDeleteAllOf implements DeleteAllOfOption

type DeleteOption

type DeleteOption interface {
	// ApplyToDelete applies this configuration to the given delete options.
	ApplyToDelete(*DeleteOptions)
}

DeleteOption is some configuration that modifies options for a delete request.

type DeleteOptions

type DeleteOptions struct {
	// GracePeriodSeconds is the duration in seconds before the object should be
	// deleted. Value must be non-negative integer. The value zero indicates
	// delete immediately. If this value is nil, the default grace period for the
	// specified type will be used.
	GracePeriodSeconds *int64

	// Preconditions must be fulfilled before a deletion is carried out. If not
	// possible, a 409 Conflict status will be returned.
	Preconditions *metav1.Preconditions

	// PropagationPolicy determined whether and how garbage collection will be
	// performed. Either this field or OrphanDependents may be set, but not both.
	// The default policy is decided by the existing finalizer set in the
	// metadata.finalizers and the resource-specific default policy.
	// Acceptable values are: 'Orphan' - orphan the dependents; 'Background' -
	// allow the garbage collector to delete the dependents in the background;
	// 'Foreground' - a cascading policy that deletes all dependents in the
	// foreground.
	PropagationPolicy *metav1.DeletionPropagation

	// Raw represents raw DeleteOptions, as passed to the API server.
	Raw *metav1.DeleteOptions

	// When present, indicates that modifications should not be
	// persisted. An invalid or unrecognized dryRun directive will
	// result in an error response and no further processing of the
	// request. Valid values are:
	// - All: all dry run stages will be processed
	DryRun []string

	// URLOption overwrites an GVK based API URL.
	URLOption *URLOptions

	// Workspace represents the workspace for object that deleting.
	Workspace *WorkspaceOptions
}

DeleteOptions contains options for delete requests. It's generally a subset of metav1.DeleteOptions.

func (*DeleteOptions) ApplyOptions

func (o *DeleteOptions) ApplyOptions(opts []DeleteOption) *DeleteOptions

ApplyOptions applies the given delete options on these options, and then returns itself (for convenient chaining).

func (*DeleteOptions) ApplyToDelete

func (o *DeleteOptions) ApplyToDelete(do *DeleteOptions)

ApplyToDelete implements DeleteOption

func (*DeleteOptions) AsDeleteOptions

func (o *DeleteOptions) AsDeleteOptions() *metav1.DeleteOptions

AsDeleteOptions returns these options as a metav1.DeleteOptions. This may mutate the Raw field.

type FieldOwner

type FieldOwner string

FieldOwner set the field manager name for the given server-side apply patch.

func (FieldOwner) ApplyToCreate

func (f FieldOwner) ApplyToCreate(opts *CreateOptions)

ApplyToCreate applies this configuration to the given create options.

func (FieldOwner) ApplyToPatch

func (f FieldOwner) ApplyToPatch(opts *PatchOptions)

ApplyToPatch applies this configuration to the given patch options.

func (FieldOwner) ApplyToUpdate

func (f FieldOwner) ApplyToUpdate(opts *UpdateOptions)

ApplyToUpdate applies this configuration to the given update options.

type GetOption

type GetOption interface {
	// ApplyToGet applies this configuration to the given get options.
	ApplyToGet(*GetOptions)
}

GetOption is some configuration that modifies options for a get request.

type GetOptions

type GetOptions struct {

	// Namespace represents the namespace to list for, or empty for
	// non-namespaced objects, or to list across all namespaces.
	Namespace string

	// URLOption overwrites an GVK based API URL.
	URLOption *URLOptions

	// Workspace represents the workspace that get object for.
	Workspace *WorkspaceOptions
}

ListOptions contains options for limiting or filtering results. It's generally a subset of metav1.ListOptions, with support for pre-parsed selectors (since generally, selectors will be executed against the cache).

func (*GetOptions) ApplyOptions

func (o *GetOptions) ApplyOptions(opts []GetOption) *GetOptions

ApplyOptions applies the given list options on these options, and then returns itself (for convenient chaining).

func (*GetOptions) ApplyToGet

func (o *GetOptions) ApplyToGet(lo *GetOptions)

ApplyToList implements ListOption for ListOptions

type GracePeriodSeconds

type GracePeriodSeconds int64

GracePeriodSeconds sets the grace period for the deletion to the given number of seconds.

func (GracePeriodSeconds) ApplyToDelete

func (s GracePeriodSeconds) ApplyToDelete(opts *DeleteOptions)

ApplyToDelete applies this configuration to the given delete options.

func (GracePeriodSeconds) ApplyToDeleteAllOf

func (s GracePeriodSeconds) ApplyToDeleteAllOf(opts *DeleteAllOfOptions)

ApplyToDeleteAllOf applies this configuration to the given an List options.

type HasLabels

type HasLabels []string

HasLabels filters the list/delete operation checking if the set of labels exists without checking their values.

func (HasLabels) ApplyToDeleteAllOf

func (m HasLabels) ApplyToDeleteAllOf(opts *DeleteAllOfOptions)

ApplyToDeleteAllOf applies this configuration to the given an List options.

func (HasLabels) ApplyToList

func (m HasLabels) ApplyToList(opts *ListOptions)

ApplyToList applies this configuration to the given list options.

type InNamespace

type InNamespace string

InNamespace restricts the list/delete operation to the given namespace.

func (InNamespace) ApplyToDeleteAllOf

func (n InNamespace) ApplyToDeleteAllOf(opts *DeleteAllOfOptions)

ApplyToDeleteAllOf applies this configuration to the given an List options.

func (InNamespace) ApplyToList

func (n InNamespace) ApplyToList(opts *ListOptions)

ApplyToList applies this configuration to the given list options.

type Limit

type Limit int64

Limit specifies the maximum number of results to return from the server. Limit does not implement DeleteAllOfOption interface because the server does not support setting it for deletecollection operations.

func (Limit) ApplyToList

func (l Limit) ApplyToList(opts *ListOptions)

ApplyToList applies this configuration to the given an list options.

type ListOption

type ListOption interface {
	// ApplyToList applies this configuration to the given list options.
	ApplyToList(*ListOptions)
}

ListOption is some configuration that modifies options for a list request.

type ListOptions

type ListOptions struct {
	// LabelSelector filters results by label.  Use SetLabelSelector to
	// set from raw string form.
	LabelSelector labels.Selector
	// FieldSelector filters results by a particular field.  In order
	// to use this with cache-based implementations, restrict usage to
	// a single field-value pair that's been added to the indexers.
	FieldSelector fields.Selector

	// Namespace represents the namespace to list for, or empty for
	// non-namespaced objects, or to list across all namespaces.
	Namespace string

	// Limit specifies the maximum number of results to return from the server. The server may
	// not support this field on all resource types, but if it does and more results remain it
	// will set the continue field on the returned list object. This field is not supported if watch
	// is true in the Raw ListOptions.
	Limit int64
	// Continue is a token returned by the server that lets a client retrieve chunks of results
	// from the server by specifying limit. The server may reject requests for continuation tokens
	// it does not recognize and will return a 410 error if the token can no longer be used because
	// it has expired. This field is not supported if watch is true in the Raw ListOptions.
	Continue string

	// Raw represents raw ListOptions, as passed to the API server.  Note
	// that these may not be respected by all implementations of interface,
	// and the LabelSelector, FieldSelector, Limit and Continue fields are ignored.
	Raw *metav1.ListOptions

	// URLOption overwrites an GVK based API URL.
	URLOption *URLOptions

	// Workspace represents the workspace to list for.
	Workspace *WorkspaceOptions
}

ListOptions contains options for limiting or filtering results. It's generally a subset of metav1.ListOptions, with support for pre-parsed selectors (since generally, selectors will be executed against the cache).

func (*ListOptions) ApplyOptions

func (o *ListOptions) ApplyOptions(opts []ListOption) *ListOptions

ApplyOptions applies the given list options on these options, and then returns itself (for convenient chaining).

func (*ListOptions) ApplyToList

func (o *ListOptions) ApplyToList(lo *ListOptions)

ApplyToList implements ListOption for ListOptions

func (*ListOptions) AsListOptions

func (o *ListOptions) AsListOptions() *metav1.ListOptions

AsListOptions returns these options as a flattened metav1.ListOptions. This may mutate the Raw field.

type MatchingFields

type MatchingFields fields.Set

MatchingFields filters the list/delete operation on the given field Set (or index in the case of cached lists).

func MatchingField deprecated

func MatchingField(name, val string) MatchingFields

MatchingField filters the list operation on the given field selector (or index in the case of cached lists).

Deprecated: Use MatchingFields

func (MatchingFields) ApplyToDeleteAllOf

func (m MatchingFields) ApplyToDeleteAllOf(opts *DeleteAllOfOptions)

ApplyToDeleteAllOf applies this configuration to the given an List options.

func (MatchingFields) ApplyToList

func (m MatchingFields) ApplyToList(opts *ListOptions)

ApplyToList applies this configuration to the given list options.

type MatchingFieldsSelector

type MatchingFieldsSelector struct {
	fields.Selector
}

MatchingFieldsSelector filters the list/delete operation on the given field selector (or index in the case of cached lists). A struct is used because fields.Selector is an interface, which cannot be aliased.

func (MatchingFieldsSelector) ApplyToDeleteAllOf

func (m MatchingFieldsSelector) ApplyToDeleteAllOf(opts *DeleteAllOfOptions)

ApplyToDeleteAllOf applies this configuration to the given an List options.

func (MatchingFieldsSelector) ApplyToList

func (m MatchingFieldsSelector) ApplyToList(opts *ListOptions)

ApplyToList applies this configuration to the given list options.

type MatchingLabels

type MatchingLabels map[string]string

MatchingLabels filters the list/delete operation on the given set of labels.

func (MatchingLabels) ApplyToDeleteAllOf

func (m MatchingLabels) ApplyToDeleteAllOf(opts *DeleteAllOfOptions)

ApplyToDeleteAllOf applies this configuration to the given an List options.

func (MatchingLabels) ApplyToList

func (m MatchingLabels) ApplyToList(opts *ListOptions)

ApplyToList applies this configuration to the given list options.

type MatchingLabelsSelector

type MatchingLabelsSelector struct {
	labels.Selector
}

MatchingLabelsSelector filters the list/delete operation on the given label selector (or index in the case of cached lists). A struct is used because labels.Selector is an interface, which cannot be aliased.

func (MatchingLabelsSelector) ApplyToDeleteAllOf

func (m MatchingLabelsSelector) ApplyToDeleteAllOf(opts *DeleteAllOfOptions)

ApplyToDeleteAllOf applies this configuration to the given an List options.

func (MatchingLabelsSelector) ApplyToList

func (m MatchingLabelsSelector) ApplyToList(opts *ListOptions)

ApplyToList applies this configuration to the given list options.

type NoConversionParamCodec

type NoConversionParamCodec struct{}

NoConversionParamCodec is a no-conversion codec for serializing parameters into URL query strings. it's useful in scenarios with the unstructured client and arbitrary resouces.

func (NoConversionParamCodec) DecodeParameters

func (NoConversionParamCodec) DecodeParameters(parameters url.Values, from schema.GroupVersion, into runtime.Object) error

func (NoConversionParamCodec) EncodeParameters

func (NoConversionParamCodec) EncodeParameters(obj runtime.Object, to schema.GroupVersion) (url.Values, error)

type ObjMeta

type ObjMeta struct {
	// ResourceMeta contains type information for the object
	*ResourceMeta

	// Object contains meta data for the object instance
	metav1.Object
}

ObjMeta stores type and object information about a Kubernetes type

type ObjectKey

type ObjectKey = types.NamespacedName

ObjectKey identifies a Kubernetes Object.

func ObjectKeyFromObject

func ObjectKeyFromObject(obj runtime.Object) (ObjectKey, error)

ObjectKeyFromObject returns the ObjectKey given a runtime.Object

type Options

type Options struct {
	// Scheme, if provided, will be used to map go structs to GroupVersionKinds
	Scheme *runtime.Scheme

	// Mapper, if provided, will be used to map GroupVersionKinds to Resources
	Mapper meta.RESTMapper
}

Options are creation options for a Client

type Patch

type Patch interface {
	// Type is the PatchType of the patch.
	Type() types.PatchType
	// Data is the raw data representing the patch.
	Data(obj runtime.Object) ([]byte, error)
}

Patch is a patch that can be applied to a Kubernetes object.

type PatchOption

type PatchOption interface {
	// ApplyToPatch applies this configuration to the given patch options.
	ApplyToPatch(*PatchOptions)
}

PatchOption is some configuration that modifies options for a patch request.

type PatchOptions

type PatchOptions struct {
	// When present, indicates that modifications should not be
	// persisted. An invalid or unrecognized dryRun directive will
	// result in an error response and no further processing of the
	// request. Valid values are:
	// - All: all dry run stages will be processed
	DryRun []string

	// Force is going to "force" Apply requests. It means user will
	// re-acquire conflicting fields owned by other people. Force
	// flag must be unset for non-apply patch requests.
	// +optional
	Force *bool

	// FieldManager is the name of the user or component submitting
	// this request.  It must be set with server-side apply.
	FieldManager string

	// Raw represents raw PatchOptions, as passed to the API server.
	Raw *metav1.PatchOptions

	// URLOption overwrites an GVK based API URL.
	URLOption *URLOptions

	// Workspace represents the workspace for object that patching.
	Workspace *WorkspaceOptions
}

PatchOptions contains options for patch requests.

func (*PatchOptions) ApplyOptions

func (o *PatchOptions) ApplyOptions(opts []PatchOption) *PatchOptions

ApplyOptions applies the given patch options on these options, and then returns itself (for convenient chaining).

func (*PatchOptions) ApplyToPatch

func (o *PatchOptions) ApplyToPatch(po *PatchOptions)

ApplyToPatch implements PatchOptions

func (*PatchOptions) AsPatchOptions

func (o *PatchOptions) AsPatchOptions() *metav1.PatchOptions

AsPatchOptions returns these options as a metav1.PatchOptions. This may mutate the Raw field.

type Preconditions

type Preconditions metav1.Preconditions

Preconditions must be fulfilled before an operation (update, delete, etc.) is carried out.

func (Preconditions) ApplyToDelete

func (p Preconditions) ApplyToDelete(opts *DeleteOptions)

ApplyToDelete applies this configuration to the given delete options.

func (Preconditions) ApplyToDeleteAllOf

func (p Preconditions) ApplyToDeleteAllOf(opts *DeleteAllOfOptions)

ApplyToDeleteAllOf applies this configuration to the given an List options.

type PropagationPolicy

type PropagationPolicy metav1.DeletionPropagation

PropagationPolicy determined whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy. Acceptable values are: 'Orphan' - orphan the dependents; 'Background' - allow the garbage collector to delete the dependents in the background; 'Foreground' - a cascading policy that deletes all dependents in the foreground.

func (PropagationPolicy) ApplyToDelete

func (p PropagationPolicy) ApplyToDelete(opts *DeleteOptions)

ApplyToDelete applies the given delete options on these options. It will propagate to the dependents of the object to let the garbage collector handle it.

func (PropagationPolicy) ApplyToDeleteAllOf

func (p PropagationPolicy) ApplyToDeleteAllOf(opts *DeleteAllOfOptions)

ApplyToDeleteAllOf applies this configuration to the given an List options.

type Reader

type Reader interface {
	// Get retrieves an obj for the given object key from the Kubernetes Cluster.
	// obj must be a struct pointer so that obj can be updated with the response
	// returned by the Server.
	Get(ctx context.Context, key ObjectKey, obj runtime.Object, opts ...GetOption) error

	// List retrieves list of objects for a given namespace and list options. On a
	// successful call, Items field in the list will be populated with the
	// result returned from the server.
	List(ctx context.Context, list runtime.Object, opts ...ListOption) error
}

Reader knows how to read and list Kubernetes objects.

type ResourceMeta

type ResourceMeta struct {
	// client is the rest client used to talk to the apiserver
	rest.Interface
	// contains filtered or unexported fields
}

ResourceMeta caches state for a Kubernetes type.

func (*ResourceMeta) IsNamespaced

func (r *ResourceMeta) IsNamespaced() bool

IsNamespaced returns true if the type is namespaced

func (*ResourceMeta) Resource

func (r *ResourceMeta) Resource() string

resource returns the resource name of the type

type StatusClient

type StatusClient interface {
	Status() StatusWriter
}

StatusClient knows how to create a client which can update status subresource for kubernetes objects.

type StatusWriter

type StatusWriter interface {
	// Update updates the fields corresponding to the status subresource for the
	// given obj. obj must be a struct pointer so that obj can be updated
	// with the content returned by the Server.
	Update(ctx context.Context, obj runtime.Object, opts ...UpdateOption) error

	// Patch patches the given object's subresource. obj must be a struct
	// pointer so that obj can be updated with the content returned by the
	// Server.
	Patch(ctx context.Context, obj runtime.Object, patch Patch, opts ...PatchOption) error
}

StatusWriter knows how to update status subresource of a Kubernetes object.

type URLOptions

type URLOptions struct {
	Group   string
	Version string
	//AbsPath overwrites all of other url options with the url provided.
	AbsPath string
}

func (*URLOptions) ApplyToCreate

func (m *URLOptions) ApplyToCreate(opts *CreateOptions)

ApplyToCreate applies this configuration to the given create options.

func (*URLOptions) ApplyToDelete

func (m *URLOptions) ApplyToDelete(opts *DeleteOptions)

ApplyToGet applies this configuration to the given get options.

func (*URLOptions) ApplyToGet

func (m *URLOptions) ApplyToGet(opts *GetOptions)

ApplyToGet applies this configuration to the given get options.

func (*URLOptions) ApplyToList

func (m *URLOptions) ApplyToList(opts *ListOptions)

ApplyToList applies this configuration to the given list options.

func (*URLOptions) URL

func (w *URLOptions) URL() []string

type UpdateOption

type UpdateOption interface {
	// ApplyToUpdate applies this configuration to the given update options.
	ApplyToUpdate(*UpdateOptions)
}

UpdateOption is some configuration that modifies options for a update request.

type UpdateOptions

type UpdateOptions struct {
	// When present, indicates that modifications should not be
	// persisted. An invalid or unrecognized dryRun directive will
	// result in an error response and no further processing of the
	// request. Valid values are:
	// - All: all dry run stages will be processed
	DryRun []string

	// FieldManager is the name of the user or component submitting
	// this request.  It must be set with server-side apply.
	FieldManager string

	// Raw represents raw UpdateOptions, as passed to the API server.
	Raw *metav1.UpdateOptions

	// URLOption overwrites an GVK based API URL.
	URLOption *URLOptions

	// Workspace represents the workspace for object that updating.
	Workspace *WorkspaceOptions
}

UpdateOptions contains options for create requests. It's generally a subset of metav1.UpdateOptions.

func (*UpdateOptions) ApplyOptions

func (o *UpdateOptions) ApplyOptions(opts []UpdateOption) *UpdateOptions

ApplyOptions applies the given update options on these options, and then returns itself (for convenient chaining).

func (*UpdateOptions) ApplyToUpdate

func (o *UpdateOptions) ApplyToUpdate(uo *UpdateOptions)

ApplyToUpdate implements UpdateOption

func (*UpdateOptions) AsUpdateOptions

func (o *UpdateOptions) AsUpdateOptions() *metav1.UpdateOptions

AsUpdateOptions returns these options as a metav1.UpdateOptions. This may mutate the Raw field.

type WorkspaceOptions

type WorkspaceOptions struct {
	Name string
}

{{{ WorkSpace Options

func (*WorkspaceOptions) ApplyToCreate

func (w *WorkspaceOptions) ApplyToCreate(opts *CreateOptions)

ApplyToCreate applies this configuration to the given create options.

func (*WorkspaceOptions) ApplyToDelete

func (w *WorkspaceOptions) ApplyToDelete(opts *DeleteOptions)

ApplyToGet applies this configuration to the given get options.

func (*WorkspaceOptions) ApplyToGet

func (w *WorkspaceOptions) ApplyToGet(opts *GetOptions)

ApplyToGet applies this configuration to the given get options.

func (*WorkspaceOptions) ApplyToList

func (w *WorkspaceOptions) ApplyToList(opts *ListOptions)

ApplyToList applies this configuration to the given list options.

type Writer

type Writer interface {
	// Create saves the object obj in the Kubernetes cluster.
	Create(ctx context.Context, obj runtime.Object, opts ...CreateOption) error

	// Delete deletes the given obj from Kubernetes cluster.
	Delete(ctx context.Context, obj runtime.Object, opts ...DeleteOption) error

	// Update updates the given obj in the Kubernetes cluster. obj must be a
	// struct pointer so that obj can be updated with the content returned by the Server.
	Update(ctx context.Context, obj runtime.Object, opts ...UpdateOption) error

	// Patch patches the given obj in the Kubernetes cluster. obj must be a
	// struct pointer so that obj can be updated with the content returned by the Server.
	Patch(ctx context.Context, obj runtime.Object, patch Patch, opts ...PatchOption) error

	// DeleteAllOf deletes all objects of the given type matching the given options.
	DeleteAllOf(ctx context.Context, obj runtime.Object, opts ...DeleteAllOfOption) error
}

Writer knows how to create, delete, and update Kubernetes objects.

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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