Skip to content
This repository was archived by the owner on Nov 9, 2026. It is now read-only.
This repository was archived by the owner on Nov 9, 2026. It is now read-only.

feat: OTLP traces ingest (feature-gated) #363

Open

Description

@ajianaz

Summary

Accept OpenTelemetry OTLP traces (HTTP protobuf first, JSON second) and map them onto the existing transactions model — the gateway to non-Sentry platforms.

Why

  • Current ingest speaks only the Sentry envelope protocol, so only platforms with a Sentry SDK can report. OTLP is the vendor-neutral standard (nginx, Kubernetes, Go, Python, PHP, .NET, Swift, Kotlin, browsers) — it is how SigNoz/HyperDX/OpenObserve win the "all platforms" argument.
  • GlitchTip shipped OTel support in 6.2 (Jun 2026). TrapFall's counter stays the same: same coverage at ~6MB, SQLite-optional, zero-ops.
  • Reuse: TrapFall already models spans/transactions (migration 003). OTLP is a translation layer, not a new storage model.

Design (seams)

  • New endpoint POST /api/otlp/v1/traces behind a cargo feature flag otlp (default OFF — precedent: postgres feature keeps the default build minimal).
  • Translation module inside trapfall-ingest (new crate only if size justifies): Resource attributes → project, spans → Span/Transaction, status mapping, sampling passthrough.
  • Translate into the existing digest channel as transaction events — downstream (WebSocket broadcast, retention, APIs) unchanged.
  • Auth: per-project ingest token header or existing DSN key — decide in the PR (state the choice + rationale).

Acceptance criteria

  • OTel Collector → TrapFall: traces visible in existing transactions UI + API
  • Feature-gated; default binary size impact < 1 MB, Docker image stays ≈ 6 MB (verify, report numbers)
  • SQLite + Postgres paths tested
  • Docs: OTel Collector config snippet (README or docs site)
  • Tests: translation mapping, endpoint auth, ingest path; CI green

Non-goals

  • OTLP logs/metrics endpoints (separate issue if demanded)
  • Bundling an OTel Collector, full semantic-conventions coverage (start with http.server + DB client spans)

Notes for implementer

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions