Skip to content

instrument: HTTP/OTLP transport sinks + extras matrix CI#98

Closed
mmercuri wants to merge 1 commit into
feat/instrument-base-foundationfrom
feat/instrument-transport-otlp
Closed

instrument: HTTP/OTLP transport sinks + extras matrix CI#98
mmercuri wants to merge 1 commit into
feat/instrument-base-foundationfrom
feat/instrument-transport-otlp

Conversation

@mmercuri

Copy link
Copy Markdown
Contributor

Summary

Lands the telemetry transport layer that adapter EventSinks ship
to, plus the CI gate that smoke-tests every adapter extra at both the
floor and ceiling of its declared pin range.

Scope

  • src/layerlens/instrument/transport/sink_http.pyHTTPSink,
    async batching transport for the LayerLens ingest endpoint
  • src/layerlens/instrument/transport/sink_otlp.pyOTLPHttpSink,
    hand-rolled protobuf marshalling against opentelemetry-proto so
    consumers don't pull in opentelemetry-sdk just to ship spans
  • tests/instrument/transport/test_sink_otlp.py — 27 unit tests for
    the OTLP serializer + transport
  • tests/instrument/test_sink_http_e2e.py — 9 end-to-end tests
    against a local FastAPI receiver
  • samples/instrument/otlp_collector/ — runnable sample pointing the
    OTLPHttpSink at a Collector
  • docs/adapters/otlp.md — configuration guide
  • .github/workflows/extras-matrix.yaml — per-extra pin-range matrix
    that installs every framework / protocol / provider extra at both
    its floor and ceiling and runs an import-only smoke check
  • pyproject.toml — two new optional extras
    • otelopentelemetry-api + opentelemetry-sdk +
      opentelemetry-exporter-otlp-proto-http (for callers who want
      the full SDK)
    • otlpopentelemetry-proto only (for the lean
      OTLPHttpSink path)

Blast radius

  • Default pip install layerlens install set is unchanged. Both
    transport sinks are inert until an adapter is wired to them.
  • No changes to existing public API surface.

Test plan

  • uv run pytest tests/instrument/transport/ tests/instrument/test_sink_http_e2e.py -x
    — 38 passed
  • Extras-matrix workflow exercises every adapter extra on PR

Stacks on

  • feat/instrument-base-foundation (M1.A) — required for the
    EventSink contract this PR implements.

Linear

LAY-3400 umbrella (M1 transport tier). Unblocks Track A's
LAY-3401–3404 (compat / transport / CI work).

Lands the telemetry transport layer that adapter EventSinks ship to,
plus the CI gate that smoke-tests every adapter extra at both the
floor and ceiling of its declared pin range.

Scope
-----
- src/layerlens/instrument/transport/sink_http.py: HTTPSink — async
  batching transport for the LayerLens ingest endpoint
- src/layerlens/instrument/transport/sink_otlp.py: OTLPHttpSink —
  hand-rolled protobuf marshalling against opentelemetry-proto so
  consumers don't pull in opentelemetry-sdk just to ship spans
- tests/instrument/transport/test_sink_otlp.py: 27 unit tests for
  the OTLP serializer + transport
- tests/instrument/test_sink_http_e2e.py: 9 end-to-end tests against
  a local FastAPI receiver
- samples/instrument/otlp_collector/: runnable sample pointing the
  OTLPHttpSink at a Collector
- docs/adapters/otlp.md: configuration guide
- .github/workflows/extras-matrix.yaml: per-extra pin-range matrix
  that installs every framework / protocol / provider extra at both
  its floor and ceiling and runs an import-only smoke check
- pyproject.toml: two new optional extras
  - `otel`: opentelemetry-api + opentelemetry-sdk +
    opentelemetry-exporter-otlp-proto-http (for callers who want the
    full SDK)
  - `otlp`: opentelemetry-proto only (for the lean OTLPHttpSink path)

Blast radius
------------
- Default `pip install layerlens` install set is unchanged. Both
  transport sinks are inert until an adapter is wired to them.
- No changes to existing public API surface.

Test plan
---------
- uv run pytest tests/instrument/transport/ tests/instrument/
  test_sink_http_e2e.py -x  -> 38 passed
- The extras-matrix workflow exercises every adapter extra on PR.

Stacks on
---------
- feat/instrument-base-foundation (M1.A) — required for the
  EventSink contract this PR implements.

LAY-3400 umbrella (M1 transport tier).
@mmercuri mmercuri requested a review from m-peko April 26, 2026 02:36
@mmercuri

Copy link
Copy Markdown
Contributor Author

Linear: https://linear.app/layerlens/issue/LAY-3403 (OTLP HTTP transport sink + extras-matrix CI workflow — partial LAY-3404). Stacked on PR #93. Under Apollo M1 epic LAY-3423.

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

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants