circuitprom

package
v0.2.3 Latest Latest
Warning

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

Go to latest
Published: Apr 4, 2024 License: MIT Imports: 3 Imported by: 0

Documentation

Overview

Package circuitprom provides a Prometheus collector for circuit breakers.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Observer

type Observer interface {
	circuit.Observer
	prometheus.Collector
}

An Observer is a Prometheus collector for a circuit breaker.

func NewObserver

func NewObserver(options ...Option) Observer

NewObserver returns an observer for a circuit breaker with the given options.

type Option added in v0.2.0

type Option interface {
	// contains filtered or unexported methods
}

An Option provides optional configuration for an Observer.

func WithConstLabels added in v0.2.0

func WithConstLabels(labels prometheus.Labels) Option

WithConstLabels returns an Option that adds constant labels to all metrics.

func WithNamespace added in v0.2.0

func WithNamespace(namespace string) Option

WithNamespace returns an Option that sets the namespace for all metrics. The default is empty.

Jump to

Keyboard shortcuts

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