SimpleCollector
abstract class SimpleCollector<Child>(val fullName: String, val help: String, val labelNames: List<String>, val unit: String) : Collector
Abstract base class for Prometheus metric types that support labeled children.
This class provides common functionality for metric types like Counter and Gauge, including label management, child instance tracking, and sample collection.
Parameters
Child
The type of the labeled metric child (e.g., Counter.Child, Gauge.Child).
fullName
The full metric name (including suffix, if applicable).
help
A human-readable description of the metric's purpose.
labelNames
The list of label names (must be valid Prometheus identifiers).
unit
The unit of the metric (optional, e.g., "seconds").
Inheritors
Constructors
Properties
Functions
Link copied to clipboard
Collects the current set of metric samples.
Link copied to clipboard
Returns the simple class name of the Collector instance.
Link copied to clipboard
Registers this collector in the given CollectorRegistry.