prometheus

package
v16.11.6 Latest Latest
Warning

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

Go to latest
Published: Jul 9, 2024 License: MIT Imports: 8 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Config

type Config struct {
	// ScrapeTimeout is the allowed duration of a Prometheus scrape before timing out.
	ScrapeTimeout duration.Duration `toml:"scrape_timeout,omitempty" json:"scrape_timeout"`
	// GRPCLatencyBuckets configures the histogram buckets used for gRPC
	// latency measurements.
	GRPCLatencyBuckets []float64 `toml:"grpc_latency_buckets,omitempty" json:"grpc_latency_buckets"`
}

Config contains additional configuration data for prometheus

func DefaultConfig

func DefaultConfig() Config

DefaultConfig returns a new config with default values set.

func (*Config) Configure

func (c *Config) Configure(logger log.Logger)

Configure configures latency buckets for prometheus timing histograms

func (*Config) Validate

func (c *Config) Validate() error

Validate runs validation on all fields and compose all found errors.

Jump to

Keyboard shortcuts

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