prometheusremotewrite

package module
v0.99.0 Latest Latest
Warning

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

Go to latest
Published: Apr 22, 2024 License: Apache-2.0 Imports: 20 Imported by: 1

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func FromMetrics added in v0.45.0

func FromMetrics(md pmetric.Metrics, settings Settings) (map[string]*prompb.TimeSeries, error)

FromMetrics converts pmetric.Metrics to Prometheus remote write format.

func OtelMetricsToMetadata added in v0.90.0

func OtelMetricsToMetadata(md pmetric.Metrics, addMetricSuffixes bool) []*prompb.MetricMetadata

Types

type ByLabelName

type ByLabelName []prompb.Label

ByLabelName enables the usage of sort.Sort() with a slice of labels

func (ByLabelName) Len

func (a ByLabelName) Len() int

func (ByLabelName) Less

func (a ByLabelName) Less(i, j int) bool

func (ByLabelName) Swap

func (a ByLabelName) Swap(i, j int)

type Settings added in v0.45.0

type Settings struct {
	Namespace           string
	ExternalLabels      map[string]string
	DisableTargetInfo   bool
	ExportCreatedMetric bool
	AddMetricSuffixes   bool
	SendMetadata        bool
}

Jump to

Keyboard shortcuts

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