metrics

package
v2.6.6 Latest Latest
Warning

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

Go to latest
Published: Mar 16, 2023 License: Apache-2.0 Imports: 7 Imported by: 2

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type MetricsServer

type MetricsServer struct {
	*http.Server
	// contains filtered or unexported fields
}

func NewMetricsServer

func NewMetricsServer(host string, port int) *MetricsServer

NewMetricsServer returns a new prometheus server which collects api server metrics

func (*MetricsServer) IncRedisRequest

func (m *MetricsServer) IncRedisRequest(failed bool)

func (*MetricsServer) ObserveRedisRequestDuration

func (m *MetricsServer) ObserveRedisRequestDuration(duration time.Duration)

ObserveRedisRequestDuration observes redis request duration

Jump to

Keyboard shortcuts

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