prometheus

package
v2.2.8 Latest Latest
Warning

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

Go to latest
Published: Apr 5, 2024 License: MIT Imports: 14 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 {
	Host      string `koanf:"host"`
	Port      int    `koanf:"port"`
	Namespace string `koanf:"namespace"`
}

func (*Config) SetDefaults

func (c *Config) SetDefaults()

type Exporter

type Exporter struct {
	// contains filtered or unexported fields
}

Exporter is the Prometheus exporter that implements the prometheus.Collector interface

func NewExporter

func NewExporter(cfg Config, logger *zap.Logger, minionSvc *minion.Service) (*Exporter, error)

func (*Exporter) Collect

func (e *Exporter) Collect(ch chan<- prometheus.Metric)

func (*Exporter) Describe

func (e *Exporter) Describe(ch chan<- *prometheus.Desc)

Describe implements the prometheus.Collector interface. It sends the super-set of all possible descriptors of metrics collected by this Collector to the provided channel and returns once the last descriptor has been sent. The sent descriptors fulfill the consistency and uniqueness requirements described in the Desc documentation.

func (*Exporter) InitializeMetrics

func (e *Exporter) InitializeMetrics()

Jump to

Keyboard shortcuts

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