task

package
v4.0.0-alpha.5 Latest Latest
Warning

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

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

Documentation

Index

Constants

This section is empty.

Variables

View Source
var Strategy = taskStrategy{_const.Scheme, apinames.SimpleNameGenerator}

Strategy is the default logic that applies when creating and updating Pod objects via the REST API.

Functions

func GetAttrs

func GetAttrs(obj runtime.Object) (labels.Set, fields.Set, error)

GetAttrs returns labels and fields of a given object for filtering purposes.

func Indexers

func Indexers() *cgtoolscache.Indexers

Indexers returns the indexers for pod storage.

func MatchTask

MatchTask returns a generic matcher for a given label and field selector.

func OwnerPipelineIndexFunc

func OwnerPipelineIndexFunc(obj any) ([]string, error)

OwnerPipelineIndexFunc return value ownerReference.object is pipeline.

func OwnerPipelineTriggerFunc

func OwnerPipelineTriggerFunc(obj runtime.Object) string

OwnerPipelineTriggerFunc returns value ownerReference is pipeline of given object.

func ToSelectableFields

func ToSelectableFields(task *kkcorev1alpha1.Task) fields.Set

ToSelectableFields returns a field set that represents the object

Types

type REST

type REST struct {
	*apiregistry.Store
}

REST resource for Task

type StatusREST

type StatusREST struct {
	// contains filtered or unexported fields
}

StatusREST status subresource for Task

func (*StatusREST) ConvertToTable

func (r *StatusREST) ConvertToTable(ctx context.Context, object runtime.Object, tableOptions runtime.Object) (*metav1.Table, error)

ConvertToTable print table view

func (*StatusREST) Destroy

func (r *StatusREST) Destroy()

Destroy cleans up resources on shutdown.

func (*StatusREST) Get

func (r *StatusREST) 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 (*StatusREST) GetResetFields

func (r *StatusREST) GetResetFields() map[fieldpath.APIVersion]*fieldpath.Set

GetResetFields implements rest.ResetFieldsStrategy

func (*StatusREST) NamespaceScoped

func (r *StatusREST) NamespaceScoped() bool

NamespaceScoped is true for Task

func (*StatusREST) New

func (r *StatusREST) New() runtime.Object

New creates a new Node object.

func (*StatusREST) Update

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

Update alters the status subset of an object.

type TaskStorage

type TaskStorage struct {
	Task       *REST
	TaskStatus *StatusREST
}

TaskStorage storage for Task

func NewStorage

func NewStorage(optsGetter apigeneric.RESTOptionsGetter) (TaskStorage, error)

NewStorage for Task storage

Jump to

Keyboard shortcuts

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