metric

package
v0.5.46 Latest Latest
Warning

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

Go to latest
Published: Apr 27, 2026 License: Apache-2.0 Imports: 4 Imported by: 0

Documentation

Index

Constants

View Source
const (
	ErrorCodeInitFailure            = ErrorCause("init_error")
	ErrorCodeStartFailure           = ErrorCause("start_error")
	ErrorCodePowerSpecFormat        = ErrorCause("spec_error")
	ErrorCodePowerGetCurrentUsage   = ErrorCause("read_power_error")
	ErrorCodePowerCapperUnavailable = ErrorCause("capper_unavailable")
	ErrorCodePowerCapCommunication  = ErrorCause("capper_communication_error")
	ErrorCodePowerEvictFailure      = ErrorCause("evict_error")
	ErrorCodeRecoverable            = ErrorCause("recoverable_error")
	ErrorCodeOther                  = ErrorCause("other_error")
)

Variables

This section is empty.

Functions

func EmitCurrentPowerUSage

func EmitCurrentPowerUSage(emitter metrics.MetricEmitter, currentWatts int)

func EmitErrorCode

func EmitErrorCode(emitter metrics.MetricEmitter, cause ErrorCause)

func EmitEvictReq

func EmitEvictReq(emitter metrics.MetricEmitter, pods int)

func EmitGetAdviceCalled added in v0.5.24

func EmitGetAdviceCalled(emitter metrics.MetricEmitter)

func EmitPowerAdvice

func EmitPowerAdvice(emitter metrics.MetricEmitter, action action.PowerAction, mode string)

func EmitPowerCapInstruction

func EmitPowerCapInstruction(emitter metrics.MetricEmitter, instruction *capper.CapInstruction)

func EmitPowerCapReset

func EmitPowerCapReset(emitter metrics.MetricEmitter)

func EmitPowerSpec

func EmitPowerSpec(emitter metrics.MetricEmitter, powerSpec *spec.PowerSpec)

Types

type ErrorCause

type ErrorCause string

Jump to

Keyboard shortcuts

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