feat(trace-exporter): add fail-closed fallback to v04#2037
Conversation
Clippy Allow Annotation ReportComparing clippy allow annotations between branches:
Summary by Rule
Annotation Counts by File
Annotation Stats by Crate
About This ReportThis report tracks Clippy allow annotations for specific rules, showing how they've changed in this PR. Decreasing the number of these annotations generally improves code quality. |
🎉 All green!🧪 All tests passed 🎯 Code Coverage (details) 🔗 Commit SHA: 09176f7 | Docs | Datadog PR Page | Give us feedback! |
Artifact Size Benchmark Reportaarch64-alpine-linux-musl
aarch64-unknown-linux-gnu
libdatadog-x64-windows
libdatadog-x86-windows
x86_64-alpine-linux-musl
x86_64-unknown-linux-gnu
|
Codecov Report❌ Patch coverage is Additional details and impacted files@@ Coverage Diff @@
## main #2037 +/- ##
==========================================
+ Coverage 73.33% 73.39% +0.05%
==========================================
Files 464 464
Lines 77748 77970 +222
==========================================
+ Hits 57020 57227 +207
- Misses 20728 20743 +15
🚀 New features to boost your workflow:
|
…allback # Conflicts: # libdd-data-pipeline/src/trace_exporter/trace_serializer.rs # libdd-trace-utils/src/msgpack_encoder/v04/mod.rs # libdd-trace-utils/src/msgpack_encoder/v1/mod.rs
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 73cbd6de94
ℹ️ About Codex in GitHub
Codex has been enabled to automatically 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 👍.
When you sign up for Codex through ChatGPT, Codex can also answer questions or update the PR, like "@codex address that feedback".
ekump
left a comment
There was a problem hiding this comment.
LGTM, just don't forget to remove the temporary code in the GH workflow
# Release proposal for libdd-data-pipeline and its dependencies This PR contains version bumps based on public API changes and commits since last release. ## libdd-trace-utils **Next version:** `8.0.0` **Semver bump:** `major` **Tag:** `libdd-trace-utils-v8.0.0` ### Commits - refactor(vecmap)!: avoid Clone bound from dedup (#2069) ## libdd-telemetry **Next version:** `5.0.1` **Semver bump:** `patch` **Tag:** `libdd-telemetry-v5.0.1` ### Commits - fix(libdd-telemetry): serialize Method::Other as "*" per OpenAPI spec (#1998) ## libdd-trace-obfuscation **Next version:** `4.0.0` **Semver bump:** `major` **Tag:** `libdd-trace-obfuscation-v4.0.0` ###⚠️ major bump forced due to: - `libdd-trace-utils`: ^5.0.0 → ^7.0.0 ### Commits - ci: bump msrv to 1.87.0 (#2017) ## libdd-trace-stats **Next version:** `5.0.0` **Semver bump:** `major` **Tag:** `libdd-trace-stats-v5.0.0` ###⚠️ major bump forced due to: - `libdd-trace-utils`: ^5.0.0 → ^7.0.0 ### Commits - revert!: add from_string to span text (#2011) (#2073) - fix(send_with_retry): follow max retries of the strategy (#2047) - ci: bump msrv to 1.87.0 (#2017) ## libdd-data-pipeline **Next version:** `6.0.0` **Semver bump:** `major` **Tag:** `libdd-data-pipeline-v6.0.0` ###⚠️ major bump forced due to: - `libdd-trace-utils`: ^5.0.0 → ^7.0.0 ### Commits - feat(data-pipeline)!: add fork safety hooks and cancellation token for trace exporter FFI (#2051) - revert!: add from_string to span text (#2011) (#2073) - feat(data-pipeline): move the async boundary up (#2064) - feat(trace-exporter): add fail-closed fallback to v04 (#2037) - fix(send_with_retry): follow max retries of the strategy (#2047) - refactor(trace-utils): replace use_v05_format bool and remove infallible expect (#1946) - ci: bump msrv to 1.87.0 (#2017) ## libdd-sampling (manually bumped as it wasn't included in the proposal) **Next version:** `4.0.0` **Semver bump:** `major` **Tag:** `libdd-sampling-v4.0.0` ###⚠️ major bump forced due to: - `libdd-trace-utils`: ^7.0.0 → ^8.0.0 --------- Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com> Co-authored-by: iunanua <18325288+iunanua@users.noreply.github.com> Co-authored-by: iunanua <igor.unanua@datadoghq.com>
What does this PR do?
Adds runtime V1 trace protocol negotiation with fail-closed fallback to V0.4. Opt in via
enable_v1_protocol()orDD_TRACE_AGENT_PROTOCOL_VERSION=1. V1 is only used after the agent advertises/v1.0/tracesin/info.Motivation
APMSP-2809
Makes V1 safe to enable: falls back to V0.4 against agents that don't support it.
Additional Notes
Dynamic rollback supported (if the agent stops advertising V1, the exporter switches back to V0.4).
How to test the change?
All test are working.
End to end tests against a real agent were done and successful as well.