TelemetryHealth
data class TelemetryHealth(val spans: PersistenceHealth, val metrics: PersistenceHealth, val logs: ExporterHealth)
Health of the local telemetry buffers, in each signal's own units.
spans and metrics count persistence turns; logs retains log-record admission and drop accounting. Do not add these counters together. None measures delivery to an OTLP collector.
Samples
val telemetry = WarpTelemetry(ReplicaId("device"), InMemoryDurableStore())
telemetry.recover()
telemetry.metrics.incrementSum(MetricKey("requests", MetricKind.SUM))
val health = telemetry.health
check(health.metrics.acknowledged == 1L)
check(health.metrics.outstandingFailures == 0L)
check(!health.metrics.recoveryFailed)
// Logs keep record units. No log records have been admitted by this instance.
check(health.logs.accepted == 0L)
check(health.spans.acknowledged == 0L)Content copied to clipboard