telemetry

package
v0.2.2 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Sep 27, 2026 License: Apache-2.0 Imports: 10 Imported by: 0

Documentation

Overview

Package telemetry is the agent-side raw-telemetry tier's control plane (#424, ADR 0001). It wraps the dedicated ports.TelemetryStore with the honesty contract the columnar tier must uphold: ingest is BOUNDED and BACKPRESSURED; retention is tiered with AUDITED expiry; and retro-hunts carry sampling, loss, columnar-sequence-gap, and A3 delivery-gap completeness metadata.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type IngestReport

type IngestReport struct {
	Accepted    int
	Dropped     int
	Disposition telemetry.LossDisposition
	Gap         *ports.TelemetrySequenceGap
}

type Service

type Service struct {
	// contains filtered or unexported fields
}

Service is the telemetry tier control plane. deliveryGaps is optional for legacy/test composition; production A3 wiring supplies it so hunt completeness includes transport loss.

func NewService

func NewService(store ports.TelemetryStore, audit ports.AuditLogger, clock ports.Clock, budget int) (*Service, error)

NewService preserves the original constructor for stores that do not compose A3 transport state.

func NewServiceWithDeliveryGaps added in v0.2.0

func NewServiceWithDeliveryGaps(store ports.TelemetryStore, gaps ports.TelemetryDeliveryGapReader, audit ports.AuditLogger, clock ports.Clock, budget int) (*Service, error)

NewServiceWithDeliveryGaps wires the A3 delivery-gap ledger into retro-hunt completeness. The reader is intentionally a narrow port rather than the whole transport store.

func (*Service) Footprint

func (s *Service) Footprint(ctx context.Context) (ports.TelemetryFootprint, error)

func (*Service) Hunt

Hunt combines the columnar store's own honesty metadata with the A3 transport ledger. Failing to read configured delivery gaps fails closed rather than returning a potentially false Complete=true result.

func (*Service) Ingest

func (s *Service) Ingest(ctx context.Context, batch ports.TelemetryBatch) (IngestReport, error)

func (*Service) RetroRunRule

func (*Service) Sweep

func (s *Service) Sweep(ctx context.Context) (ports.SweepReport, error)

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL