Documentation ¶
Overview ¶
Package metrics implements the memory metrics collection and reporting.
Index ¶
- Constants
- func InitAveragers(db *sql.DB, tableName string)
- func ReadTotalBytes(ctx context.Context, since time.Time) (components_metrics_state.Metrics, error)
- func ReadUsedBytes(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 SetAvailableBytes(bytes float64)
- func SetFreeBytes(bytes float64)
- func SetLastUpdateUnixSeconds(unixSeconds float64)
- func SetTotalBytes(ctx context.Context, bytes float64, currentTime time.Time) error
- func SetUsedBytes(ctx context.Context, bytes float64, currentTime time.Time) error
- func SetUsedPercent(ctx context.Context, pct float64, currentTime time.Time) error
Constants ¶
View Source
const SubSystem = "memory"
Variables ¶
This section is empty.
Functions ¶
func InitAveragers ¶
func ReadTotalBytes ¶
func ReadUsedBytes ¶
func ReadUsedPercents ¶
func SetAvailableBytes ¶
func SetAvailableBytes(bytes float64)
func SetFreeBytes ¶
func SetFreeBytes(bytes float64)
func SetLastUpdateUnixSeconds ¶
func SetLastUpdateUnixSeconds(unixSeconds float64)
func SetTotalBytes ¶
func SetUsedBytes ¶
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.