Documentation
¶
Overview ¶
Package hostprobe reads host facts an executor reports about itself: the kernel clock discipline and the host platform. Every probe is read-only and local; none changes host state, contacts a time source or sends a packet.
Index ¶
Constants ¶
const ( ClockSynced = "synced" ClockUnsynced = "unsynced" ClockUnknown = "unknown" )
Clock states.
const ( ReadinessReady = "ready" ReadinessDegraded = "degraded" ReadinessUnknown = "unknown" ReasonUnsynced = "unsynced" ReasonErrorExceedsBound = "error_exceeds_bound" )
Clock readiness and its degraded reasons.
const DefaultClockErrorBound = 100 * time.Millisecond
DefaultClockErrorBound is the estimated clock error above which an executor reports its clock readiness as degraded unless the operator configures a different bound.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Clock ¶
type Clock struct {
State string
EstimatedError *time.Duration
MaxError *time.Duration
Bound time.Duration
Readiness string
Reason string
}
Clock is the kernel's view of its own clock discipline. EstimatedError and MaxError are the kernel's esterror and maxerror, maintained by a time daemon such as chrony or ntpd; they are estimates, not measured bounds.
type Platform ¶
type Platform struct {
OS string
Arch string
KernelRelease string
CPUs int
MemoryBytes uint64
BuildVersion string
}
Platform describes the host an executor runs on. Empty and zero values are unknown. It is operator-only data: the dispatcher never lists it publicly.
func ReadPlatform ¶
func ReadPlatform() Platform
ReadPlatform reads the platform facts. It never fails; a fact that cannot be read is left unknown.