metrics

package module
v1.17.0 Latest Latest
Warning

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

Go to latest
Published: Nov 29, 2023 License: MIT Imports: 17 Imported by: 1

Documentation

Index

Constants

View Source
const (
	UNKNOWN_EXPORTER       MetricExporterType = 0
	OTLP_GRPC_TLS_EXPORTER MetricExporterType = 1
	OTLP_GRPC_EXPORTER     MetricExporterType = 2
	PROMETHEUS_EXPORTER    MetricExporterType = 3

	OTLP_GZIP_COMPRESSIONS OTLPCompression = "gzip"
)

Variables

This section is empty.

Functions

func Message

func Message(msg string) string

Types

type Headers

type Headers map[string]string

type MetricExporterType

type MetricExporterType int32

type OTLPCompression

type OTLPCompression string

type OTLPMetrics added in v1.17.0

type OTLPMetrics interface {
	WithApiKeyHeader() OTLPMetrics
	AddHeader(key, value string) OTLPMetrics
	WithHeaders(headers Headers) OTLPMetrics
	Endpoint(s string) OTLPMetrics
	WithTimeout(t time.Duration) OTLPMetrics
	WithReconnection(t time.Duration) OTLPMetrics
	WithCompression(c OTLPCompression) OTLPMetrics
	Provider() (shutdown func(context.Context) error, err error)
}

func NewOTLPBuilder added in v1.12.0

func NewOTLPBuilder(cfg *configs.Configs, logger logging.Logger) OTLPMetrics

type PrometheusMetrics added in v1.17.0

type PrometheusMetrics interface {
	HTTPHandler() http.Handler
	Provider() (shutdown func(context.Context) error, err error)
}

func NewPrometheus

func NewPrometheus(cfg *configs.Configs, logger logging.Logger) PrometheusMetrics

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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