metrics

package
v1.15.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Oct 28, 2024 License: Apache-2.0 Imports: 2 Imported by: 11

Documentation

Index

Constants

View Source
const (

	// data mover metrics
	DataUploadSuccessTotal   = "data_upload_success_total"
	DataUploadFailureTotal   = "data_upload_failure_total"
	DataUploadCancelTotal    = "data_upload_cancel_total"
	DataDownloadSuccessTotal = "data_download_success_total"
	DataDownloadFailureTotal = "data_download_failure_total"
	DataDownloadCancelTotal  = "data_download_cancel_total"

	// metrics values
	BackupLastStatusSucc    int64 = 1
	BackupLastStatusFailure int64 = 0
)

Variables

This section is empty.

Functions

This section is empty.

Types

type ServerMetrics

type ServerMetrics struct {
	// contains filtered or unexported fields
}

ServerMetrics contains Prometheus metrics for the Velero server.

func NewNodeMetrics added in v1.12.0

func NewNodeMetrics() *ServerMetrics

func NewServerMetrics

func NewServerMetrics() *ServerMetrics

NewServerMetrics returns new ServerMetrics

func (*ServerMetrics) InitMetricsForNode added in v1.12.0

func (m *ServerMetrics) InitMetricsForNode(node string)

InitMetricsForNode initializes counter metrics for a node.

func (*ServerMetrics) InitSchedule added in v0.9.3

func (m *ServerMetrics) InitSchedule(scheduleName string)

InitSchedule initializes counter metrics of a schedule.

func (*ServerMetrics) ObservePodVolumeOpLatency added in v1.10.0

func (m *ServerMetrics) ObservePodVolumeOpLatency(node, pvbName, opName, backupName string, seconds float64)

ObservePodVolumeOpLatency records the number of seconds a pod volume operation took.

func (*ServerMetrics) RegisterAllMetrics

func (m *ServerMetrics) RegisterAllMetrics()

RegisterAllMetrics registers all prometheus metrics.

func (*ServerMetrics) RegisterBackupAttempt

func (m *ServerMetrics) RegisterBackupAttempt(backupSchedule string)

RegisterBackupAttempt records an backup attempt.

func (*ServerMetrics) RegisterBackupDeletionAttempt added in v1.0.0

func (m *ServerMetrics) RegisterBackupDeletionAttempt(backupSchedule string)

RegisterBackupDeletionAttempt records the number of attempted backup deletions

func (*ServerMetrics) RegisterBackupDeletionFailed added in v1.0.0

func (m *ServerMetrics) RegisterBackupDeletionFailed(backupSchedule string)

RegisterBackupDeletionFailed records the number of failed backup deletions

func (*ServerMetrics) RegisterBackupDeletionSuccess added in v1.0.0

func (m *ServerMetrics) RegisterBackupDeletionSuccess(backupSchedule string)

RegisterBackupDeletionSuccess records the number of successful backup deletions

func (*ServerMetrics) RegisterBackupDuration

func (m *ServerMetrics) RegisterBackupDuration(backupSchedule string, seconds float64)

RegisterBackupDuration records the number of seconds a backup took.

func (*ServerMetrics) RegisterBackupFailed

func (m *ServerMetrics) RegisterBackupFailed(backupSchedule string)

RegisterBackupFailed records a failed backup.

func (*ServerMetrics) RegisterBackupItemsErrorsGauge added in v1.9.0

func (m *ServerMetrics) RegisterBackupItemsErrorsGauge(backupSchedule string, items int)

RegisterBackupItemsErrorsGauge records the number of all error messages that were generated during execution of the backup.

func (*ServerMetrics) RegisterBackupItemsTotalGauge added in v1.9.0

func (m *ServerMetrics) RegisterBackupItemsTotalGauge(backupSchedule string, items int)

RegisterBackupItemsTotalGauge records the number of items to be backed up.

func (*ServerMetrics) RegisterBackupLastStatus added in v1.11.0

func (m *ServerMetrics) RegisterBackupLastStatus(backupSchedule string, lastStatus int64)

RegisterBackupLastStatus records the last status of the backup.

func (*ServerMetrics) RegisterBackupPartialFailure added in v1.0.0

func (m *ServerMetrics) RegisterBackupPartialFailure(backupSchedule string)

RegisterBackupPartialFailure records a partially failed backup.

func (*ServerMetrics) RegisterBackupSuccess

func (m *ServerMetrics) RegisterBackupSuccess(backupSchedule string)

RegisterBackupSuccess records a successful completion of a backup.

func (*ServerMetrics) RegisterBackupValidationFailure added in v1.5.0

func (m *ServerMetrics) RegisterBackupValidationFailure(backupSchedule string)

RegisterBackupValidationFailure records a validation failed backup.

func (*ServerMetrics) RegisterBackupWarning added in v1.11.0

func (m *ServerMetrics) RegisterBackupWarning(backupSchedule string)

RegisterBackupWarning records a warned backup.

func (*ServerMetrics) RegisterCSISnapshotAttempts added in v1.9.0

func (m *ServerMetrics) RegisterCSISnapshotAttempts(backupSchedule, backupName string, csiSnapshotsAttempted int)

RegisterCSISnapshotAttempts records an attempt to snapshot a volume by CSI plugin.

func (*ServerMetrics) RegisterCSISnapshotFailures added in v1.9.0

func (m *ServerMetrics) RegisterCSISnapshotFailures(backupSchedule, backupName string, csiSnapshotsFailed int)

RegisterCSISnapshotFailures records a failed volume snapshot by CSI plugin.

func (*ServerMetrics) RegisterCSISnapshotSuccesses added in v1.9.0

func (m *ServerMetrics) RegisterCSISnapshotSuccesses(backupSchedule, backupName string, csiSnapshotCompleted int)

RegisterCSISnapshotSuccesses records a completed volume snapshot by CSI plugin.

func (*ServerMetrics) RegisterDataDownloadCancel added in v1.12.0

func (m *ServerMetrics) RegisterDataDownloadCancel(node string)

RegisterDataDownloadCancel records canceled downloaded snapshots.

func (*ServerMetrics) RegisterDataDownloadFailure added in v1.12.0

func (m *ServerMetrics) RegisterDataDownloadFailure(node string)

RegisterDataDownloadFailure records failed downloaded snapshots.

func (*ServerMetrics) RegisterDataDownloadSuccess added in v1.12.0

func (m *ServerMetrics) RegisterDataDownloadSuccess(node string)

RegisterDataDownloadSuccess records successful downloaded snapshots.

func (*ServerMetrics) RegisterDataUploadCancel added in v1.12.0

func (m *ServerMetrics) RegisterDataUploadCancel(node string)

RegisterDataUploadCancel records canceled uploaded snapshots.

func (*ServerMetrics) RegisterDataUploadFailure added in v1.12.0

func (m *ServerMetrics) RegisterDataUploadFailure(node string)

RegisterDataUploadFailure records failed uploaded snapshots.

func (*ServerMetrics) RegisterDataUploadSuccess added in v1.12.0

func (m *ServerMetrics) RegisterDataUploadSuccess(node string)

RegisterDataUploadSuccess records successful uploaded snapshots.

func (*ServerMetrics) RegisterPodVolumeBackupDequeue added in v1.5.0

func (m *ServerMetrics) RegisterPodVolumeBackupDequeue(node string)

RegisterPodVolumeBackupDequeue records dequeuing of a PodVolumeBackup object.

func (*ServerMetrics) RegisterPodVolumeBackupEnqueue added in v1.5.0

func (m *ServerMetrics) RegisterPodVolumeBackupEnqueue(node string)

RegisterPodVolumeBackupEnqueue records enqueuing of a PodVolumeBackup object.

func (*ServerMetrics) RegisterPodVolumeOpLatencyGauge added in v1.10.0

func (m *ServerMetrics) RegisterPodVolumeOpLatencyGauge(node, pvbName, opName, backupName string, seconds float64)

RegisterPodVolumeOpLatencyGauge registers the pod volume operation latency as a gauge metric.

func (*ServerMetrics) RegisterRestoreAttempt added in v0.10.0

func (m *ServerMetrics) RegisterRestoreAttempt(backupSchedule string)

RegisterRestoreAttempt records an attempt to restore a backup.

func (*ServerMetrics) RegisterRestoreFailed added in v0.10.0

func (m *ServerMetrics) RegisterRestoreFailed(backupSchedule string)

RegisterRestoreFailed records a restore that failed.

func (*ServerMetrics) RegisterRestorePartialFailure added in v1.0.0

func (m *ServerMetrics) RegisterRestorePartialFailure(backupSchedule string)

RegisterRestorePartialFailure records a restore that partially failed.

func (*ServerMetrics) RegisterRestoreSuccess added in v0.10.0

func (m *ServerMetrics) RegisterRestoreSuccess(backupSchedule string)

RegisterRestoreSuccess records a successful (maybe partial) completion of a restore.

func (*ServerMetrics) RegisterRestoreValidationFailed added in v0.10.0

func (m *ServerMetrics) RegisterRestoreValidationFailed(backupSchedule string)

RegisterRestoreValidationFailed records a restore that failed validation.

func (*ServerMetrics) RegisterVolumeSnapshotAttempts added in v0.10.0

func (m *ServerMetrics) RegisterVolumeSnapshotAttempts(backupSchedule string, volumeSnapshotsAttempted int)

RegisterVolumeSnapshotAttempts records an attempt to snapshot a volume.

func (*ServerMetrics) RegisterVolumeSnapshotFailures added in v0.10.0

func (m *ServerMetrics) RegisterVolumeSnapshotFailures(backupSchedule string, volumeSnapshotsFailed int)

RegisterVolumeSnapshotFailures records a failed volume snapshot.

func (*ServerMetrics) RegisterVolumeSnapshotSuccesses added in v0.10.0

func (m *ServerMetrics) RegisterVolumeSnapshotSuccesses(backupSchedule string, volumeSnapshotsCompleted int)

RegisterVolumeSnapshotSuccesses records a completed volume snapshot.

func (*ServerMetrics) RemoveSchedule added in v1.13.0

func (m *ServerMetrics) RemoveSchedule(scheduleName string)

RemoveSchedule removes metrics associated with a specified schedule.

func (*ServerMetrics) SetBackupLastSuccessfulTimestamp added in v1.0.0

func (m *ServerMetrics) SetBackupLastSuccessfulTimestamp(backupSchedule string, time time.Time)

SetBackupLastSuccessfulTimestamp records the last time a backup ran successfully, Unix timestamp in seconds

func (*ServerMetrics) SetBackupTarballSizeBytesGauge

func (m *ServerMetrics) SetBackupTarballSizeBytesGauge(backupSchedule string, size int64)

SetBackupTarballSizeBytesGauge records the size, in bytes, of a backup tarball.

func (*ServerMetrics) SetBackupTotal added in v1.0.0

func (m *ServerMetrics) SetBackupTotal(numberOfBackups int64)

SetBackupTotal records the current number of existent backups.

func (*ServerMetrics) SetRestoreTotal added in v1.0.0

func (m *ServerMetrics) SetRestoreTotal(numberOfRestores int64)

SetRestoreTotal records the current number of existent restores.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL