metrics

package
v0.0.0-...-967821a Latest Latest
Warning

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

Go to latest
Published: Aug 2, 2017 License: Apache-2.0 Imports: 6 Imported by: 1

Documentation

Index

Constants

This section is empty.

Variables

View Source
var GlobalPodMetrics = PodMetrics{
	TotalNumberPods: prometheus.NewGauge(
		prometheus.GaugeOpts{
			Name:      "total_number_pods",
			Namespace: namespace,
			Help:      "Total number of pods in the cluster",
		},
	),
	IncomingPackets: prometheus.NewCounterVec(
		prometheus.CounterOpts{
			Name:      "packets_incoming_total",
			Namespace: namespace,
			Help:      "Total number of incoming packets.",
		},
		[]string{"pod_name"},
	),
	OutgoingPackets: prometheus.NewCounterVec(
		prometheus.CounterOpts{
			Name:      "packets_outgoing_total",
			Namespace: namespace,
			Help:      "Total number of outgoing packets.",
		},
		[]string{"pod_name"},
	),
}

Functions

func Serve

func Serve(ctx context.Context, addr string)

Types

type PodMetrics

type PodMetrics struct {
	TotalNumberPods prometheus.Gauge
	IncomingPackets *prometheus.CounterVec
	OutgoingPackets *prometheus.CounterVec
}

Jump to

Keyboard shortcuts

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