metrics

package
v0.2.1-patch-3 Latest Latest
Warning

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

Go to latest
Published: Jul 26, 2024 License: MIT Imports: 6 Imported by: 0

Documentation

Index

Constants

View Source
const (
	LabelError        = "error"
	LabelRequeueAfter = "requeue_after"
	LabelRequeue      = "requeue"
	LabelSuccess      = "success"
)

Variables

View Source
var (
	AppRoutingReconcileTotal = prometheus.NewCounterVec(prometheus.CounterOpts{
		Name: "app_routing_reconcile_total",
		Help: "Total number of reconciliations per controller",
	}, []string{"controller", "result"})

	AppRoutingReconcileErrors = prometheus.NewCounterVec(prometheus.CounterOpts{
		Name: "app_routing_reconcile_errors_total",
		Help: "Total number of reconciliation errors per controller",
	}, []string{"controller"})
)

Functions

func HandleControllerReconcileMetrics

func HandleControllerReconcileMetrics(controllerName controllername.ControllerNamer, result ctrl.Result, err error)

HandleControllerReconcileMetrics is meant to be called within a defer for each controller. This lets us put all the metric handling in one place, rather than duplicating it in every controller

func HandleWebhookHandlerMetrics added in v0.1.0

func HandleWebhookHandlerMetrics(controllerName controllername.ControllerNamer, result admission.Response, err error)

HandleWebhookHandlerMetrics is meant to be called within a defer for each webhook handler func.

func InitControllerMetrics

func InitControllerMetrics(controllerName controllername.ControllerNamer)

Types

This section is empty.

Jump to

Keyboard shortcuts

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