Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func MetricsExporterProvider ¶
Types ¶
type Expirer ¶
type Expirer struct {
// contains filtered or unexported fields
}
Expirer drops metrics from labels that haven't been updated during a given timeout TODO: generify and move to a common section for using it also in AppO11y, supporting more OTEL metrics
func NewExpirer ¶
NewExpirer creates a metric that wraps a Counter. Its labeled instances are dropped if they haven't been updated during the last timeout period
func (*Expirer) ForRecord ¶
ForRecord returns the Counter for the given eBPF record. If that record s accessed for the first time, a new Counter is created. If not, a cached copy is returned and the "last access" cache time is updated.
func (*Expirer) UpdateTime ¶
func (ex *Expirer) UpdateTime()
UpdateTime updates the last access time to be annotated to any new or existing metric. It is a required operation before processing a given batch of metrics (invoking the WithLabelValues).
type MetricsConfig ¶
type MetricsConfig struct { Metrics *otel.MetricsConfig AllowedAttributes []string }
func (MetricsConfig) Enabled ¶
func (mc MetricsConfig) Enabled() bool