prometheus

package
v0.10.0 Latest Latest
Warning

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

Go to latest
Published: Mar 19, 2018 License: BSD-3-Clause Imports: 21 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func New

func New(cfgBaseName string) (collector.Collector, error)

New creates new prom collector

Types

type Prom

type Prom struct {
	sync.Mutex
	// contains filtered or unexported fields
}

Prom defines prom collector

func (*Prom) Collect

func (c *Prom) Collect() error

Collect returns collector metrics

func (*Prom) Flush

func (c *Prom) Flush() cgm.Metrics

Flush returns last metrics collected

func (*Prom) ID

func (c *Prom) ID() string

ID returns the id of the instance

func (*Prom) Inventory

func (c *Prom) Inventory() collector.InventoryStats

Inventory returns collector stats for /inventory endpoint

type URLDef

type URLDef struct {
	ID  string `json:"id" toml:"id" yaml:"id"`
	URL string `json:"url" toml:"url" yaml:"url"`
	TTL string `json:"ttl" toml:"ttl" yaml:"ttl"`
	// contains filtered or unexported fields
}

URLDef defines a url to fetch text formatted prom metrics from

Jump to

Keyboard shortcuts

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