Documentation ¶
Overview ¶
Package metrics implements the CPU metrics collection and reporting.
Index ¶
- Constants
- func InitAveragers(db *sql.DB, tableName string)
- func ReadLoadAverage5mins(ctx context.Context, since time.Time) (components_metrics_state.Metrics, error)
- func ReadUsedPercents(ctx context.Context, since time.Time) (components_metrics_state.Metrics, error)
- func Register(reg *prometheus.Registry, db *sql.DB, tableName string) error
- func SetLastUpdateUnixSeconds(unixSeconds float64)
- func SetLoadAverage(ctx context.Context, duration time.Duration, avg float64, ...) error
- func SetUsedPercent(ctx context.Context, pct float64, currentTime time.Time) error
Constants ¶
View Source
const SubSystem = "cpu"
Variables ¶
This section is empty.
Functions ¶
func InitAveragers ¶
func ReadLoadAverage5mins ¶
func ReadUsedPercents ¶
func SetLastUpdateUnixSeconds ¶
func SetLastUpdateUnixSeconds(unixSeconds float64)
func SetLoadAverage ¶
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.