taskrun

package
v0.3.5 Latest Latest
Warning

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

Go to latest
Published: Jan 5, 2026 License: Apache-2.0 Imports: 24 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func NewController

func NewController(ctx context.Context, cmw configmap.Watcher) *controller.Impl

NewController creates a Reconciler and returns the result of NewImpl.

Types

type Reconciler

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

Reconciler implements simpledeploymentreconciler.Interface for SimpleDeployment resources.

func (*Reconciler) ReconcileKind

func (r *Reconciler) ReconcileKind(ctx context.Context, tr *pipelinev1.TaskRun) reconciler.Event

ReconcileKind implements Interface.ReconcileKind.

type TrFuncs

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

TrFuncs provides methods for working with TaskRun resources it contains a client to interact with the pipeline API and manage TaskRuns

func NewTrFuncs

func NewTrFuncs(client pipelineversioned.Interface) *TrFuncs

NewTrFuncs creates a new instance of TrFuncs with the provided pipeline client. This client is used to interact with the Tekton pipeline API.

func (*TrFuncs) Delete

func (trf *TrFuncs) Delete(ctx context.Context, namespace, name string) error

Delete removes a specific TaskRun by name in the given namespace.

func (*TrFuncs) Get

func (trf *TrFuncs) Get(ctx context.Context, namespace, name string) (metav1.Object, error)

Get retrieves a specific TaskRun by name in the given namespace.

func (*TrFuncs) GetCompletionTime

func (trf *TrFuncs) GetCompletionTime(resource metav1.Object) (metav1.Time, error)

GetCompletionTime retrieves the completion time of a TaskRun resource.

func (*TrFuncs) GetDefaultLabelKey

func (trf *TrFuncs) GetDefaultLabelKey() string

GetDefaultLabelKey returns the default label key for TaskRun resources.

func (*TrFuncs) GetEnforcedConfigLevel

func (trf *TrFuncs) GetEnforcedConfigLevel(namespace, name string, selectors config.SelectorSpec) config.EnforcedConfigLevel

GetEnforcedConfigLevel retrieves the enforced config level for a TaskRun.

func (*TrFuncs) GetFailedHistoryLimitCount

func (trf *TrFuncs) GetFailedHistoryLimitCount(namespace, name string, selectors config.SelectorSpec) (*int32, string)

GetFailedHistoryLimitCount retrieves the failed history limit count for a TaskRun.

func (*TrFuncs) GetMatchingSelector added in v0.3.5

func (trf *TrFuncs) GetMatchingSelector(namespace, name string, selectors config.SelectorSpec) *config.SelectorSpec

GetMatchingSelector returns the ConfigMap's selector that matches a TaskRun.

func (*TrFuncs) GetSuccessHistoryLimitCount

func (trf *TrFuncs) GetSuccessHistoryLimitCount(namespace, name string, selectors config.SelectorSpec) (*int32, string)

GetSuccessHistoryLimitCount retrieves the success history limit count for a TaskRun.

func (*TrFuncs) GetTTLSecondsAfterFinished

func (trf *TrFuncs) GetTTLSecondsAfterFinished(namespace, taskName string, selectors config.SelectorSpec) (*int32, string)

GetTTLSecondsAfterFinished retrieves the TTL (time-to-live) in seconds after a TaskRun finishes.

func (*TrFuncs) Ignore

func (trf *TrFuncs) Ignore(resource metav1.Object) bool

Ignore returns true if the resource should be ignored based on labels and annotations.

func (*TrFuncs) IsCompleted

func (trf *TrFuncs) IsCompleted(resource metav1.Object) bool

IsCompleted checks if the TaskRun resource has completed.

func (*TrFuncs) IsFailed

func (trf *TrFuncs) IsFailed(resource metav1.Object) bool

IsFailed checks if the TaskRun resource has failed.

func (*TrFuncs) IsSuccessful

func (trf *TrFuncs) IsSuccessful(resource metav1.Object) bool

IsSuccessful checks if the TaskRun resource has successfully completed.

func (*TrFuncs) List

func (trf *TrFuncs) List(ctx context.Context, namespace, labelSelector string) ([]metav1.Object, error)

List returns a list of TaskRuns in a given namespace with a label selector.

func (*TrFuncs) ListByAnnotations

func (trf *TrFuncs) ListByAnnotations(ctx context.Context, namespace string, annotations map[string]string) ([]metav1.Object, error)

ListByAnnotations returns a list of TaskRuns in a given namespace filtered by annotations.

func (*TrFuncs) ListByLabels

func (trf *TrFuncs) ListByLabels(ctx context.Context, namespace string, labels map[string]string) ([]metav1.Object, error)

ListByLabels returns a list of TaskRuns in a given namespace filtered by multiple labels.

func (*TrFuncs) ListByNamespaces

func (trf *TrFuncs) ListByNamespaces(ctx context.Context, namespaces []string) (map[string][]metav1.Object, error)

ListByNamespaces returns a list of TaskRuns across multiple namespaces.

func (*TrFuncs) Patch

func (trf *TrFuncs) Patch(ctx context.Context, namespace, name string, patchBytes []byte) error

Patch modifies an existing TaskRun resource using a JSON patch. This is useful for updating only specific fields of the resource.

func (*TrFuncs) Type

func (trf *TrFuncs) Type() string

Type returns the kind of resource represented by the TaskRunFuncs struct, which is "TaskRun".

func (*TrFuncs) Update

func (trf *TrFuncs) Update(ctx context.Context, resource metav1.Object) error

Update modifies an existing TaskRun resource.

Jump to

Keyboard shortcuts

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