Help us shape the future of Go! Take the 2026 Go Developer Survey

ingest

package
v0.20.0 Latest Latest
Warning

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

Go to latest
Published: Oct 27, 2026 License: MIT Imports: 14 Imported by: 0

Documentation

Overview

Package ingest is Studio's OTLP/HTTP receiver (S4.4): POST /v1/traces and /v1/logs, protobuf and JSON, optional gzip, a 16 MiB limit on the decompressed body, and the publish-then-write pipeline —

decode → obsdb.FromOTLP… → publish to the live hub → DB.Write

— so the live tail never waits on the database. A write failure answers 503 so the exporter retries; the retry's duplicate live frames are dropped by the client on (run, kind, pos).

The mapping itself lives in obsdb (FromOTLPTraces/FromOTLPLogs), so the in-process local sink and this receiver produce identical rows. Auth is the caller's: the handlers take an authorized predicate (Studio: the ingest token, or loopback with none configured).

Index

Constants

View Source
const MaxBody = 16 << 20

MaxBody is the request-body limit after decompression (S4.4): 16 MiB. Above it the receiver answers 413.

Variables

This section is empty.

Functions

func Logs

func Logs(db obsdb.DB, hub obsdb.Hub, authorized func(*http.Request) bool) http.HandlerFunc

Logs returns the POST /v1/logs handler: decode, publish, write.

func Traces

func Traces(db obsdb.DB, hub obsdb.Hub, authorized func(*http.Request) bool) http.HandlerFunc

Traces returns the POST /v1/traces handler: decode, publish, write.

Types

This section is empty.

Jump to

Keyboard shortcuts

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