conventions

package
v0.12.1-0...-6bdb67e Latest Latest
Warning

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

Go to latest
Published: Apr 14, 2025 License: Apache-2.0 Imports: 4 Imported by: 0

Documentation

Index

Constants

View Source
const (
	// Metrics.
	PromSLIErrorMetricFmt = "slo:sli_error:ratio_rate%s"

	// Labels.
	PromSLONameLabelName      = "sloth_slo"
	PromSLOIDLabelName        = "sloth_id"
	PromSLOServiceLabelName   = "sloth_service"
	PromSLOWindowLabelName    = "sloth_window"
	PromSLOSeverityLabelName  = "sloth_severity"
	PromSLOVersionLabelName   = "sloth_version"
	PromSLOModeLabelName      = "sloth_mode"
	PromSLOSpecLabelName      = "sloth_spec"
	PromSLOObjectiveLabelName = "sloth_objective"
)

Prometheus metrics conventions.

Variables

This section is empty.

Functions

func GetSLIErrorMetric

func GetSLIErrorMetric(window time.Duration) string

GetSLIErrorMetric returns the SLI error Prometheus metric name.

func GetSLOIDPromLabels

func GetSLOIDPromLabels(s model.PromSLO) map[string]string

GetSLOIDPromLabels returns the ID labels of an SLO, these can be used to identify an SLO recorded metrics and alerts.

Types

This section is empty.

Jump to

Keyboard shortcuts

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