metrics

package
v0.0.5-dev.1 Latest Latest
Warning

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

Go to latest
Published: Mar 10, 2023 License: MIT Imports: 3 Imported by: 1

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Metric

type Metric[T any] struct {
	Timestamp time.Time
	Value     T
}

func NewMetric

func NewMetric[T any](ctx context.Context, value T) *Metric[T]

type MetricsRecorder

type MetricsRecorder interface {
	RecordVMStatus(ctx context.Context, metric *Metric[*vm.VirtualMachineStatus]) error
}

type NoOpMetricRecorder

type NoOpMetricRecorder struct{}

func NewNoOpMetricRecorder

func NewNoOpMetricRecorder() *NoOpMetricRecorder

func (*NoOpMetricRecorder) RecordVMStatus

func (rec *NoOpMetricRecorder) RecordVMStatus(ctx context.Context, metric *Metric[*vm.VirtualMachineStatus]) error

Jump to

Keyboard shortcuts

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