storage

package
v1.9.0-industry.1 Latest Latest
Warning

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

Go to latest
Published: Nov 16, 2022 License: Apache-2.0, BSD-2-Clause, BSD-3-Clause, + 8 more Imports: 16 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func ValidateGetObjectAndTenantID

func ValidateGetObjectAndTenantID(ctx context.Context, store *registry.Store, name string, options *metav1.GetOptions) (runtime.Object, error)

ValidateGetObjectAndTenantID validate name and tenantID, if success return NsEmigration

Types

type REST

type REST struct {
	*registry.Store
	// contains filtered or unexported fields
}

REST implements a RESTStorage for emigration sets against etcd.

func (*REST) Delete

func (r *REST) Delete(ctx context.Context, name string, deleteValidation rest.ValidateObjectFunc,
	options *metav1.DeleteOptions) (runtime.Object, bool, error)

Delete enforces life-cycle rules for emigration termination

func (*REST) DeleteCollection

func (r *REST) DeleteCollection(ctx context.Context, deleteValidation rest.ValidateObjectFunc,
	options *metav1.DeleteOptions, listOptions *metainternal.ListOptions) (runtime.Object, error)

DeleteCollection selects all resources in the storage matching given 'listOptions' and deletes them.

func (*REST) Get

func (r *REST) Get(ctx context.Context, name string, options *metav1.GetOptions) (runtime.Object, error)

Get retrieves the object from the storage. It is required to support Patch.

func (*REST) List

func (r *REST) List(ctx context.Context, options *metainternal.ListOptions) (runtime.Object, error)

List selects resources in the storage which match to the selector. 'options' can be nil.

func (*REST) ShortNames

func (r *REST) ShortNames() []string

ShortNames implements the ShortNamesProvider interface. Returns a list of short names for a resource.

func (*REST) Update

func (r *REST) Update(ctx context.Context, name string, objInfo rest.UpdatedObjectInfo,
	createValidation rest.ValidateObjectFunc, updateValidation rest.ValidateObjectUpdateFunc,
	forceAllowCreate bool, options *metav1.UpdateOptions) (runtime.Object, bool, error)

Update alters the object subset of an object.

type Storage

type Storage struct {
	Emigration *REST
}

Storage includes storage for emigration and all sub resources.

func NewStorage

func NewStorage(optsGetter genericregistry.RESTOptionsGetter, businessClient *businessinternalclient.BusinessClient,
	platformClient platformversionedclient.PlatformV1Interface, privilegedUsername string) *Storage

NewStorage returns a Storage object that will work against emigration sets.

Jump to

Keyboard shortcuts

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