metricsutils

package
v0.34.0-rc.2 Latest Latest
Warning

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

Go to latest
Published: Jun 6, 2023 License: Apache-2.0 Imports: 16 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func BoolToString added in v0.25.0

func BoolToString(b bool) string

BoolToString is a helper for converting boolean values to a Prometheus labels-compatible string.

func NewMetricsHandlerIntegration

func NewMetricsHandlerIntegration(
	_ log.Logger,
	c integrations.Config,
	mc common.MetricsConfig,
	globals integrations.Globals,
	h http.Handler,
) (integrations.MetricsIntegration, error)

NewMetricsHandlerIntegration returns a integrations.MetricsIntegration which will expose a /metrics endpoint for h.

func NewNamedShim added in v0.22.9

func NewNamedShim(newName string) v2.UpgradeFunc

NewNamedShim returns a v2.UpgradeFunc which will upgrade a v1.Config to a v2.Config with a new name.

func Shim added in v0.22.9

func Shim(before v1.Config, common common.MetricsConfig) (after v2.UpgradedConfig)

Shim upgrades a v1.Config to a v2.Config. The resulting config is NOT registered. Shim matches the v2.UpgradeFunc type.

Types

This section is empty.

Jump to

Keyboard shortcuts

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