telemetry

package
v0.2.0 Latest Latest
Warning

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

Go to latest
Published: Oct 28, 2026 License: MIT Imports: 13 Imported by: 0

Documentation

Overview

Package telemetry records only fixed operation names and classified outcomes. Never pass caller-controlled strings as operation names or attributes.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func InjectTraceParent

func InjectTraceParent(ctx context.Context, header http.Header)

InjectTraceParent copies only the W3C traceparent from the active context. It does not use global propagators or forward baggage/tracestate.

Types

type Observer

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

func New

func (*Observer) ExportIntegrityFailure

func (o *Observer) ExportIntegrityFailure(ctx context.Context, kind string)

ExportIntegrityFailure records a failed check, never an artifact identity.

func (*Observer) ExtractionRejected

func (o *Observer) ExtractionRejected(ctx context.Context, kind string)

ExtractionRejected observes a durable pre-provider input-limit rejection.

func (*Observer) ExtractionResult

func (o *Observer) ExtractionResult(ctx context.Context, kind, outcome string, proposals, issues int)

ExtractionResult observes successful result persistence, outside transaction retry callbacks. It is operational telemetry, not an exactly-once audit count.

func (*Observer) RecallFiltered

func (o *Observer) RecallFiltered(ctx context.Context, kind string, missing, ineligible int64)

RecallFiltered records completed ledger revalidation, outside retry callbacks. Missing versions and ineligible resolutions are distinct from malformed hits, duplicate hits, wrong kinds, scope exclusions and disclosure failures.

func (*Observer) Start

func (o *Observer) Start(ctx context.Context, stage string) (context.Context, *Operation)

type Operation

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

func (*Operation) End

func (op *Operation) End(err *error)

End must be deferred directly. It never records error or panic text, and rethrows panics after recording a bounded outcome.

Jump to

Keyboard shortcuts

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