metric

package
v0.0.0-...-9eed78a Latest Latest
Warning

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

Go to latest
Published: Jul 23, 2024 License: MIT Imports: 5 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	Namespace = "dodo"
	Subsystem = "go"
)

prometheus related param

View Source
var CounterVec = &counter{m: newMetric(cv)}

CounterVec is promteheus counterVec

View Source
var GaugeVec = &gauge{m: newMetric(gv)}

GaugeVec is promteheus gaugeVec

View Source
var HistogramVec = &histogram{m: newMetric(hv)}

HistogramVec is promteheus histogramVec

View Source
var SummaryVec = &summary{m: newMetric(sv)}

SummaryVec is promteheus summaryVec

Functions

func AddConstLabels

func AddConstLabels(name string, value string)

AddConstLabels add const kv into promethues

func AddHistogramBucket

func AddHistogramBucket(name string, buckets []float64)

AddHistogramBucket config histogramBuckets, it's not thread safe, should initialize first it will append +Inf as last element if not exist

func AddMetricDescription

func AddMetricDescription(name string, desc string)

AddMetricDescription add metric desc, it's not thread safe, should initialize first

func RetLabel

func RetLabel(err error) string

RetLabel RetLabel

Types

This section is empty.

Jump to

Keyboard shortcuts

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