Skip to content

Conversation

@davidgoli
Copy link

@davidgoli davidgoli commented Dec 19, 2025

Type

  • Refactor
  • Feature
  • Bug Fix
  • Optimization
  • Documentation Update

Description

Add support for Protocol Buffers binary encoding as an alternative to JSON for OTLP trace, metrics, and log exports. This enables more efficient wire format when communicating with OpenTelemetry collectors. In particular, some OTLP collectors, such as Coralogix, only support protobuf and not json.

  • Add protocol option ("json" | "protobuf") to Otlp.layer and individual OtlpTracer, OtlpMetrics, OtlpLogger layers
  • Implement protobuf wire format encoding following opentelemetry-proto specs
  • Set appropriate Content-Type header (application/x-protobuf vs application/json)
  • No new dependencies - protobuf encoding implemented from scratch

🤖 Generated with Claude Code

Related

  • Related Issue #
  • Closes #

@davidgoli davidgoli requested a review from tim-smart as a code owner December 19, 2025 20:20
@github-project-automation github-project-automation bot moved this to Discussion Ongoing in PR Backlog Dec 19, 2025
@changeset-bot
Copy link

changeset-bot bot commented Dec 19, 2025

🦋 Changeset detected

Latest commit: 27cd330

The changes in this PR will be included in the next version bump.

This PR includes changesets to release 1 package
Name Type
@effect/opentelemetry Minor

Not sure what this means? Click here to learn what changesets are.

Click here if you're a maintainer who wants to add another changeset to this PR

Add support for Protocol Buffers binary encoding as an alternative to JSON
for OTLP trace, metrics, and log exports. This enables more efficient
wire format when communicating with OpenTelemetry collectors.

- Add `protocol` option ("json" | "protobuf") to Otlp.layer and individual
  OtlpTracer, OtlpMetrics, OtlpLogger layers
- Implement protobuf wire format encoding following opentelemetry-proto specs
- Set appropriate Content-Type header (application/x-protobuf vs application/json)
- No new dependencies - protobuf encoding implemented from scratch

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Opus 4.5 <[email protected]>
@davidgoli davidgoli force-pushed the feat/otel-protobuf-support branch from 09584a8 to 27cd330 Compare December 19, 2025 20:27
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

Status: Discussion Ongoing

Development

Successfully merging this pull request may close these issues.

1 participant