Documentation
¶
Index ¶
- Constants
- func NewPrometheusMetrics(namespace string, registry metrics.RegisterGatherer) *prometheusMetrics
- func NewTriggerMetrics(namespace, name string) *triggerMetrics
- func SinceInSeconds(start time.Time) float64
- type NoOpMetrics
- func (m *NoOpMetrics) AddIPAllocation(subnetID string, allocated int64)
- func (m *NoOpMetrics) AddIPRelease(subnetID string, released int64)
- func (m *NoOpMetrics) AllocationAttempt(typ, status, subnetID string, observe float64)
- func (m *NoOpMetrics) IncInterfaceAllocation(subnetID string)
- func (m *NoOpMetrics) IncResyncCount()
- func (m *NoOpMetrics) K8sSyncTrigger() trigger.MetricsObserver
- func (m *NoOpMetrics) PoolMaintainerTrigger() trigger.MetricsObserver
- func (m *NoOpMetrics) ReleaseAttempt(typ, status, subnetID string, observe float64)
- func (m *NoOpMetrics) ResyncTrigger() trigger.MetricsObserver
- func (m *NoOpMetrics) SetAllocatedIPs(typ string, allocated int)
- func (m *NoOpMetrics) SetAvailableIPsPerSubnet(subnetID, availabilityZone string, available int)
- func (m *NoOpMetrics) SetAvailableInterfaces(available int)
- func (m *NoOpMetrics) SetEmptyInterfaceSlots(emptyInterfaceSlots int)
- func (m *NoOpMetrics) SetIPAvailable(node string, n int)
- func (m *NoOpMetrics) SetIPNeeded(node string, n int)
- func (m *NoOpMetrics) SetIPUsed(node string, n int)
- func (m *NoOpMetrics) SetInterfaceCandidates(interfaceCandidates int)
- func (m *NoOpMetrics) SetNodes(category string, nodes int)
- type NoOpMetricsObserver
Constants ¶
View Source
const LabelTargetNodeName = "target_node"
Variables ¶
This section is empty.
Functions ¶
func NewPrometheusMetrics ¶
func NewPrometheusMetrics(namespace string, registry metrics.RegisterGatherer) *prometheusMetrics
NewPrometheusMetrics returns a new interface metrics implementation backed by Prometheus metrics.
func NewTriggerMetrics ¶
func NewTriggerMetrics(namespace, name string) *triggerMetrics
func SinceInSeconds ¶
SinceInSeconds gets the time since the specified start in seconds.
Types ¶
type NoOpMetrics ¶
type NoOpMetrics struct{}
NoOpMetrics is a no-operation implementation of the metrics
func (*NoOpMetrics) AddIPAllocation ¶
func (m *NoOpMetrics) AddIPAllocation(subnetID string, allocated int64)
func (*NoOpMetrics) AddIPRelease ¶
func (m *NoOpMetrics) AddIPRelease(subnetID string, released int64)
func (*NoOpMetrics) AllocationAttempt ¶
func (m *NoOpMetrics) AllocationAttempt(typ, status, subnetID string, observe float64)
func (*NoOpMetrics) IncInterfaceAllocation ¶
func (m *NoOpMetrics) IncInterfaceAllocation(subnetID string)
func (*NoOpMetrics) IncResyncCount ¶
func (m *NoOpMetrics) IncResyncCount()
func (*NoOpMetrics) K8sSyncTrigger ¶
func (m *NoOpMetrics) K8sSyncTrigger() trigger.MetricsObserver
func (*NoOpMetrics) PoolMaintainerTrigger ¶
func (m *NoOpMetrics) PoolMaintainerTrigger() trigger.MetricsObserver
func (*NoOpMetrics) ReleaseAttempt ¶
func (m *NoOpMetrics) ReleaseAttempt(typ, status, subnetID string, observe float64)
func (*NoOpMetrics) ResyncTrigger ¶
func (m *NoOpMetrics) ResyncTrigger() trigger.MetricsObserver
func (*NoOpMetrics) SetAllocatedIPs ¶
func (m *NoOpMetrics) SetAllocatedIPs(typ string, allocated int)
func (*NoOpMetrics) SetAvailableIPsPerSubnet ¶
func (m *NoOpMetrics) SetAvailableIPsPerSubnet(subnetID, availabilityZone string, available int)
func (*NoOpMetrics) SetAvailableInterfaces ¶
func (m *NoOpMetrics) SetAvailableInterfaces(available int)
func (*NoOpMetrics) SetEmptyInterfaceSlots ¶
func (m *NoOpMetrics) SetEmptyInterfaceSlots(emptyInterfaceSlots int)
func (*NoOpMetrics) SetIPAvailable ¶
func (m *NoOpMetrics) SetIPAvailable(node string, n int)
func (*NoOpMetrics) SetIPNeeded ¶
func (m *NoOpMetrics) SetIPNeeded(node string, n int)
func (*NoOpMetrics) SetIPUsed ¶
func (m *NoOpMetrics) SetIPUsed(node string, n int)
func (*NoOpMetrics) SetInterfaceCandidates ¶
func (m *NoOpMetrics) SetInterfaceCandidates(interfaceCandidates int)
func (*NoOpMetrics) SetNodes ¶
func (m *NoOpMetrics) SetNodes(category string, nodes int)
type NoOpMetricsObserver ¶
type NoOpMetricsObserver struct{}
NoOpMetricsObserver is a no-operation implementation of the metrics observer
func (*NoOpMetricsObserver) PostRun ¶
func (m *NoOpMetricsObserver) PostRun(callDuration, latency time.Duration, folds int)
MetricsObserver implementation
func (*NoOpMetricsObserver) QueueEvent ¶
func (m *NoOpMetricsObserver) QueueEvent(reason string)
Click to show internal directories.
Click to hide internal directories.