taskrunmetrics

package
v0.26.12 Latest Latest
Warning

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

Go to latest
Published: Nov 16, 2026 License: Apache-2.0 Imports: 10 Imported by: 1 module, 0 packages

The first number is the count of modules that contain a package that imports this one. The module count is a better indicator of popularity than the package count. A module with 100 importing packages is counted only once instead of 100 times, reflecting the fact that the choice to use the package was likely made only once, not 100 times.
A '?' means that the value hasn't been computed yet.

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func WithClient

func WithClient(ctx context.Context) context.Context

WithClient adds a metrics recorder to the given context

Types

type Recorder

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

Recorder is used to actually record TaskRun metrics.

func Get

func Get(ctx context.Context) *Recorder

Get extracts the taskrunmetrics.Recorder from the context.

func NewRecorder

func NewRecorder(ctx context.Context) (*Recorder, error)

NewRecorder creates a new metrics recorder instance to log the TaskRun related metrics.

func (*Recorder) RecordCountMetrics

func (r *Recorder) RecordCountMetrics(ctx context.Context, metricType common.Metric)

RecordCountMetrics implements github.com/tektoncd/chains/pkg/metrics.Recorder.RecordCountMetrics

func (*Recorder) RecordErrorMetric added in v0.26.0

func (r *Recorder) RecordErrorMetric(ctx context.Context, errType common.MetricErrorType)

RecordErrorMetric records a TaskRun signing failure with a given error type tag.

type RecorderKey

type RecorderKey struct{}

RecorderKey is used for associating the Recorder inside the context.Context.

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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