metrics

package
v0.0.0-...-f9df99f Latest Latest
Warning

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

Go to latest
Published: Dec 6, 2024 License: Apache-2.0 Imports: 5 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var ActiveUploads = prometheus.NewGauge(prometheus.GaugeOpts{
	Name: "dex_server_active_uploads",
	Help: "Current number of active uploads",

}) // .metricsOpenConnections

todo this could also be a vec per datastream

View Source
var DefaultMetrics = []prometheus.Collector{
	ActiveUploads,
}
View Source
var HttpReqs = prometheus.NewCounterVec(
	prometheus.CounterOpts{
		Name: "http_requests_total",
		Help: "How many HTTP requests processed, partitioned by status code and HTTP method.",
	},
	[]string{"code", "method"},
)
View Source
var OpenConnections = prometheus.NewGauge(prometheus.GaugeOpts{
	Name: "dex_server_connections_open",
	Help: "Current number of server open connections.",

}) // .metricsOpenConnections

Functions

func ActiveUploadDecHook

func ActiveUploadDecHook(event handler.HookEvent, resp hooks.HookResponse) (hooks.HookResponse, error)

func ActiveUploadIncHook

func ActiveUploadIncHook(event handler.HookEvent, resp hooks.HookResponse) (hooks.HookResponse, error)

func RegisterMetrics

func RegisterMetrics(metrics ...prometheus.Collector) error

func TrackHTTP

func TrackHTTP(handler http.Handler) http.Handler

Types

type ManifestMetrics

type ManifestMetrics struct {
	Keys    []string
	Counter *prometheus.CounterVec
}

func NewManifestMetrics

func NewManifestMetrics(name string, help string, keys ...string) *ManifestMetrics

func (*ManifestMetrics) Hook

Jump to

Keyboard shortcuts

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