Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func NewMetricsClient ¶
func NewMetricsClient(logger logger.Logger, restConfig *rest.Config, autoScalerConf scalertypes.AutoScalerOptions) (scalertypes.MetricsClient, error)
Types ¶
type K8sCustomMetricsClient ¶
type K8sCustomMetricsClient struct {
k8scustommetrics.CustomMetricsClient
// contains filtered or unexported fields
}
func NewCustomMetricsClient ¶
func (*K8sCustomMetricsClient) GetResourceMetrics ¶
func (cmw *K8sCustomMetricsClient) GetResourceMetrics(resources []scalertypes.Resource) (map[string]map[string]int, error)
type PrometheusMetricsClient ¶
type PrometheusMetricsClient struct {
// contains filtered or unexported fields
}
PrometheusMetricsClient implements MetricsClient interface using Prometheus as the backend
func NewPrometheusClient ¶
func NewPrometheusClient(parentLogger logger.Logger, prometheusURL, namespace string, templates []scalertypes.QueryTemplate, interval time.Duration) (*PrometheusMetricsClient, error)
NewPrometheusClient creates a new PrometheusMetricsClient instance
func (*PrometheusMetricsClient) GetResourceMetrics ¶
func (pc *PrometheusMetricsClient) GetResourceMetrics(resources []scalertypes.Resource) (map[string]map[string]int, error)
GetResourceMetrics retrieves metrics for multiple resources
Click to show internal directories.
Click to hide internal directories.