Documentation
¶
Index ¶
- func GenerateAndServeCRMetrics(cfg *rest.Config, ns []string, operatorGVKs []schema.GroupVersionKind, ...) error
- func GetNamespacesForMetrics(operatorNs string) ([]string, error)
- func NewClusterScopedMetricsStores(dclient dynamic.NamespaceableResourceInterface, api string, kind string, ...) []*metricsstore.MetricsStore
- func NewMetricsStores(dclient dynamic.NamespaceableResourceInterface, namespaces []string, ...) []*metricsstore.MetricsStoredeprecated
- func NewNamespacedMetricsStores(dclient dynamic.NamespaceableResourceInterface, namespaces []string, ...) []*metricsstore.MetricsStore
- func ServeMetrics(stores [][]*metricsstore.MetricsStore, host string, port int32)
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func GenerateAndServeCRMetrics ¶
func GenerateAndServeCRMetrics(cfg *rest.Config, ns []string, operatorGVKs []schema.GroupVersionKind, host string, port int32) error
GenerateAndServeCRMetrics generates CustomResource specific metrics for each custom resource GVK in operatorGVKs. A list of namespaces, ns, can be passed to ServeCRMetrics to scope the generated metrics. Passing nil or an empty list of namespaces will result in an error. The function also starts serving the generated collections of the metrics on given host and port.
func GetNamespacesForMetrics ¶ added in v0.16.0
GetNamespacesForMetrics wil return all namespaces which will be used to export the metrics
func NewClusterScopedMetricsStores ¶ added in v0.17.0
func NewClusterScopedMetricsStores(dclient dynamic.NamespaceableResourceInterface, api string, kind string, metricFamily []metric.FamilyGenerator) []*metricsstore.MetricsStore
NewClusterScopedMetricsStores returns collections of metrics per the api/kind resource. The metrics are registered in the custom metrics.FamilyGenerator that needs to be defined.
func NewMetricsStores
deprecated
added in
v0.11.0
func NewMetricsStores(dclient dynamic.NamespaceableResourceInterface, namespaces []string, api string, kind string, metricFamily []metric.FamilyGenerator) []*metricsstore.MetricsStore
NewMetricsStores returns collections of metrics in the namespaces provided, per the api/kind resource. The metrics are registered in the custom metrics.FamilyGenerator that needs to be defined.
Deprecated: Use NewNamespacedMetricsStores instead.
func NewNamespacedMetricsStores ¶ added in v0.17.0
func NewNamespacedMetricsStores(dclient dynamic.NamespaceableResourceInterface, namespaces []string, api string, kind string, metricFamily []metric.FamilyGenerator) []*metricsstore.MetricsStore
NewNamespacedMetricsStores returns collections of metrics in the namespaces provided, per the api/kind resource. The metrics are registered in the custom metrics.FamilyGenerator that needs to be defined.
func ServeMetrics ¶
func ServeMetrics(stores [][]*metricsstore.MetricsStore, host string, port int32)
Types ¶
This section is empty.