prom

package
v0.0.0-...-5e3b14e Latest Latest
Warning

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

Go to latest
Published: Oct 21, 2019 License: MIT Imports: 5 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var M = Metrics{
	EvictedPods: prometheus.NewCounter(
		prometheus.CounterOpts{
			ConstLabels: prometheus.Labels{},
			Namespace:   "rebuy",
			Subsystem:   "node_drainer",
			Name:        "evicted_pods",
			Help:        "Number of evicted Pods on total.",
		},
	),
	LastEvictionDuration: prometheus.NewGauge(
		prometheus.GaugeOpts{
			ConstLabels: prometheus.Labels{},
			Namespace:   "rebuy",
			Subsystem:   "node_drainer",
			Name:        "last_eviction_duration",
			Help:        "Duration in seconds of the last eviction.",
		},
	),
}

Functions

func Run

func Run(port string) *prometheus.Registry

Types

type Metrics

type Metrics struct {
	EvictedPods          prometheus.Counter
	LastEvictionDuration prometheus.Gauge
}

func (*Metrics) IncreaseEvictedPods

func (m *Metrics) IncreaseEvictedPods()

func (*Metrics) SetLastEvictionDuration

func (m *Metrics) SetLastEvictionDuration(duration float64)

Jump to

Keyboard shortcuts

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