metrics

package
v0.1.23 Latest Latest
Warning

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

Go to latest
Published: May 8, 2021 License: AGPL-3.0 Imports: 5 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Agent

type Agent struct {
	Path            string
	RefreshInterval time.Duration
}

Agent struct with options

func NewAgent

func NewAgent(path string, interval time.Duration, proxy *mhttp.Proxy) *Agent

NewAgent creates and initializes the metrics agent with a HTTP server

func (*Agent) Register

func (ma *Agent) Register(c prometheus.Collector)

Register adds a prometheus collector

type Metrics

type Metrics struct {
	Enabled         bool
	RefreshInterval int
}

MetricsCfg initializes the metrics config

Jump to

Keyboard shortcuts

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