Documentation ¶
Index ¶
- Constants
- Variables
- func RecordCheckerScanDuration(resource string, start time.Time)
- func RecordDWSOperationDuration(resource, cluster string, start time.Time)
- func RecordDWSOperationStatus(resource, cluster, code string)
- func RecordUWSOperationDuration(resource string, start time.Time)
- func RecordUWSOperationStatus(resource, code string)
- func Register()
- func SinceInMicroseconds(start time.Time) float64
- func SinceInSeconds(start time.Time) float64
Constants ¶
View Source
const ( ResourceSyncerSubsystem = "syncer" PodOperationsKey = "pod_operations_total" PodOperationsDurationKey = "pod_operations_duration_seconds" CheckerMissMatchKey = "checker_missmatch_count" CheckerRemedyKey = "checker_remedy_count" CheckerScanDurationKey = "checker_scan_duaration_seconds" DWSOperationCounterKey = "dws_operations_total" DWSOperationDurationKey = "dws_operations_duration_seconds" UWSOperationCounterKey = "uws_operations_total" UWSOperationDurationKey = "uws_operations_duration_seconds" ClusterHealthKey = "virtual_cluster_health" )
Variables ¶
View Source
var ( PodOperations = prometheus.NewCounterVec( prometheus.CounterOpts{ Subsystem: ResourceSyncerSubsystem, Name: PodOperationsKey, Help: "Cumulative number of pod operations by operation type.", }, []string{"operation_type", "code"}, ) PodOperationsDuration = prometheus.NewHistogramVec( prometheus.HistogramOpts{ Subsystem: ResourceSyncerSubsystem, Name: PodOperationsDurationKey, Help: "Duration in seconds of pod operations. Broken down by operation type.", Buckets: prometheus.DefBuckets, }, []string{"operation_type"}, ) CheckerMissMatchStats = prometheus.NewGaugeVec( prometheus.GaugeOpts{ Subsystem: ResourceSyncerSubsystem, Name: CheckerMissMatchKey, Help: "Last checker scan results for mismatched resources.", }, []string{"counter_name"}, ) CheckerRemedyStats = prometheus.NewCounterVec( prometheus.CounterOpts{ Subsystem: ResourceSyncerSubsystem, Name: CheckerRemedyKey, Help: "Cumulative number of checker remediation actions.", }, []string{"counter_name"}, ) CheckerScanDuration = prometheus.NewHistogramVec( prometheus.HistogramOpts{ Subsystem: ResourceSyncerSubsystem, Name: CheckerScanDurationKey, Help: "Duration in seconds of each resource checker's scan time.", Buckets: prometheus.DefBuckets, }, []string{"resource"}, ) DWSOperationDuration = prometheus.NewHistogramVec( prometheus.HistogramOpts{ Subsystem: ResourceSyncerSubsystem, Name: DWSOperationDurationKey, Help: "Duration in seconds of each resource dws operation time.", Buckets: prometheus.DefBuckets, }, []string{"resource", "vc_name"}) DWSOperationCounter = prometheus.NewCounterVec( prometheus.CounterOpts{ Subsystem: ResourceSyncerSubsystem, Name: DWSOperationCounterKey, Help: "Cumulative number of downward resource operations.", }, []string{"resource", "vc_name", "code"}) UWSOperationDuration = prometheus.NewHistogramVec( prometheus.HistogramOpts{ Subsystem: ResourceSyncerSubsystem, Name: UWSOperationDurationKey, Help: "Duration in seconds of resource uws operation time.", Buckets: prometheus.DefBuckets, }, []string{"resource"}, ) UWSOperationCounter = prometheus.NewCounterVec( prometheus.CounterOpts{ Subsystem: ResourceSyncerSubsystem, Name: UWSOperationCounterKey, Help: "Cumulative number of upward resource operations.", }, []string{"resource", "code"}) ClusterHealthStats = prometheus.NewGaugeVec( prometheus.GaugeOpts{ Subsystem: ResourceSyncerSubsystem, Name: ClusterHealthKey, Help: "Last checker scan status for virtual clusters.", }, []string{"status"}, ) )
Functions ¶
func RecordDWSOperationStatus ¶
func RecordDWSOperationStatus(resource, cluster, code string)
func RecordUWSOperationStatus ¶
func RecordUWSOperationStatus(resource, code string)
func SinceInMicroseconds ¶
Gets the time since the specified start in microseconds.
func SinceInSeconds ¶
SinceInSeconds gets the time since the specified start in seconds.
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.