Skip to content

feat(data-pipeline)!: OTLP gRPC trace export - #2171

Merged
gh-worker-dd-mergequeue-cf854d[bot] merged 10 commits into
mainfrom
brian.marks/otlp-grpc-trace-export
Sep 9, 2026
Merged

gh-worker-dd-mergequeue-cf854d[bot] merged 10 commits into
mainfrom
brian.marks/otlp-grpc-trace-export

Conversation

@bm1549

@bm1549 bm1549 commented Jun 26, 2026 •

Copy link
Copy Markdown
Contributor

What does this PR do?

Adds OTLP gRPC as a trace-export transport, selectable with OTEL_EXPORTER_OTLP_TRACES_PROTOCOL=grpc. OtlpProtocol gains a Grpc variant, and TraceExporter dispatches through OtlpExportMode (Http or Grpc). The gRPC path limits response bodies to 4 MiB and reports partial-success responses. Remote-status diagnostics retain the original gRPC code. OTLP resource metadata is built once when the exporter is constructed, including the client-computed-stats marker. gRPC is native-only; wasm32 rejects it during build. The FFI accepts grpc, so SDKs using libdatadog can select the transport.

The transport validates its dial authority before creating the exporter. Portless http:// endpoints use port 80. Valid explicit DNS and IPv6 ports are preserved; empty hosts, malformed ports, and userinfo are rejected. Retryable gRPC errors use bounded exponential backoff with jitter. RESOURCE_EXHAUSTED is retried only when the server supplies google.rpc.RetryInfo. A positive server delay is used as the backoff base when it fits within the 30-second retry budget; longer delays stop retries instead of retrying before the server requested. Zero or missing delays use the existing 100 ms base. Protobuf requests are shared across attempts instead of deep-cloned.

The fork-safe gRPC transport primitive landed in #2273. This PR integrates it with the exporter and FFI and includes the transport hardening found during review. Completed responses now win over subsequent connection teardown, and transient HTTP/2 stream resets are classified as retryable transport errors. Remote gRPC statuses keep their code and status classification instead of being reported as local I/O failures. The gRPC path sends the standard libdatadog user-agent and entity headers and emits the native trace-export telemetry now used by the other transports.

Motivation

libdatadog's OTLP trace export was HTTP-only. Java and .NET implement gRPC OTLP separately; PHP, Python, Ruby, and Rust use libdatadog for trace export. Adding gRPC here lets their integrations honor OTEL_EXPORTER_OTLP_TRACES_PROTOCOL=grpc instead of rejecting it or falling back to another transport.

Additional Notes

  • The transport from feat(data-pipeline): add fork-safe OTLP gRPC trace transport #2273 is a custom tonic GrpcService over hyper h2c. It creates a connection per request and has no persistent worker, which keeps it safe across forks.
  • OtlpProtocol::from_str("grpc") now succeeds. Adding a variant to the exhaustive public enum is a breaking change, as noted in the commit footer.
  • Transient IO and the retryable gRPC codes (Cancelled, Aborted, OutOfRange, DataLoss, Unavailable, and DeadlineExceeded) get OTLP_MAX_RETRIES + 1 total attempts. RetryInfo controls recoverable throttling delays; other retries use the existing 100 ms exponential base, with up to 100 ms of jitter.
  • Remote gRPC statuses map to compatible HTTP statuses for the existing RequestError and FFI error classification, while retaining the gRPC code in the message.
  • Both OTLP transports preserve .set_client_computed_stats() in the resource attributes and request metadata.
  • The current transport is plaintext h2c. TLS support and an FFI setter for custom OTLP headers remain follow-ups; the FFI header limitation also applies to HTTP OTLP.

How to test the change?

  • cargo check -p libdd-data-pipeline
  • cargo +nightly-2026-07-26 fmt --all -- --check
  • cargo +stable clippy -p libdd-data-pipeline --all-targets --no-deps -- -D warnings
  • cargo +nightly clippy -p libdd-data-pipeline --test test_trace_exporter_otlp_grpc -- -D warnings
  • cargo +1.87.0 check -p libdd-data-pipeline --test test_trace_exporter_otlp_grpc
  • cargo nextest run -p libdd-data-pipeline -E '!test(tracing_integration_tests::)' (204 passed; 7 Docker-backed integration tests skipped locally)
  • cargo test -p libdd-data-pipeline grpc --lib (34 passed)
  • cargo test -p libdd-data-pipeline --test test_trace_exporter_otlp_grpc (2 passed)
  • cargo test -p libdd-data-pipeline --doc (2 passed)
  • cargo check -p libdd-data-pipeline --target wasm32-unknown-unknown --no-default-features
  • cargo ffi-test --skip-build --filter trace_exporter (1 passed; the full FFI build succeeded)
  • cargo +stable clippy -p libdd-data-pipeline --all-targets -- -D warnings currently stops on a pre-existing collapsible_match warning in libdd-trace-utils/src/tracer_payload.rs, which this PR does not modify.

@bm1549 bm1549 added the AI Generated PR largely written by AI tools label Jun 26, 2026
@datadog-official

datadog-official Bot commented Jun 26, 2026 •

Copy link
Copy Markdown

Tests

🎉 All green!

🧪 All tests passed
❄️ No new flaky tests detected

🔄 Datadog auto-retried 2 jobs - 0 passed on retry View in Datadog

🎯 Code Coverage (details)
• Patch Coverage: 90.36%
• Overall Coverage: 77.62% (-0.05%)

This comment will be updated automatically if new data arrives.
🔗 Commit SHA: 2b21167 | Docs | View more details | Give us feedback!

bm1549 added a commit that referenced this pull request Jun 27, 2026
The in-process exporter<->h2-server round trip is too timing-sensitive for
heavily contended CI runners: the client `send` has hit its request timeout on
macos-15 (GitHub) and the alpine/arm release-build matrix (GitLab) across
multiple runs, despite passing locally (20/20) and on less-loaded runners, and
despite the live backend verification in PR #2171 succeeding.

Mark it #[ignore] so it no longer runs in the default CI suites (it can't flake
the PR or burn release-build runner time), while keeping it runnable on demand
via `--run-ignored all`. The gRPC export path stays covered by this crate's unit
tests (ProstCodec, grpc_status_to_error, attach_metadata, build_grpc_channel,
builder dispatch, protocol parse) and by the live backend verification.

Co-Authored-By: Claude Sonnet 4.6 (1M context) <noreply@anthropic.com>
@dd-octo-sts

dd-octo-sts Bot commented Jun 27, 2026 •

Copy link
Copy Markdown
Contributor

Artifact Size Benchmark Report

aarch64-alpine-linux-musl
Artifact Baseline Commit Change
/aarch64-alpine-linux-musl/lib/libdatadog_profiling.so 8.45 MB 8.96 MB +5.98% (+518.42 KB) 🚨
/aarch64-alpine-linux-musl/lib/libdatadog_profiling.a 91.37 MB 95.57 MB +4.59% (+4.20 MB) ⚠️
aarch64-unknown-linux-gnu
Artifact Baseline Commit Change
/aarch64-unknown-linux-gnu/lib/libdatadog_profiling.so 11.38 MB 12.11 MB +6.32% (+737.44 KB) 🚨
/aarch64-unknown-linux-gnu/lib/libdatadog_profiling.a 102.71 MB 106.92 MB +4.09% (+4.20 MB) ⚠️
libdatadog-x64-windows
Artifact Baseline Commit Change
/libdatadog-x64-windows/debug/dynamic/datadog_profiling_ffi.dll 27.36 MB 28.91 MB +5.69% (+1.55 MB) 🚨
/libdatadog-x64-windows/debug/dynamic/datadog_profiling_ffi.lib 96.08 KB 96.08 KB 0% (0 B) 👌
/libdatadog-x64-windows/debug/dynamic/datadog_profiling_ffi.pdb 185.94 MB 191.08 MB +2.76% (+5.14 MB) ⚠️
/libdatadog-x64-windows/debug/static/datadog_profiling_ffi.lib 804.22 MB 810.01 MB +.72% (+5.79 MB) 🔍
/libdatadog-x64-windows/release/dynamic/datadog_profiling_ffi.dll 9.03 MB 9.65 MB +6.83% (+632.00 KB) 🚨
/libdatadog-x64-windows/release/dynamic/datadog_profiling_ffi.lib 96.08 KB 96.08 KB 0% (0 B) 👌
/libdatadog-x64-windows/release/dynamic/datadog_profiling_ffi.pdb 26.27 MB 27.37 MB +4.19% (+1.10 MB) ⚠️
/libdatadog-x64-windows/release/static/datadog_profiling_ffi.lib 52.70 MB 55.31 MB +4.95% (+2.61 MB) ⚠️
libdatadog-x86-windows
Artifact Baseline Commit Change
/libdatadog-x86-windows/debug/dynamic/datadog_profiling_ffi.dll 23.80 MB 25.26 MB +6.12% (+1.45 MB) 🚨
/libdatadog-x86-windows/debug/dynamic/datadog_profiling_ffi.lib 97.58 KB 97.58 KB 0% (0 B) 👌
/libdatadog-x86-windows/debug/dynamic/datadog_profiling_ffi.pdb 190.71 MB 196.27 MB +2.91% (+5.56 MB) ⚠️
/libdatadog-x86-windows/debug/static/datadog_profiling_ffi.lib 792.04 MB 795.90 MB +.48% (+3.86 MB) 🔍
/libdatadog-x86-windows/release/dynamic/datadog_profiling_ffi.dll 6.96 MB 7.46 MB +7.07% (+505.00 KB) 🚨
/libdatadog-x86-windows/release/dynamic/datadog_profiling_ffi.lib 97.58 KB 97.58 KB 0% (0 B) 👌
/libdatadog-x86-windows/release/dynamic/datadog_profiling_ffi.pdb 28.21 MB 29.44 MB +4.37% (+1.23 MB) ⚠️
/libdatadog-x86-windows/release/static/datadog_profiling_ffi.lib 49.74 MB 52.22 MB +4.98% (+2.48 MB) ⚠️
x86_64-alpine-linux-musl
Artifact Baseline Commit Change
/x86_64-alpine-linux-musl/lib/libdatadog_profiling.a 81.56 MB 85.61 MB +4.96% (+4.04 MB) ⚠️
/x86_64-alpine-linux-musl/lib/libdatadog_profiling.so 9.42 MB 9.99 MB +6.07% (+586.40 KB) 🚨
x86_64-unknown-linux-gnu
Artifact Baseline Commit Change
/x86_64-unknown-linux-gnu/lib/libdatadog_profiling.a 97.38 MB 101.51 MB +4.24% (+4.13 MB) ⚠️
/x86_64-unknown-linux-gnu/lib/libdatadog_profiling.so 11.48 MB 12.20 MB +6.31% (+742.41 KB) 🚨

@bm1549
bm1549 marked this pull request as ready for review June 29, 2026 17:17
@bm1549
bm1549 requested review from a team as code owners June 29, 2026 17:17
@bm1549
bm1549 requested review from vpellan and removed request for a team June 29, 2026 17:17

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: 9dcddce271

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

Comment thread libdd-data-pipeline/src/otlp/grpc_exporter.rs Outdated
Comment thread libdd-data-pipeline/src/otlp/grpc_exporter.rs Outdated
bm1549 added a commit that referenced this pull request Jul 10, 2026
The in-process exporter<->h2-server round trip is too timing-sensitive for
heavily contended CI runners: the client `send` has hit its request timeout on
macos-15 (GitHub) and the alpine/arm release-build matrix (GitLab) across
multiple runs, despite passing locally (20/20) and on less-loaded runners, and
despite the live backend verification in PR #2171 succeeding.

Mark it #[ignore] so it no longer runs in the default CI suites (it can't flake
the PR or burn release-build runner time), while keeping it runnable on demand
via `--run-ignored all`. The gRPC export path stays covered by this crate's unit
tests (ProstCodec, grpc_status_to_error, attach_metadata, build_grpc_channel,
builder dispatch, protocol parse) and by the live backend verification.

Co-Authored-By: Claude Sonnet 4.6 (1M context) <noreply@anthropic.com>
@bm1549
bm1549 force-pushed the brian.marks/otlp-grpc-trace-export branch from 9dcddce to 093ed21 Compare July 10, 2026 22:35
@pr-commenter

pr-commenter Bot commented Jul 10, 2026 •

Copy link
Copy Markdown

Benchmarks

Comparison

Benchmark execution time: 2026-09-09 17:29:58

Comparing candidate commit 2b21167 in PR branch brian.marks/otlp-grpc-trace-export with baseline commit d0cf2b4 in branch main.

📊 Benchmarking dashboard

Found 0 performance improvements and 0 performance regressions! Performance is the same for 108 metrics, 0 unstable metrics.

Explanation

This is an A/B test comparing a candidate commit's performance against that of a baseline commit. Performance changes are noted in the tables below as:

  • 🟩 = significantly better candidate vs. baseline
  • 🟥 = significantly worse candidate vs. baseline

We compute a confidence interval (CI) over the relative difference of means between metrics from the candidate and baseline commits, considering the baseline as the reference.

If the CI is entirely outside the configured SIGNIFICANT_IMPACT_THRESHOLD (or the deprecated UNCONFIDENCE_THRESHOLD), the change is considered significant.

Feel free to reach out to #apm-benchmarking-platform on Slack if you have any questions.

More details about the CI and significant changes

You can imagine this CI as a range of values that is likely to contain the true difference of means between the candidate and baseline commits.

CIs of the difference of means are often centered around 0%, because often changes are not that big:

---------------------------------(------|---^--------)-------------------------------->
                              -0.6%    0%  0.3%     +1.2%
                                 |          |        |
         lower bound of the CI --'          |        |
sample mean (center of the CI) -------------'        |
         upper bound of the CI ----------------------'

As described above, a change is considered significant if the CI is entirely outside the configured SIGNIFICANT_IMPACT_THRESHOLD (or the deprecated UNCONFIDENCE_THRESHOLD).

For instance, for an execution time metric, this confidence interval indicates a significantly worse performance:

----------------------------------------|---------|---(---------^---------)---------->
                                       0%        1%  1.3%      2.2%      3.1%
                                                  |   |         |         |
       significant impact threshold --------------'   |         |         |
                      lower bound of CI --------------'         |         |
       sample mean (center of the CI) --------------------------'         |
                      upper bound of CI ----------------------------------'

Benchmark execution time: 2026-09-09 17:32:47

Comparing candidate commit 2b21167 in PR branch brian.marks/otlp-grpc-trace-export with baseline commit d0cf2b4 in branch main.

📊 Benchmarking dashboard

Found 2 performance improvements and 3 performance regressions! Performance is the same for 103 metrics, 10 unstable metrics.

Explanation

This is an A/B test comparing a candidate commit's performance against that of a baseline commit. Performance changes are noted in the tables below as:

  • 🟩 = significantly better candidate vs. baseline
  • 🟥 = significantly worse candidate vs. baseline

We compute a confidence interval (CI) over the relative difference of means between metrics from the candidate and baseline commits, considering the baseline as the reference.

If the CI is entirely outside the configured SIGNIFICANT_IMPACT_THRESHOLD (or the deprecated UNCONFIDENCE_THRESHOLD), the change is considered significant.

Feel free to reach out to #apm-benchmarking-platform on Slack if you have any questions.

More details about the CI and significant changes

You can imagine this CI as a range of values that is likely to contain the true difference of means between the candidate and baseline commits.

CIs of the difference of means are often centered around 0%, because often changes are not that big:

---------------------------------(------|---^--------)-------------------------------->
                              -0.6%    0%  0.3%     +1.2%
                                 |          |        |
         lower bound of the CI --'          |        |
sample mean (center of the CI) -------------'        |
         upper bound of the CI ----------------------'

As described above, a change is considered significant if the CI is entirely outside the configured SIGNIFICANT_IMPACT_THRESHOLD (or the deprecated UNCONFIDENCE_THRESHOLD).

For instance, for an execution time metric, this confidence interval indicates a significantly worse performance:

----------------------------------------|---------|---(---------^---------)---------->
                                       0%        1%  1.3%      2.2%      3.1%
                                                  |   |         |         |
       significant impact threshold --------------'   |         |         |
                      lower bound of CI --------------'         |         |
       sample mean (center of the CI) --------------------------'         |
                      upper bound of CI ----------------------------------'

scenario:credit_card/is_card_number_no_luhn/378282246310005

  • 🟩 execution_time [-10.149µs; -10.066µs] or [-15.621%; -15.494%]
  • 🟩 throughput [+2824213.423op/s; +2847343.095op/s] or [+18.349%; +18.499%]

scenario:datadog_sample_span/complex_rule_partial_match/wall_time

  • 🟥 execution_time [+13.174ns; +13.316ns] or [+5.611%; +5.672%]

scenario:trace_buffer/4_senders/no_delay

  • 🟥 execution_time [+125.528µs; +155.919µs] or [+5.519%; +6.855%]
  • 🟥 throughput [-104209.627op/s; -83469.838op/s] or [-6.573%; -5.265%]

Unstable benchmarks

These benchmarks have a confidence interval too wide to call a change; treat them as noise rather than signal.

scenario:datadog_sample_span/parent_not_sampled_short_circuit/allocated_bytes

  • unstable execution_time [-0.000ns; +0.000ns] or [+555.542%; -555.644%]

scenario:datadog_sample_span/parent_sampled_short_circuit/allocated_bytes

  • unstable execution_time [-0.000ns; +0.000ns] or [+554.775%; -555.283%]

scenario:glob_matcher/ascii_case_insensitive_match/allocated_bytes

  • unstable execution_time [-0.000ns; +0.000ns] or [+555.735%; -555.735%]

scenario:glob_matcher/ascii_exact_match/allocated_bytes

  • unstable execution_time [-0.000ns; +0.000ns] or [+554.622%; -555.211%]

scenario:glob_matcher/ascii_exact_miss/allocated_bytes

  • unstable execution_time [-0.000ns; +0.000ns] or [+551.857%; -553.913%]

scenario:glob_matcher/ascii_wildcard_backtrack_match/allocated_bytes

  • unstable execution_time [-0.000ns; +0.000ns] or [+554.968%; -555.374%]

scenario:glob_matcher/ascii_wildcard_heavy_backtrack/allocated_bytes

  • unstable execution_time [-0.000ns; +0.000ns] or [+554.034%; -554.935%]

scenario:glob_matcher/ascii_wildcard_question_match/allocated_bytes

  • unstable execution_time [-0.000ns; +0.000ns] or [+558.830%; -557.194%]

scenario:glob_matcher/ascii_wildcard_star_match/allocated_bytes

  • unstable execution_time [-0.000ns; +0.000ns] or [+565.204%; -560.215%]

scenario:glob_matcher/star_short_circuit/allocated_bytes

  • unstable execution_time [-0.000ns; +0.000ns] or [+554.289%; -555.055%]

Candidate

Omitted due to size.

Baseline

Omitted due to size.

@yannham yannham left a comment •

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

First, apologies for waiting so long before giving you a first review. We'll avoid that kind of delay in the future.

As far as the PR goes, I have left a bunch of comments but there's no big technical blocker on my side. However I can't approve right away because the size impact is quite important. We don't have binary size quality gates (yet), but downstream consumers of libdatadog (tracers) do, which can lead to an unfortunate situation where this would get merged but tracers would be unable to update to future releases.

A first naive question: could/should this be feature-gated? I assume you'd want all tracers to support otlp out of the box, so the answers might be no, bu asking just in case.

A good test for the impact of the binary size increase: would you mind trying to create a PR against dd-trace-py pointing to this PR's libdatadog ref, and see if it triggers the size gates for e.g. serverless?

Comment thread libdd-data-pipeline/benches/otlp_grpc_export.rs Outdated
Comment thread libdd-data-pipeline/src/otlp/config.rs Outdated
Comment thread libdd-data-pipeline/src/otlp/config.rs Outdated
Comment thread libdd-data-pipeline/src/otlp/config.rs Outdated
Comment thread libdd-data-pipeline/src/otlp/config.rs Outdated
Comment thread libdd-data-pipeline/src/trace_exporter/mod.rs Outdated
Comment thread libdd-data-pipeline/src/trace_exporter/mod.rs Outdated
Comment thread libdd-data-pipeline/src/trace_exporter/mod.rs Outdated
Comment thread libdd-data-pipeline/Cargo.toml Outdated
Comment thread libdd-data-pipeline/tests/test_trace_exporter_otlp_grpc.rs
@yannham

yannham commented Jul 23, 2026

Copy link
Copy Markdown
Contributor

So, we've had a discussion with @VianneyRuhlmann about the whole worker situation. We believe we can side-step the "task in the background that needs to be restared" entirely by plugging in our own GrpcService implementation. It seems tonic provides a complicated default implementation through Channel with this background tower Service that reads through a channel and whatnot. But it's customizable and we can provide our own implementation of GrpcService instead, which seems to be rather simple (basically send some request). Doing so there's no background task anymore, we can get rid of the wait channel, and of the worker as well. It might even be possible to remove the "transport" feature entirely and save some binary size, though this has to be seen.

@bm1549
bm1549 force-pushed the brian.marks/otlp-grpc-trace-export branch from 093ed21 to 812e43b Compare July 24, 2026 20:44
@bm1549
bm1549 changed the base branch from main to brian.marks/otlp-grpc-transport July 24, 2026 20:44
@bm1549
bm1549 marked this pull request as draft July 24, 2026 20:44
@bm1549 bm1549 changed the title feat(data-pipeline): OTLP gRPC trace export feat(data-pipeline)!: OTLP gRPC trace export Jul 24, 2026
gh-worker-dd-mergequeue-cf854d Bot pushed a commit to DataDog/dd-trace-py that referenced this pull request Aug 5, 2026
## Description

When native OTLP trace export fails, `NativeWriter` currently reports its configured Datadog Agent intake URL even though libdatadog attempted the OTLP endpoint. This makes an OTLP protocol or connectivity error look like an Agent fallback.

Use the configured OTLP trace endpoint in failure diagnostics whenever OTLP trace export is active. Agent export diagnostics keep their existing behavior.

The original investigation also exposed a separate protocol mismatch: released versions send OTLP traces over HTTP/JSON, while the repro targeted the collector's gRPC port. HTTP/protobuf and gRPC support are already tracked by #18609, DataDog/libdatadog#2171, and DataDog/libdatadog#2273; this PR does not duplicate those transport changes.

## Testing

- `scripts/run-tests --venv 1ef5a52 -- -- tests/tracer/test_writer.py -k 'native_writer_reports_otlp_intake_endpoint or native_writer_stores_otlp_endpoint'` (Python 3.13; 2 passed)
- `scripts/lint checks`
- `scripts/lint style -- ddtrace/internal/writer/writer.py tests/tracer/test_writer.py`
- `scripts/lint spelling -- releasenotes/notes/fix-otlp-export-error-endpoint-6e7b7c8f756ef3a7.yaml`
- `riot run reno lint`

## Risks

Low. The change only affects the endpoint displayed in trace-export failure diagnostics when an OTLP endpoint is configured. It does not change routing, serialization, or retry behavior.

## Additional Notes

The OTLP/DDOT reference and the original handoff document were corrected separately to record that the old port-4317 reproduction was testing an HTTP exporter against a gRPC receiver.


Co-authored-by: munir.abdinur <munir.abdinur@datadoghq.com>
Base automatically changed from brian.marks/otlp-grpc-transport to main September 1, 2026 17:15
@bm1549
bm1549 force-pushed the brian.marks/otlp-grpc-trace-export branch from 812e43b to 13656d6 Compare September 1, 2026 18:52
Wires OTLP gRPC trace export into TraceExporter on top of the fork-safe
gRPC transport, selectable via OTEL_EXPORTER_OTLP_TRACES_PROTOCOL=grpc.

OtlpProtocol gains a Grpc variant; the exporter dispatches through a new
OtlpExportMode (Http | Grpc) to either the existing HTTP path or the gRPC
transport (send_otlp_traces_grpc), with bounded exponential retry on
transient IO matching the HTTP path. The OTLP resource info is built once
at construction and shared by both paths. gRPC is native-only; wasm32
rejects it at build time. Includes a public-API end-to-end gRPC export test.

BREAKING CHANGE: adds the Grpc variant to the exhaustive public OtlpProtocol
enum, so exhaustive matches on it must add an arm. libdatadog consumers pin
by version and pick this up on the next release.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
@bm1549
bm1549 force-pushed the brian.marks/otlp-grpc-trace-export branch from 13656d6 to f0e93c2 Compare September 1, 2026 19:17
@bm1549
bm1549 marked this pull request as ready for review September 1, 2026 20:39
@chatgpt-codex-connector

chatgpt-codex-connector Bot commented Sep 1, 2026 •

Copy link
Copy Markdown

Codex Review Summary

This comment shows the latest Codex review activity on this pull request.

Review Status Commit Review trigger
📝 Code Review ✅ Completed 2026-09-01T20:44:13.710778Z f0e93c2 Draft marked ready
ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review" or "@codex security review".

Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings.

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: f0e93c2dce

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

Comment thread libdd-data-pipeline/src/trace_exporter/builder.rs
Comment thread libdd-data-pipeline/src/otlp/grpc_exporter.rs Outdated
Default portless HTTP endpoints to port 80 while rejecting ambiguous authorities. Decode google.rpc.RetryInfo locally to avoid another tonic dependency, retry recoverable resource exhaustion with capped exponential delays, and share protobuf requests across attempts.
@bm1549
bm1549 requested a review from a team as a code owner September 1, 2026 21:43
Comment thread libdd-data-pipeline/src/trace_exporter/builder.rs
Comment thread libdd-data-pipeline/src/trace_exporter/mod.rs Outdated
Comment thread libdd-data-pipeline/src/trace_exporter/mod.rs Outdated
Comment thread libdd-data-pipeline/src/otlp/grpc_exporter.rs Outdated
Comment thread libdd-data-pipeline/src/otlp/grpc_exporter.rs
@bm1549
bm1549 requested a review from a team as a code owner September 3, 2026 01:12

@mabdinur mabdinur left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Reviewed the current head, including the per-request gRPC transport lifecycle, endpoint validation, retry/status handling, OTLP metadata, FFI selection, and target gating. Focused compile, format, clippy, tests, docs, and FFI validation pass locally. I found no blocking correctness issues.

@gh-worker-dd-mergequeue-cf854d
gh-worker-dd-mergequeue-cf854d Bot merged commit a2a1dfb into main Sep 9, 2026
102 of 107 checks passed
@gh-worker-dd-mergequeue-cf854d
gh-worker-dd-mergequeue-cf854d Bot deleted the brian.marks/otlp-grpc-trace-export branch September 9, 2026 18:29
paullegranddc added a commit that referenced this pull request Sep 24, 2026
…ibdd-data-pipeline, libdd-li... (#2571)

<!-- release-proposal-inputs: {"crates":"libdd-capabilities-impl,
libdd-common, libdd-data-pipeline, libdd-library-config,
libdd-profiling-heap-allocator, libdd-remote-config, libdd-sampling,
libdd-shared-runtime, libdd-telemetry, libdd-tinybytes,
libdd-trace-utils","main_start_ref":"","level_overrides":"","bypass_standard_checks":false}
-->

# Release proposal for libdd-capabilities-impl, libdd-common,
libdd-data-pipeline, libdd-library-config,
libdd-profiling-heap-allocator, libdd-remote-config, libdd-sampling,
libdd-shared-runtime, libdd-telemetry, libdd-tinybytes,
libdd-trace-utils and their dependencies

This PR contains version bumps based on public API changes and commits
since last release.


### ⚠️ Crates left out of this proposal affected by its major
bumps

These publishable workspace crates are not part of this release but
their dependency requirement was rewritten on this branch while their
published version still requires the old major. If they are a dependency
on your deployment not including them in the release could result in
duplicate packages or symbol incompatibility.

- `libdd-capabilities` `3.0.1` → `4.0.0` affects: `libdd-crashtracker`,
`libdd-ffe`, `libdd-live-debugger`
- `libdd-capabilities-impl` `5.0.0` → `6.0.0` affects:
`libdd-crashtracker`, `libdd-live-debugger`, `libdd-tracer-flare`
- `libdd-common` `6.0.0` → `7.0.0` affects: `libdd-crashtracker`,
`libdd-ffe`, `libdd-http-client`, `libdd-ipc`, `libdd-live-debugger`,
`libdd-profiling`, `libdd-tracer-flare`
- `libdd-data-pipeline` `10.0.0` → `11.0.0` affects:
`libdd-live-debugger`
- `libdd-remote-config` `5.0.0` → `6.0.0` affects: `libdd-ffe`,
`libdd-live-debugger`, `libdd-tracer-flare`
- `libdd-telemetry` `8.0.0` → `9.0.0` affects: `libdd-crashtracker`
- `libdd-trace-stats` `9.0.0` → `10.0.0` affects: `libdd-ipc`
- `libdd-trace-utils` `12.0.0` → `13.0.0` affects: `libdd-tracer-flare`

## libdd-capabilities
**Next version:** `4.0.0`
**Semver bump:** `major`
**Tag:** `libdd-capabilities-v4.0.0`

### Commits

- feat(trace-exporter)!: add API to force flush stats on the trace
exporter (#2538)
- refactor!: apply small timeout pooling strategy to libdd-http-client
as well (#2449)
- chore: move all remaining external deps to workspace-level
dependencies (#2476)

## libdd-common
**Next version:** `7.0.0`
**Semver bump:** `major`
**Tag:** `libdd-common-v7.0.0`

### Commits

- build: enforce workspace-level dependency declarations (#2514)
- chore!: remove unused dependencies (v2) (#2511)
- chore: move all remaining external deps to workspace-level
dependencies (#2476)
- chore(libdd-data-pipeline): solve cargo deny [APMSP-3884] (#2318)
- fix!: benchmark was doing many samples for deterministic heap usage
(#2465)

## libdd-ddsketch
**Next version:** `1.1.2`
**Semver bump:** `patch`
**Tag:** `libdd-ddsketch-v1.1.2`

### Commits

- chore: move all remaining external deps to workspace-level
dependencies (#2476)
- chore(libdd-data-pipeline): solve cargo deny [APMSP-3884] (#2318)

## libdd-profiling-heap-sampler
**Next version:** `1.1.0`
**Semver bump:** `minor`
**Tag:** `libdd-profiling-heap-sampler-v1.1.0`

### Commits

- chore: move all remaining external deps to workspace-level
dependencies (#2476)
- refactor: migrate to workspace dependencies, phase 4 (#2296)
- feat(profiling): add USDT semaphores to skip slow path around heap
profile sampler (#2266)

## libdd-tinybytes
**Next version:** `1.1.4`
**Semver bump:** `patch`
**Tag:** `libdd-tinybytes-v1.1.4`

### Commits

- chore: move all remaining external deps to workspace-level
dependencies (#2476)

## libdd-trace-protobuf
**Next version:** `5.0.1`
**Semver bump:** `patch`
**Tag:** `libdd-trace-protobuf-v5.0.1`

### Commits

- chore: move all remaining external deps to workspace-level
dependencies (#2476)
- fix(build): build script change detection (#2467)

## libdd-capabilities-impl
**Next version:** `6.0.0`
**Semver bump:** `major`
**Tag:** `libdd-capabilities-impl-v6.0.0`

### ⚠️ major bump forced due to:

- `libdd-capabilities`: ^3.0.1 → ^4.0.0
- `libdd-common`: ^6.0.0 → ^7.0.0

### Commits

- refactor!: apply small timeout pooling strategy to libdd-http-client
as well (#2449)
- fix(sidecar)!: stabilize the sidecar for macos usage (#2475)
- chore: move all remaining external deps to workspace-level
dependencies (#2476)

## libdd-profiling-heap-allocator
**Next version:** `1.1.0`
**Semver bump:** `minor`
**Tag:** `libdd-profiling-heap-allocator-v1.1.0`

### Commits

- refactor(benchmarks): measure allocator thread CPU time (#2500)
- refactor: migrate to workspace dependencies, phase 4 (#2296)
- feat(profiling): add USDT semaphores to skip slow path around heap
profile sampler (#2266)

## libdd-library-config
**Next version:** `4.1.0`
**Semver bump:** `minor`
**Tag:** `libdd-library-config-v4.1.0`

### Commits

- chore!: remove unused dependencies (v2) (#2511)
- chore: move all remaining external deps to workspace-level
dependencies (#2476)

## libdd-trace-normalization
**Next version:** `4.1.0`
**Semver bump:** `minor`
**Tag:** `libdd-trace-normalization-v4.1.0`

### Commits

- chore: move all remaining external deps to workspace-level
dependencies (#2476)
- chore(libdd-data-pipeline): solve cargo deny [APMSP-3884] (#2318)

## libdd-remote-config
**Next version:** `6.0.0`
**Semver bump:** `major`
**Tag:** `libdd-remote-config-v6.0.0`

### ⚠️ major bump forced due to:

- `libdd-capabilities`: ^3.0.1 → ^4.0.0
- `libdd-capabilities-impl`: ^5.0.0 → ^6.0.0
- `libdd-common`: ^6.0.0 → ^7.0.0

### Commits

- refactor!: apply small timeout pooling strategy to libdd-http-client
as well (#2449)
- chore!: remove unused dependencies (v2) (#2511)
- fix(rem-cfg)!: remove AsmRawResponseBody (#2540)
- chore: move all remaining external deps to workspace-level
dependencies (#2476)

## libdd-shared-runtime
**Next version:** `5.0.0`
**Semver bump:** `major`
**Tag:** `libdd-shared-runtime-v5.0.0`

### ⚠️ major bump forced due to:

- `libdd-capabilities`: ^3.0.1 → ^4.0.0
- `libdd-capabilities-impl`: ^5.0.0 → ^6.0.0
- `libdd-common`: ^6.0.0 → ^7.0.0

### Commits

- feat(trace-exporter)!: add API to force flush stats on the trace
exporter (#2538)
- chore: move all remaining external deps to workspace-level
dependencies (#2476)

## libdd-trace-utils
**Next version:** `13.0.0`
**Semver bump:** `major`
**Tag:** `libdd-trace-utils-v13.0.0`

### ⚠️ major bump forced due to:

- `libdd-capabilities`: ^3.0.1 → ^4.0.0
- `libdd-capabilities-impl`: ^5.0.0 → ^6.0.0
- `libdd-common`: ^6.0.0 → ^7.0.0

### Commits

- fix(trace-utils)!: add forgotten css to agentless v1 encoder (#2557)
- fix(otlp): use potential dedupe in otlp serialization path (#2531)
- feat(trace-utils)!: add v1-native OTLP encoder brick (#2369)
- perf(serialization): bench the actual path used by the trace exporter
(#2512)
- perf(trace): write agentless JSON directly (#2454)
- chore: move all remaining external deps to workspace-level
dependencies (#2476)
- perf(trace): encode agentless IDs without formatting (#2452)
- perf(trace-utils)!: use pooled spans on the send path (#2382)
- feat(data-pipeline)!: OTLP gRPC trace export (#2171)
- chore(libdd-data-pipeline): solve cargo deny [APMSP-3884] (#2318)
- fix!: benchmark was doing many samples for deterministic heap usage
(#2465)

## libdd-dogstatsd-client
**Next version:** `7.0.0`
**Semver bump:** `major`
**Tag:** `libdd-dogstatsd-client-v7.0.0`

### ⚠️ major bump forced due to:

- `libdd-common`: ^6.0.0 → ^7.0.0
- `libdd-shared-runtime`: ^4.0.0 → ^5.0.0

### Commits

- chore: move all remaining external deps to workspace-level
dependencies (#2476)

## libdd-telemetry
**Next version:** `9.0.0`
**Semver bump:** `major`
**Tag:** `libdd-telemetry-v9.0.0`

### ⚠️ major bump forced due to:

- `libdd-capabilities`: ^3.0.1 → ^4.0.0
- `libdd-common`: ^6.0.0 → ^7.0.0
- `libdd-shared-runtime`: ^4.0.0 → ^5.0.0

### Commits

- refactor!: apply small timeout pooling strategy to libdd-http-client
as well (#2449)
- chore!: remove unused dependencies (v2) (#2511)
- chore: move all remaining external deps to workspace-level
dependencies (#2476)
- fix(telemetry): fall back to the proper intake telemetry domain when
direct submission is enabled (#2484)

## libdd-sampling
**Next version:** `7.0.0`
**Semver bump:** `major`
**Tag:** `libdd-sampling-v7.0.0`

### ⚠️ major bump forced due to:

- `libdd-common`: ^5.2.0 → ^7.0.0
- `libdd-trace-utils`: ^10.1.0 → ^13.0.0

### Commits

- chore(benchmarks): remove batched-loop sampling noise (#2498)
- chore: move all remaining external deps to workspace-level
dependencies (#2476)
- fix!: benchmark was doing many samples for deterministic heap usage
(#2465)
- feat(trace-utils)!: add from owned to SpanText (#2403)
- test(sampling): make rate_limiter thread-safety test deterministic
(#2354)

## libdd-trace-obfuscation
**Next version:** `9.0.0`
**Semver bump:** `major`
**Tag:** `libdd-trace-obfuscation-v9.0.0`

### ⚠️ major bump forced due to:

- `libdd-common`: ^6.0.0 → ^7.0.0
- `libdd-trace-utils`: ^12.0.0 → ^13.0.0

### Commits

- feat(data-pipeline)!: refactor agent's /info obfuscation config format
(#2490)
- fix(obfuscation): keep URLs whose path or fragment holds a bracket
(#2527)
- fix(obfuscation): stop forcing serde_json/preserve_order on dependents
(#2529)
- fix(obfuscation): prevent crash and cap recursion in SQL/HTTP
obfuscation (#2441)
- chore: move all remaining external deps to workspace-level
dependencies (#2476)
- fix(data-pipeline-ffi): harden agentless config setters and parse
obfuscation config once (#2474)

## libdd-trace-stats
**Next version:** `10.0.0`
**Semver bump:** `major`
**Tag:** `libdd-trace-stats-v10.0.0`

### ⚠️ major bump forced due to:

- `libdd-capabilities`: ^3.0.1 → ^4.0.0
- `libdd-capabilities-impl`: ^5.0.0 → ^6.0.0
- `libdd-common`: ^6.0.0 → ^7.0.0
- `libdd-shared-runtime`: ^4.0.0 → ^5.0.0
- `libdd-trace-obfuscation`: ^8.0.0 → ^9.0.0
- `libdd-trace-utils`: ^12.0.0 → ^13.0.0

### Commits

- feat(trace-exporter)!: add API to force flush stats on the trace
exporter (#2538)
- fix(trace-stats): cardinality limit telemetry name (#2559)
- feat(data-pipeline)!: refactor agent's /info obfuscation config format
(#2490)
- chore!: remove unused dependencies (v2) (#2511)
- feat(data-pipeline)!: generate agentless trace stats (#2488)
- chore: move all remaining external deps to workspace-level
dependencies (#2476)
- chore(libdd-data-pipeline): solve cargo deny [APMSP-3884] (#2318)

## libdd-data-pipeline-core
**Next version:** `2.0.0`
**Semver bump:** `major`
**Tag:** `libdd-data-pipeline-core-v2.0.0`

### ⚠️ major bump forced due to:

- `libdd-capabilities`: ^3.0.1 → ^4.0.0
- `libdd-common`: ^6.0.0 → ^7.0.0
- `libdd-trace-obfuscation`: ^8.0.0 → ^9.0.0
- `libdd-trace-utils`: ^12.0.0 → ^13.0.0

### Commits

- refactor!: apply small timeout pooling strategy to libdd-http-client
as well (#2449)
- feat(data-pipeline)!: generate agentless trace stats (#2488)
- perf(data-pipeline): avoid parsing static entity header names (#2457)
- chore: move all remaining external deps to workspace-level
dependencies (#2476)
- perf(trace-utils)!: use pooled spans on the send path (#2382)

## libdd-data-pipeline
**Next version:** `11.0.0`
**Semver bump:** `major`
**Tag:** `libdd-data-pipeline-v11.0.0`

### ⚠️ major bump forced due to:

- `libdd-capabilities`: ^3.0.1 → ^4.0.0
- `libdd-capabilities-impl`: ^5.0.0 → ^6.0.0
- `libdd-common`: ^6.0.0 → ^7.0.0
- `libdd-data-pipeline-core`: ^1.0.0 → ^2.0.0
- `libdd-shared-runtime`: ^4.0.0 → ^5.0.0
- `libdd-trace-obfuscation`: ^8.0.0 → ^9.0.0
- `libdd-trace-stats`: ^9.0.0 → ^10.0.0
- `libdd-trace-utils`: ^12.0.0 → ^13.0.0

### Commits

- feat(trace-exporter)!: add API to force flush stats on the trace
exporter (#2538)
- refactor!: apply small timeout pooling strategy to libdd-http-client
as well (#2449)
- feat(data-pipeline)!: refactor agent's /info obfuscation config format
(#2490)
- test(data-pipeline): stop OTLP gRPC post-connect test from hanging
(#2549)
- chore!: remove unused dependencies (v2) (#2511)
- feat(data-pipeline)!: generate agentless trace stats (#2488)
- fix(otlp): use potential dedupe in otlp serialization path (#2531)
- refactor(benchmarks): isolate enqueue timing in data-pipeline (#2499)
- perf(trace): write agentless JSON directly (#2454)
- test(data-pipeline): fix flaky OTLP gRPC exporter integration tests
(#2505)
- chore: move all remaining external deps to workspace-level
dependencies (#2476)
- perf(trace-utils)!: use pooled spans on the send path (#2382)
- feat(data-pipeline)!: OTLP gRPC trace export (#2171)
- chore(libdd-data-pipeline): solve cargo deny [APMSP-3884] (#2318)


[APMSP-3884]:
https://datadoghq.atlassian.net/browse/APMSP-3884?atlOrigin=eyJpIjoiNWRkNTljNzYxNjVmNDY3MDlhMDU5Y2ZhYzA5YTRkZjUiLCJwIjoiZ2l0aHViLWNvbS1KU1cifQ

---------

Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
Co-authored-by: paullegranddc <82819397+paullegranddc@users.noreply.github.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants