Skip to content

fix(libdd-telemetry): serialize Method::Other as "*" per OpenAPI spec#1998

Merged
gh-worker-dd-mergequeue-cf854d[bot] merged 3 commits into
mainfrom
glopes/fix-method-other-serialization
Jun 3, 2026
Merged

fix(libdd-telemetry): serialize Method::Other as "*" per OpenAPI spec#1998
gh-worker-dd-mergequeue-cf854d[bot] merged 3 commits into
mainfrom
glopes/fix-method-other-serialization

Conversation

@cataphract
Copy link
Copy Markdown
Contributor

Summary

The Method enum's Other variant was serializing as "OTHER" on the wire due
to the #[serde(rename_all = "UPPERCASE")] attribute. However, the
OpenAPI spec
defines "*" as the value for this variant — "OTHER" does not appear in the
schema at all. The existing code comment acknowledged this discrepancy but did not
fix it.

This PR adds #[serde(rename = "*")] on Other to override the enum-level
rename_all for that one variant, making the wire value match the spec.

Note: it is unclear whether Other accurately describes the "*" concept
(i.e. "any method / wildcard") or whether it was originally intended as a
catch-all for unknown/unrecognised methods. If the latter, "*" may be the
wrong wire value for unknown methods and the two concepts may warrant separate
variants. This is left as a follow-up question for the spec owners.

Impact

  • Method::Other now serializes/deserializes as "*" instead of "OTHER"
  • C ABI discriminant DDOG_METHOD_OTHER = 9 is unchanged — ABI-stable for FFI consumers
  • cbindgen reads Rust identifiers, not serde attributes, so the generated header is unaffected

🤖 Generated with Claude Code

@cataphract cataphract requested a review from a team as a code owner May 15, 2026 14:13
@github-actions
Copy link
Copy Markdown
Contributor

github-actions Bot commented May 15, 2026

Clippy Allow Annotation Report

Comparing clippy allow annotations between branches:

  • Base Branch: origin/main
  • PR Branch: origin/glopes/fix-method-other-serialization

Summary by Rule

Rule Base Branch PR Branch Change

Annotation Counts by File

File Base Branch PR Branch Change

Annotation Stats by Crate

Crate Base Branch PR Branch Change
clippy-annotation-reporter 5 5 No change (0%)
datadog-ffe-ffi 1 1 No change (0%)
datadog-ipc 21 21 No change (0%)
datadog-live-debugger 6 6 No change (0%)
datadog-live-debugger-ffi 10 10 No change (0%)
datadog-profiling-replayer 4 4 No change (0%)
datadog-remote-config 3 3 No change (0%)
datadog-sidecar 57 57 No change (0%)
libdd-common 13 13 No change (0%)
libdd-common-ffi 12 12 No change (0%)
libdd-data-pipeline 5 5 No change (0%)
libdd-ddsketch 2 2 No change (0%)
libdd-dogstatsd-client 1 1 No change (0%)
libdd-profiling 13 13 No change (0%)
libdd-telemetry 20 20 No change (0%)
libdd-tinybytes 4 4 No change (0%)
libdd-trace-normalization 2 2 No change (0%)
libdd-trace-obfuscation 3 3 No change (0%)
libdd-trace-stats 1 1 No change (0%)
libdd-trace-utils 13 13 No change (0%)
Total 196 196 No change (0%)

About This Report

This 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.

@dd-octo-sts
Copy link
Copy Markdown
Contributor

dd-octo-sts Bot commented May 15, 2026

Artifact Size Benchmark Report

aarch64-alpine-linux-musl
Artifact Baseline Commit Change
/aarch64-alpine-linux-musl/lib/libdatadog_profiling.a 82.91 MB 82.91 MB -0% (-640 B) 👌
/aarch64-alpine-linux-musl/lib/libdatadog_profiling.so 7.63 MB 7.63 MB 0% (0 B) 👌
aarch64-unknown-linux-gnu
Artifact Baseline Commit Change
/aarch64-unknown-linux-gnu/lib/libdatadog_profiling.so 10.26 MB 10.26 MB 0% (0 B) 👌
/aarch64-unknown-linux-gnu/lib/libdatadog_profiling.a 93.99 MB 93.98 MB -0% (-688 B) 👌
libdatadog-x64-windows
Artifact Baseline Commit Change
/libdatadog-x64-windows/debug/dynamic/datadog_profiling_ffi.dll 24.54 MB 24.54 MB 0% (0 B) 👌
/libdatadog-x64-windows/debug/dynamic/datadog_profiling_ffi.lib 83.96 KB 83.96 KB 0% (0 B) 👌
/libdatadog-x64-windows/debug/dynamic/datadog_profiling_ffi.pdb 178.18 MB 178.17 MB -0% (-8.00 KB) 👌
/libdatadog-x64-windows/debug/static/datadog_profiling_ffi.lib 913.88 MB 913.88 MB -0% (-4 B) 👌
/libdatadog-x64-windows/release/dynamic/datadog_profiling_ffi.dll 8.03 MB 8.03 MB 0% (0 B) 👌
/libdatadog-x64-windows/release/dynamic/datadog_profiling_ffi.lib 83.96 KB 83.96 KB 0% (0 B) 👌
/libdatadog-x64-windows/release/dynamic/datadog_profiling_ffi.pdb 23.77 MB 23.77 MB 0% (0 B) 👌
/libdatadog-x64-windows/release/static/datadog_profiling_ffi.lib 47.42 MB 47.42 MB -0% (-144 B) 👌
libdatadog-x86-windows
Artifact Baseline Commit Change
/libdatadog-x86-windows/debug/dynamic/datadog_profiling_ffi.dll 21.26 MB 21.26 MB 0% (0 B) 👌
/libdatadog-x86-windows/debug/dynamic/datadog_profiling_ffi.lib 85.29 KB 85.29 KB 0% (0 B) 👌
/libdatadog-x86-windows/debug/dynamic/datadog_profiling_ffi.pdb 182.11 MB 182.11 MB 0% (0 B) 👌
/libdatadog-x86-windows/debug/static/datadog_profiling_ffi.lib 906.50 MB 906.50 MB -0% (-4 B) 👌
/libdatadog-x86-windows/release/dynamic/datadog_profiling_ffi.dll 6.20 MB 6.20 MB 0% (0 B) 👌
/libdatadog-x86-windows/release/dynamic/datadog_profiling_ffi.lib 85.29 KB 85.29 KB 0% (0 B) 👌
/libdatadog-x86-windows/release/dynamic/datadog_profiling_ffi.pdb 25.48 MB 25.48 MB 0% (0 B) 👌
/libdatadog-x86-windows/release/static/datadog_profiling_ffi.lib 45.07 MB 45.07 MB -0% (-148 B) 👌
x86_64-alpine-linux-musl
Artifact Baseline Commit Change
/x86_64-alpine-linux-musl/lib/libdatadog_profiling.a 73.94 MB 73.94 MB -0% (-120 B) 👌
/x86_64-alpine-linux-musl/lib/libdatadog_profiling.so 8.53 MB 8.53 MB 0% (0 B) 👌
x86_64-unknown-linux-gnu
Artifact Baseline Commit Change
/x86_64-unknown-linux-gnu/lib/libdatadog_profiling.a 89.34 MB 89.34 MB -0% (-144 B) 👌
/x86_64-unknown-linux-gnu/lib/libdatadog_profiling.so 10.37 MB 10.37 MB 0% (0 B) 👌

@datadog-prod-us1-6
Copy link
Copy Markdown

datadog-prod-us1-6 Bot commented May 15, 2026

Tests

🎉 All green!

🧪 All tests passed
❄️ No new flaky tests detected

🎯 Code Coverage (details)
Patch Coverage: 100.00%
Overall Coverage: 73.39% (-0.05%)

This comment will be updated automatically if new data arrives.
🔗 Commit SHA: b1351d4 | Docs | Datadog PR Page | Give us feedback!

@codecov-commenter
Copy link
Copy Markdown

codecov-commenter commented May 15, 2026

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 73.39%. Comparing base (a1da9fc) to head (b1351d4).

Additional details and impacted files
@@            Coverage Diff             @@
##             main    #1998      +/-   ##
==========================================
- Coverage   73.44%   73.39%   -0.05%     
==========================================
  Files         465      465              
  Lines       77949    77949              
==========================================
- Hits        57248    57210      -38     
- Misses      20701    20739      +38     
Components Coverage Δ
libdd-crashtracker 65.44% <ø> (-0.03%) ⬇️
libdd-crashtracker-ffi 37.68% <ø> (ø)
libdd-alloc 98.77% <ø> (ø)
libdd-data-pipeline 87.14% <ø> (ø)
libdd-data-pipeline-ffi 77.03% <ø> (ø)
libdd-common 79.89% <ø> (ø)
libdd-common-ffi 74.41% <ø> (ø)
libdd-telemetry 73.37% <ø> (ø)
libdd-telemetry-ffi 31.36% <ø> (ø)
libdd-dogstatsd-client 82.64% <ø> (ø)
datadog-ipc 74.75% <ø> (-1.47%) ⬇️
libdd-profiling 81.70% <ø> (+0.01%) ⬆️
libdd-profiling-ffi 64.79% <ø> (ø)
libdd-sampling 97.41% <ø> (ø)
datadog-sidecar 34.60% <ø> (-0.02%) ⬇️
datdog-sidecar-ffi 8.61% <ø> (ø)
spawn-worker 48.86% <ø> (ø)
libdd-tinybytes 93.80% <ø> (ø)
libdd-trace-normalization 81.71% <ø> (ø)
libdd-trace-obfuscation 87.30% <ø> (ø)
libdd-trace-protobuf 68.25% <ø> (ø)
libdd-trace-utils 89.31% <ø> (+0.09%) ⬆️
libdd-tracer-flare 86.88% <ø> (ø)
libdd-log 74.83% <ø> (ø)
🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

@cataphract cataphract changed the title Fix Method::Other to serialize as "*" per OpenAPI spec fix(libdd-telemetry): serialize Method::Other as "*" per OpenAPI spec May 15, 2026
The serde rename_all = "UPPERCASE" attribute was causing Other to
serialize as "OTHER" on the wire, but the OpenAPI spec defines "*" as
the valid value for this variant.
@cataphract cataphract force-pushed the glopes/fix-method-other-serialization branch from f5807e0 to cbd925c Compare May 15, 2026 14:30
@cataphract
Copy link
Copy Markdown
Contributor Author

/merge

@gh-worker-devflow-routing-ef8351
Copy link
Copy Markdown

gh-worker-devflow-routing-ef8351 Bot commented Jun 2, 2026

View all feedbacks in Devflow UI.

2026-06-02 13:49:12 UTC ℹ️ Start processing command /merge


2026-06-02 13:49:19 UTC ℹ️ MergeQueue: waiting for PR to be ready

This pull request is not mergeable according to GitHub. Common reasons include pending required checks, missing approvals, or merge conflicts — but it could also be blocked by other repository rules or settings.
It will be added to the queue as soon as checks pass and/or get approvals. View in MergeQueue UI.
Note: if you pushed new commits since the last approval, you may need additional approval.
You can remove it from the waiting list with /remove command.


2026-06-02 17:59:09 UTC ⚠️ MergeQueue: This merge request was unqueued

devflow unqueued this merge request: It did not become mergeable within the expected time

@cataphract
Copy link
Copy Markdown
Contributor Author

/merge

@gh-worker-devflow-routing-ef8351
Copy link
Copy Markdown

gh-worker-devflow-routing-ef8351 Bot commented Jun 3, 2026

View all feedbacks in Devflow UI.

2026-06-03 14:16:39 UTC ℹ️ Start processing command /merge


2026-06-03 14:16:45 UTC ℹ️ MergeQueue: pull request added to the queue

The expected merge time in main is approximately 47m (p90).


2026-06-03 15:03:47 UTC ℹ️ MergeQueue: This merge request was merged

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