Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type DefaultLabelStrategy ¶
type DefaultLabelStrategy struct {
// contains filtered or unexported fields
}
DefaultLabelStrategy defines the labels to add to an metric and its data retrieval method
func NewDefaultLabelStrategy ¶
func NewDefaultLabelStrategy(descriptionLabels bool, descriptionLabelsRegex string) *DefaultLabelStrategy
func (*DefaultLabelStrategy) LabelNames ¶
func (d *DefaultLabelStrategy) LabelNames(p *protocol.Protocol) []string
LabelNames returns the list of label names
func (*DefaultLabelStrategy) LabelValues ¶
func (d *DefaultLabelStrategy) LabelValues(p *protocol.Protocol) []string
LabelValues returns the values for a protocol
type GenericProtocolMetricExporter ¶
type GenericProtocolMetricExporter struct {
// contains filtered or unexported fields
}
GenericProtocolMetricExporter exports metrics retrieved from Bird routing daemon
func NewGenericProtocolMetricExporter ¶
func NewGenericProtocolMetricExporter(prefix string, newNaming bool, labelStrategy LabelStrategy) *GenericProtocolMetricExporter
NewGenericProtocolMetricExporter creates a new instance of GenericProtocolMetricExporter
func (*GenericProtocolMetricExporter) Describe ¶
func (m *GenericProtocolMetricExporter) Describe(ch chan<- *prometheus.Desc)
func (*GenericProtocolMetricExporter) Export ¶
func (m *GenericProtocolMetricExporter) Export(p *protocol.Protocol, ch chan<- prometheus.Metric, newNaming bool)
type LabelStrategy ¶
type LabelStrategy interface { // LabelNames is the list of label names LabelNames(p *protocol.Protocol) []string // Label values is the list of values for the labels specified in `LabelNames()` LabelValues(p *protocol.Protocol) []string }
LabelStrategy abstracts the label generation for protocol metrics
type LegacyLabelStrategy ¶
type LegacyLabelStrategy struct { }
func NewLegacyLabelStrategy ¶
func NewLegacyLabelStrategy() *LegacyLabelStrategy
func (*LegacyLabelStrategy) LabelNames ¶
func (*LegacyLabelStrategy) LabelNames(p *protocol.Protocol) []string
func (*LegacyLabelStrategy) LabelValues ¶
func (*LegacyLabelStrategy) LabelValues(p *protocol.Protocol) []string
type LegacyMetricExporter ¶
type LegacyMetricExporter struct {
// contains filtered or unexported fields
}
func (*LegacyMetricExporter) Describe ¶
func (e *LegacyMetricExporter) Describe(ch chan<- *prometheus.Desc)
func (*LegacyMetricExporter) Export ¶
func (e *LegacyMetricExporter) Export(p *protocol.Protocol, ch chan<- prometheus.Metric, newFormat bool)
type MetricExporter ¶
type MetricExporter interface { Describe(ch chan<- *prometheus.Desc) Export(p *protocol.Protocol, ch chan<- prometheus.Metric, newFormat bool) }
func NewBFDExporter ¶
func NewBFDExporter(client client.Client) MetricExporter
NewBFDExporter creates a new MetricExporter for BFD metrics
func NewLegacyMetricExporter ¶
func NewLegacyMetricExporter(prefixIpv4, prefixIpv6 string, labelStrategy LabelStrategy) MetricExporter
func NewOSPFExporter ¶
func NewOSPFExporter(prefix string, client client.Client) MetricExporter
NewOSPFExporter creates a new MetricExporter for OSPF metrics
Click to show internal directories.
Click to hide internal directories.