Documentation ¶
Index ¶
- Constants
- func CVORelabelConfigs(set MetricsSet) []*prometheusoperatorv1.RelabelConfig
- func CatalogOperatorRelabelConfigs(set MetricsSet) []*prometheusoperatorv1.RelabelConfig
- func ControlPlaneOperatorRelabelConfigs(set MetricsSet) []*prometheusoperatorv1.RelabelConfig
- func EnableOBOMonitoring(namespace *corev1.Namespace)
- func EtcdRelabelConfigs(set MetricsSet) []*prometheusoperatorv1.RelabelConfig
- func HostedClusterConfigOperatorRelabelConfigs(set MetricsSet) []*prometheusoperatorv1.RelabelConfig
- func KASRelabelConfigs(set MetricsSet) []*prometheusoperatorv1.RelabelConfig
- func KCMRelabelConfigs(set MetricsSet) []*prometheusoperatorv1.RelabelConfig
- func LoadSREMetricsSetConfigurationFromConfigMap(cm *corev1.ConfigMap) error
- func MetricsSetToEnv(set MetricsSet) corev1.EnvVar
- func NTORelabelConfigs(set MetricsSet) []*prometheusoperatorv1.RelabelConfig
- func OLMRelabelConfigs(set MetricsSet) []*prometheusoperatorv1.RelabelConfig
- func OpenShiftAPIServerRelabelConfigs(set MetricsSet) []*prometheusoperatorv1.RelabelConfig
- func OpenShiftControllerManagerRelabelConfigs(set MetricsSet) []*prometheusoperatorv1.RelabelConfig
- func OpenShiftRouteControllerManagerRelabelConfigs(set MetricsSet) []*prometheusoperatorv1.RelabelConfig
- func RegistryOperatorRelabelConfigs(set MetricsSet) []*prometheusoperatorv1.RelabelConfig
- func SREMetricsSetConfigHash(cm *corev1.ConfigMap) string
- func SREMetricsSetConfigurationConfigMap(namespace string) *corev1.ConfigMap
- type MetricsSet
- type MetricsSetConfig
- type PlatformMonitoring
Constants ¶
const ( DefaultMetricsSet = MetricsSetTelemetry SREConfigurationConfigMapName = "sre-metric-set" SREConfigurationConfigMapKey = "config" )
const ( // The common label for monitoring in HyperShift // Namespaces with this label will be actively monitored by the observability operator HyperShiftMonitoringLabel = "hypershift.openshift.io/monitoring" )
Variables ¶
This section is empty.
Functions ¶
func CVORelabelConfigs ¶
func CVORelabelConfigs(set MetricsSet) []*prometheusoperatorv1.RelabelConfig
func CatalogOperatorRelabelConfigs ¶
func CatalogOperatorRelabelConfigs(set MetricsSet) []*prometheusoperatorv1.RelabelConfig
func ControlPlaneOperatorRelabelConfigs ¶
func ControlPlaneOperatorRelabelConfigs(set MetricsSet) []*prometheusoperatorv1.RelabelConfig
func EnableOBOMonitoring ¶ added in v0.1.5
EnableOBOMonitoring enforces observability operator monitoring on the given namespace
func EtcdRelabelConfigs ¶
func EtcdRelabelConfigs(set MetricsSet) []*prometheusoperatorv1.RelabelConfig
func HostedClusterConfigOperatorRelabelConfigs ¶
func HostedClusterConfigOperatorRelabelConfigs(set MetricsSet) []*prometheusoperatorv1.RelabelConfig
func KASRelabelConfigs ¶
func KASRelabelConfigs(set MetricsSet) []*prometheusoperatorv1.RelabelConfig
func KCMRelabelConfigs ¶
func KCMRelabelConfigs(set MetricsSet) []*prometheusoperatorv1.RelabelConfig
func LoadSREMetricsSetConfigurationFromConfigMap ¶ added in v0.1.7
LoadSREMetricsSetConfigurationFromConfigMap parses the SRE metrics set configuration from the given ConfigMap and loads it into the singleton variable 'sreMetricsSetConfig' This can then be used by reconcile functions that get lists of RelabelConfigs for a particular component.
func MetricsSetToEnv ¶
func MetricsSetToEnv(set MetricsSet) corev1.EnvVar
func NTORelabelConfigs ¶
func NTORelabelConfigs(set MetricsSet) []*prometheusoperatorv1.RelabelConfig
func OLMRelabelConfigs ¶
func OLMRelabelConfigs(set MetricsSet) []*prometheusoperatorv1.RelabelConfig
func OpenShiftAPIServerRelabelConfigs ¶
func OpenShiftAPIServerRelabelConfigs(set MetricsSet) []*prometheusoperatorv1.RelabelConfig
func OpenShiftControllerManagerRelabelConfigs ¶
func OpenShiftControllerManagerRelabelConfigs(set MetricsSet) []*prometheusoperatorv1.RelabelConfig
func OpenShiftRouteControllerManagerRelabelConfigs ¶
func OpenShiftRouteControllerManagerRelabelConfigs(set MetricsSet) []*prometheusoperatorv1.RelabelConfig
func RegistryOperatorRelabelConfigs ¶
func RegistryOperatorRelabelConfigs(set MetricsSet) []*prometheusoperatorv1.RelabelConfig
func SREMetricsSetConfigHash ¶ added in v0.1.7
SREMetricsSetConfigHash calculates a hash of the SRE metrics set configuration given a ConfigMap that contains it.
func SREMetricsSetConfigurationConfigMap ¶ added in v0.1.7
SREMetricsSetConfigurationConfigMap returns a ConfigMap manifest for the SRE metrics set configuration, given a namespace. This configmap is expected to be created by the HyperShift administrator in the hypershift operator's namespace. It is then synced from there to every control plane namespace by the hypershift operator.
Types ¶
type MetricsSet ¶
type MetricsSet string
const ( MetricsSetTelemetry MetricsSet = "Telemetry" MetricsSetSRE MetricsSet = "SRE" MetricsSetAll MetricsSet = "All" )
func MetricsSetFromEnv ¶
func MetricsSetFromEnv() (MetricsSet, error)
func MetricsSetFromString ¶
func MetricsSetFromString(str string) (MetricsSet, error)
func (*MetricsSet) Set ¶
func (s *MetricsSet) Set(value string) error
func (*MetricsSet) String ¶
func (s *MetricsSet) String() string
func (*MetricsSet) Type ¶
func (s *MetricsSet) Type() string
type MetricsSetConfig ¶ added in v0.1.7
type MetricsSetConfig struct { // Kube/OpenShift components Etcd []*prometheusoperatorv1.RelabelConfig `json:"etcd,omitempty"` KubeAPIServer []*prometheusoperatorv1.RelabelConfig `json:"kubeAPIServer,omitempty"` KubeControllerManager []*prometheusoperatorv1.RelabelConfig `json:"kubeControllerManager,omitempty"` OpenShiftAPIServer []*prometheusoperatorv1.RelabelConfig `json:"openshiftAPIServer,omitempty"` OpenShiftControllerManager []*prometheusoperatorv1.RelabelConfig `json:"openshiftControllerManager,omitempty"` OpenShiftRouteControllerManager []*prometheusoperatorv1.RelabelConfig `json:"openshiftRouteControllerManager,omitempty"` CVO []*prometheusoperatorv1.RelabelConfig `json:"cvo,omitempty"` OLM []*prometheusoperatorv1.RelabelConfig `json:"olm,omitempty"` CatalogOperator []*prometheusoperatorv1.RelabelConfig `json:"catalogOperator,omitempty"` RegistryOperator []*prometheusoperatorv1.RelabelConfig `json:"registryOperator,omitempty"` NodeTuningOperator []*prometheusoperatorv1.RelabelConfig `json:"nodeTuningOperator,omitempty"` // HyperShift components ControlPlaneOperator []*prometheusoperatorv1.RelabelConfig `json:"controlPlaneOperator,omitempty"` HostedClusterConfigOperator []*prometheusoperatorv1.RelabelConfig `json:"hostedClusterConfigOperator,omitempty"` }
func (*MetricsSetConfig) LoadFromString ¶ added in v0.1.7
func (c *MetricsSetConfig) LoadFromString(value string) error
type PlatformMonitoring ¶
type PlatformMonitoring string
PlatformMonitoring is used to indicate which metrics will be scraped by the management cluster's platform monitoring stack: - OperatorOnly indicates that only the hypershift operator will be scraped - All indicates that the hypershift operator and any control planes created by it will be scraped - None indicates that neither operator nor control planes will be scraped
var ( PlatformMonitoringOperatorOnly PlatformMonitoring = "OperatorOnly" PlatformMonitoringAll PlatformMonitoring = "All" PlatformMonitoringNone PlatformMonitoring = "None" )
func (*PlatformMonitoring) IsEnabled ¶
func (o *PlatformMonitoring) IsEnabled() bool
func (*PlatformMonitoring) Set ¶
func (o *PlatformMonitoring) Set(value string) error
func (*PlatformMonitoring) String ¶
func (o *PlatformMonitoring) String() string
func (*PlatformMonitoring) Type ¶
func (o *PlatformMonitoring) Type() string