Documentation ¶
Overview ¶
Package metric provides functionality for managing gathering metrics, calling external metric gathering logic through shell commands with relevant data piped to them.
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Gatherer ¶
type Gatherer struct { Clientset kubernetes.Interface Config *config.Config Execute execute.Executer K8sMetricGatherer measure.Gatherer }
Gatherer handles triggering the metric gathering logic to gather metrics for a resource
type GetMetricer ¶ added in v0.9.0
GetMetricer provides methods for retrieving metrics
type Metric ¶
type Metric struct { Resource string `json:"resource,omitempty"` Value string `json:"value,omitempty"` }
Metric is the result of the custom metric calculation, containing information on the relevant resource and the metric value
type Spec ¶ added in v0.11.0
type Spec struct { Resource metav1.Object `json:"resource"` Metrics *[]*Metric `json:"metrics,omitempty"` RunType string `json:"runType"` KubernetesMetrics []*measure.Metric `json:"kubernetesMetrics,omitempty"` }
Spec defines information fed into a gatherer to retrieve metrics, contains an optional field 'Metrics' for storing the result
Click to show internal directories.
Click to hide internal directories.