extlabels

package
v0.2.1 Latest Latest
Warning

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

Go to latest
Published: Dec 16, 2025 License: Apache-2.0 Imports: 3 Imported by: 0

Documentation

Index

Constants

View Source
const (
	MetricType = "__type__"
	MetricUnit = "__unit__"
)

Variables

View Source
var (
	ErrDuplicateLabelSet = errors.New("vector cannot contain metrics with the same labelset")
)

Functions

func DropBucketLabel

func DropBucketLabel(l labels.Labels, b labels.ScratchBuilder) (labels.Labels, labels.Label)

DropBucketLabel removes the le label and returns the dropped name and remaining labels.

func DropLabel

DropLabel removes the label with name from l and returns the dropped label.

func DropLabels

func DropLabels(l labels.Labels, shouldDrop func(name string) bool, b labels.ScratchBuilder) labels.Labels

DropLabels removes labels from l based on the shouldDrop function and returns the remaining labels.

func DropReserved

func DropReserved(l labels.Labels, b labels.ScratchBuilder) labels.Labels

DropReserved removes all reserved labels (__name__, __type__, __unit__) and returns the remaining labels.

Types

This section is empty.

Jump to

Keyboard shortcuts

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