collector

package
v4.2.0 Latest Latest
Warning

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

Go to latest
Published: Mar 27, 2024 License: Apache-2.0 Imports: 8 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	ReleaseDesc *prometheus.Desc = prometheus.NewDesc(
		prometheus.BuildFQName(namespace, subsystem, "status"),
		"Metric about the status of a Release.",
		[]string{
			labelName,
			labelState,
			labelReady,
			labelInUse,
		},
		nil,
	)
)

Functions

func IsInvalidConfig

func IsInvalidConfig(err error) bool

IsInvalidConfig asserts invalidConfigError.

Types

type ReleaseCollector

type ReleaseCollector struct {
	// contains filtered or unexported fields
}

func NewReleaseCollector

func NewReleaseCollector(config ReleaseCollectorConfig) (*ReleaseCollector, error)

func (*ReleaseCollector) Collect

func (r *ReleaseCollector) Collect(ch chan<- prometheus.Metric) error

func (*ReleaseCollector) Describe

func (r *ReleaseCollector) Describe(ch chan<- *prometheus.Desc) error

type ReleaseCollectorConfig

type ReleaseCollectorConfig struct {
	K8sClient k8sclient.Interface
	Logger    micrologger.Logger
}

type Set

type Set struct {
	*collector.Set
}

Set is basically only a wrapper for the operator's collector implementations. It eases the initialization and prevents some weird import mess so we do not have to alias packages. There is also the benefit of the helper type kept private so we do not need to expose this magic.

func NewSet

func NewSet(config SetConfig) (*Set, error)

type SetConfig

type SetConfig struct {
	K8sClient k8sclient.Interface
	Logger    micrologger.Logger
}

Jump to

Keyboard shortcuts

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