metrics

package
v1.9.0 Latest Latest
Warning

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

Go to latest
Published: Sep 21, 2026 License: Apache-2.0 Imports: 18 Imported by: 0

Documentation

Index

Constants

View Source
const QueueHandlerPath = "/api/queue/"

Variables

This section is empty.

Functions

func RemoveStoreMetrics

func RemoveStoreMetrics(store *v1.Store)

RemoveStoreMetrics removes all metrics for a deleted store.

func UpdateQueueMetrics added in v1.9.0

func UpdateQueueMetrics(namespace string, storeName string, transports []v1.QueueTransportStats)

func UpdateScheduledTaskMetrics

func UpdateScheduledTaskMetrics(store *v1.Store, cronJob *batchv1.CronJob)

UpdateScheduledTaskMetrics sets metrics for the scheduled task CronJob.

func UpdateStoreMetrics

func UpdateStoreMetrics(store *v1.Store)

UpdateStoreMetrics sets all gauge values from a Store's status.

Types

type QueueStats added in v1.9.0

type QueueStats struct {
	Client     client.Client
	Clientset  *kubernetes.Clientset
	RestConfig *rest.Config
	TTL        time.Duration
	Logger     *zap.SugaredLogger
	// contains filtered or unexported fields
}

QueueStats serves live queue lengths for the KEDA metrics-api scaler. The counts are fetched from the admin pod on demand and cached for a short TTL, so freshness is driven by the scaler polling instead of the reconcile interval of the store.

func NewQueueStats added in v1.9.0

func NewQueueStats(
	c client.Client,
	clientset *kubernetes.Clientset,
	restConfig *rest.Config,
	ttl time.Duration,
	logger *zap.SugaredLogger,
) *QueueStats

func (*QueueStats) Handler added in v1.9.0

func (q *QueueStats) Handler() http.Handler

Jump to

Keyboard shortcuts

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