Documentation ¶
Overview ¶
Package recommender (aka metrics_recommender) - code for metrics of VPA Recommender
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func NewExecutionTimer ¶
func NewExecutionTimer() *metrics.ExecutionTimer
NewExecutionTimer provides a timer for Recommender's RunOnce execution
func ObserveRecommendationLatency ¶
ObserveRecommendationLatency observes the time it took for the first recommendation to appear
func RecordAggregateContainerStatesCount ¶
func RecordAggregateContainerStatesCount(statesCount int)
RecordAggregateContainerStatesCount records the number of containers being tracked by the recommender
func RecordMetricsServerResponse ¶ added in v0.12.0
RecordMetricsServerResponse records result of a query to metrics server
Types ¶
type ObjectCounter ¶
type ObjectCounter struct {
// contains filtered or unexported fields
}
ObjectCounter helps split all VPA objects into buckets
func NewObjectCounter ¶
func NewObjectCounter() *ObjectCounter
NewObjectCounter creates a new helper to split VPA objects into buckets
func (*ObjectCounter) Add ¶
func (oc *ObjectCounter) Add(vpa *model.Vpa)
Add updates the helper state to include the given VPA object
func (*ObjectCounter) Observe ¶
func (oc *ObjectCounter) Observe()
Observe passes all the computed bucket values to metrics