Skip to content

fix(otlp): send array, key-value list, bytes and empty span attributes as string tags - #3713

Merged
gh-worker-dd-mergequeue-cf854d[bot] merged 5 commits into
mainfrom
lt/3443
Dec 4, 2026
Merged

gh-worker-dd-mergequeue-cf854d[bot] merged 5 commits into
mainfrom
lt/3443

Conversation

@lucastemb

Copy link
Copy Markdown
Contributor

Summary

An OTLP span attribute that is an array, a key-value list, or has no value was dropped, and a bytes attribute was sent in a place that is not a normal tag. The data was lost, or at best hard to search.

Now these attributes arrive as ordinary string tags on the span: an array or key-value list as JSON text, bytes as base64, and a value-less attribute as an empty string. Strings, numbers, and booleans are unchanged.

Change Type

  • Bug fix
  • New feature
  • Non-functional (chore, refactoring, docs)
  • Performance

How did you test this PR?

  • A unit test for each type (bytes, array, key-value list, no value) that fails without the change, and a test that both OTLP receive paths now tag these attributes alike.
  • cargo nextest run -p saluki-components on the OTLP trace tests, cargo clippy -p saluki-components --tests, make fmt and make check-docs.
  • I removed the five matching known differences from the otlp-traces-conversion correctness case. I did not run the case, because it needs Docker.

References

@dd-octo-sts dd-octo-sts Bot added area/components Sources, transforms, and destinations. area/test All things testing: unit/integration, correctness, SMP regression, etc. labels Dec 4, 2026
@pr-commenter

pr-commenter Bot commented Dec 4, 2026 •

Copy link
Copy Markdown

Binary Size Analysis (Agent Data Plane)

Baseline: f21242e · Comparison: 7ba8b03 · diff
Analysis Configuration: optimized-release profile, stripped binaries · Pass/Fail Threshold: +5%
Sizes: 25.94 MiB (baseline) vs 25.94 MiB (comparison)
Size Change: +0 B (+0.00%)

✅ Binary size difference within threshold

Changes by Module
Module File Size Symbols
[Unmapped] -152 B 1
saluki_components::common::otlp +151 B 1
zstd +4 B 1
[sections] -3 B 2
Detailed Symbol Changes
    FILE SIZE        VM SIZE    
 --------------  -------------- 
  +0.7%    +151  +0.7%    +151    saluki_components::common::otlp::traces::transform::otel_span_to_dd_span::hed20074e4d467055
  +0.0%      +8  +0.0%      +8    [section .gcc_except_table]
  +1.3%      +4  +1.3%      +4    zstd::stream::raw::Encoder::with_dictionary::h34614f189ff09f0e
  -0.0%     -11  -0.0%     -11    [section .text]
  -2.6%    -152  [ = ]       0    [Unmapped]
  [ = ]       0  +0.0%    +152    TOTAL

@pr-commenter

pr-commenter Bot commented Dec 4, 2026 •

Copy link
Copy Markdown

Regression Detector (Agent Data Plane)

Run ID: 821c2e87-349d-4f3c-8d82-c06ec4a1dd3f
Baseline: f21242e1 · Comparison: 7ba8b033 · diff

Optimization Goals: ✅ No significant changes detected

Fine details of change detection per experiment (5)

Experiments configured erratic: true are tagged (ignored) and skipped when determining which experiments regressed or improved. Experiments which are detected as erratic at runtime are tagged (erratic) to flag that the run's sample dispersion was high, but their regression / improvement signal still counts.

experiment goal Δ mean % links
quality_gates_rss_dsd_ultraheavy memory utilization ⚪ +1.67 metrics profiles logs
quality_gates_rss_dsd_low memory utilization ⚪ -0.03 metrics profiles logs
quality_gates_rss_dsd_heavy memory utilization ⚪ -0.18 metrics profiles logs
quality_gates_rss_idle memory utilization ⚪ -0.25 metrics profiles logs
quality_gates_rss_dsd_medium memory utilization ⚪ -0.58 metrics profiles logs
Bounds Checks: ✅ Passed (5)
experiment check replicates observed links
quality_gates_rss_dsd_heavy memory_usage 10/10 ✅ 156.98MiB ≤ 250MiB metrics profiles logs
quality_gates_rss_dsd_low memory_usage 10/10 ✅ 46.06MiB ≤ 55MiB metrics profiles logs
quality_gates_rss_dsd_medium memory_usage 10/10 ✅ 70.84MiB ≤ 92MiB metrics profiles logs
quality_gates_rss_dsd_ultraheavy memory_usage 10/10 ✅ 289.83MiB ≤ 420MiB metrics profiles logs
quality_gates_rss_idle memory_usage 10/10 ✅ 30.34MiB ≤ 36MiB metrics profiles logs
Explanation

A change is flagged as a regression when |Δ mean %| > 5.00% in the regressing direction for its optimization goal AND SMP marks the experiment as a regression (is_regression: true). Improvements use the matching criteria for the improving direction. Experiments configured erratic: true (tagged (ignored)) are skipped outright; experiments detected as erratic at runtime (tagged (erratic)) still count, since that flag describes sample dispersion rather than directional certainty. The Δ mean % cell is colored accordingly: 🟢 = improvement, 🔴 = regression, ⚪ = neutral. Reduction in CPU or memory is an improvement; reduction in ingress throughput is a regression. Experiments tagged (no analysis) show ⚠️ n/a: SMP ran them but produced no analysis, usually because a replicate failed and exhausted its retries. Check the SMP report for that experiment's replicate failures.

@github-actions github-actions Bot 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.

AI review by Claude - workflow run

Patch is correct, with 0 blocking findings. Span attributes that are arrays, key-value lists, bytes, or that have no value now go through the shared otlp_value_as_string helper, so they become string tags. The two receive paths are tested to agree on them. The new test helper was inserted below an existing doc comment, so that comment now sits on the wrong item.

@datadog-prod-us1-3 datadog-prod-us1-3 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.

Bits Code Review: PASS

More details

The conversion reuses the existing OTLP string renderer for base64 bytes and JSON collections, with no actionable regression identified by the completed static review. Runtime behavior was not exercised.

Was this helpful? React 👍 or 👎

Open Bits AI session

🤖 Bits Code Review · Commit c8aeb1f

The mapped_span_attribute helper was inserted between the TestGetOTelVersion doc comment and test_get_otel_version, so the helper carried two doc lines and the test none.
@lucastemb

Copy link
Copy Markdown
Contributor Author

/merge

@gh-worker-devflow-routing-ef8351

gh-worker-devflow-routing-ef8351 Bot commented Dec 4, 2026 •

Copy link
Copy Markdown

View all feedbacks in Devflow UI.

2026-12-04 19:56:38 UTC ℹ️ Start processing command /merge


2026-12-04 19:56:46 UTC ℹ️ MergeQueue: Pull request is not mergeable yet

It will be processed automatically as soon as GitHub reports it as mergeable. View in MergeQueue UI.

  • Run /code blockers to see what is blocking it.
  • Run /remove to cancel it.

2026-12-04 20:30:19 UTC ℹ️ MergeQueue: merge request added to the queue

The expected merge time in main is approximately 2h (p90).


2026-12-04 20:57:07 UTC ℹ️ MergeQueue: This merge request was merged

@lucastemb

Copy link
Copy Markdown
Contributor Author

/merge

@gh-worker-devflow-routing-ef8351

gh-worker-devflow-routing-ef8351 Bot commented Dec 4, 2026 •

Copy link
Copy Markdown

View all feedbacks in Devflow UI.

2026-12-04 20:07:10 UTC ℹ️ Start processing command /merge


2026-12-04 20:07:12 UTC ❌ MergeQueue

PR already in the queue with status waiting

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

Labels

area/components Sources, transforms, and destinations. area/test All things testing: unit/integration, correctness, SMP regression, etc. changelog/no-changelog No changelog entry needed mergequeue-status: done

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Traces(otlp): ADP drops OTLP attributes of type array, key-value list and absent, and sends bytes in meta_struct

2 participants