metrics

package
v0.0.0-...-2aa8555 Latest Latest
Warning

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

Go to latest
Published: Jan 6, 2021 License: Apache-2.0 Imports: 3 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Handler

func Handler()

HandleMetrics register handler

Types

type Metrics

type Metrics struct {
	// Connection gauge
	CurrentTCPConnectionCount  prometheus.Gauge
	CurrentMQTTConnectionCount *prometheus.GaugeVec

	// MQTT defaultMetrics
	NewConnectionCount    *prometheus.CounterVec
	ClosedConnectionCount *prometheus.CounterVec

	// packets histogram
	// UpPacketCount              *prometheus.CounterVec
	// DownPacketCount            *prometheus.CounterVec
	UpPacketSizeHistogramVec   *prometheus.HistogramVec
	DownPacketSizeHistogramVec *prometheus.HistogramVec

	CacheCount     prometheus.Counter
	CacheHintCount prometheus.Counter

	// GRPC
	GrpcHistogramVec         *prometheus.HistogramVec
	TopicScanDuration        prometheus.Histogram
	ConnectionOnlineDuration *prometheus.HistogramVec

	ClientPullDuration *prometheus.HistogramVec
	ClientPullCount    *prometheus.GaugeVec

	// panic due to an unknown error
	ClientPanicCount prometheus.Counter
}

Metrics monitoring management

func GetMetrics

func GetMetrics() *Metrics

GetMetrics get default a metrics object

Jump to

Keyboard shortcuts

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