kafkaprometheus

package
v3.17.0 Latest Latest
Warning

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

Go to latest
Published: Feb 23, 2024 License: Apache-2.0 Imports: 4 Imported by: 0

Documentation

Index

Constants

View Source
const SlugSeparator = "$" // SlugSeparator is excluded by topicRegex.

Variables

This section is empty.

Functions

func SplitSlug

func SplitSlug(s string) (topic, eventName, groupID string)

ParseSlug returns topic, eventName, and groupID

Types

type KafkaStatCollector

type KafkaStatCollector interface {
	GetWriterStats() ([]kafka.WriterStats, []string)
	GetReaderStats() ([]kafka.ReaderStats, []string)
}

type ReaderCollector

type ReaderCollector struct {
	Client KafkaStatCollector
}

ReaderCollector implements prometheus' Collector interface, for kafka reader.

func (*ReaderCollector) Collect

func (r *ReaderCollector) Collect(metrics chan<- prometheus.Metric)

func (*ReaderCollector) Describe

func (r *ReaderCollector) Describe(c chan<- *prometheus.Desc)

type WriterCollector

type WriterCollector struct {
	Client KafkaStatCollector
}

WriterCollector implements prometheus' Collector interface, for kafka writer.

func (*WriterCollector) Collect

func (w *WriterCollector) Collect(metrics chan<- prometheus.Metric)

func (*WriterCollector) Describe

func (w *WriterCollector) Describe(c chan<- *prometheus.Desc)

Jump to

Keyboard shortcuts

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