metrics

package
v0.13.1 Latest Latest
Warning

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

Go to latest
Published: Jul 14, 2026 License: Apache-2.0 Imports: 15 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Start

func Start(m *http.ServeMux, resource *resource.Resource, opts ...Option) error

Start metrics collection and exporting.

func Stop

func Stop()

Stop metrics collection and exporting.

Types

type Option added in v0.8.0

type Option func() error

func WithExporter added in v0.12.0

func WithExporter(v string) Option

WithExporter sets the type of metrics exporter to use.

func WithMetrics added in v0.8.0

func WithMetrics(cfg *config.Config) Option

WithMetrics sets the enabled and metrics.

func WithNamespace added in v0.8.0

func WithNamespace(v string) Option

WithNamespace sets a common namespace (prefix) for all metrics.

func WithReportPeriod added in v0.8.0

func WithReportPeriod(v time.Duration) Option

WithReportPeriod sets the reporting period for periodic metric exporters (otlp-http and otlp-grpc).

Jump to

Keyboard shortcuts

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