Files
nvllama-watchdog/core/metric.go
2026-10-11 12:24:01 +02:00

26 lines
409 B
Go

package core
import (
"context"
"time"
)
type Metric struct {
Name string
Help string
Type string // "counter", "gauge", "histogram"
Value float64
Labels map[string]string
Timestamp time.Time
}
type Reader interface {
Name() string
Read(ctx context.Context) ([]Metric, error)
}
type Exporter interface {
Name() string
Write(ctx context.Context, metrics []Metric) error
}