Skip to content

feat(otel): Enable improved OTel trace compatibility via opt-in configuration#8894

Merged
zacharycmontoya merged 17 commits into
masterfrom
zach.montoya/opt-in-otel-semantics
Jun 16, 2026
Merged

feat(otel): Enable improved OTel trace compatibility via opt-in configuration#8894
zacharycmontoya merged 17 commits into
masterfrom
zach.montoya/opt-in-otel-semantics

Conversation

@zacharycmontoya

@zacharycmontoya zacharycmontoya commented Jun 12, 2026

Copy link
Copy Markdown
Contributor

What does this PR do?

This PR adds a configuration to process spans as closely as possible to the OTel SDK. The result is that using OpenTelemetry Tracing instrumentations allows DD SDKs to produce OTLP spans with nearly identical span fields.

When enabled, this updates the dd-trace-js behavior in the following ways:

  • OtelSpan.updateName no longer updates the operation name. Instead, it now updates the resource name, which is the expected OpenTelemetry behavior.
  • OtelSpan.setAttribute no longer remaps the tag http.response.status_code so it will maintain its intended key and value type
  • OtelSpan.recordException no longer sets span attributes error.message, error.type, or error.stack. These exist on the exception span event and will be recognized by Error Tracking
  • OtelSpan.setStatus now overwrites the span's status message with the latest status. This means a previous ERROR status with a message that is then upgraded to OK will have the status message cleared.
  • When exporting OTLP spans, the previous behavior would set the following span attributes to preserve Datadog semantics. With this new semantic mode, the following span attributes are no longer generated from the Datadog span:
    • service.name
    • operation.name
    • resource.name
    • span.type
    • span.kind
    • error.message

Motivation

We want to enable OpenTelemetry SDK users to migrate to the Datadog SDK in their language ecosystem, so this change allows them to export OTLP spans from the Datadog SDK without the shape of their data changing. This is most notable when using the OpenTelemetry Tracing API and OpenTelemetry Instrumentation Libraries to generate traces -- with this new semantic mode, the OTLP span should reach the backend without its semantics changing.

Additional Notes

N/A

… to update the DD span's resource name. Previously, this updated the operation name which was a bug
@zacharycmontoya
zacharycmontoya requested review from a team as code owners June 12, 2026 01:05
@zacharycmontoya
zacharycmontoya requested review from BridgeAR and removed request for a team June 12, 2026 01:05
@datadog-datadog-prod-us1-2

datadog-datadog-prod-us1-2 Bot commented Jun 12, 2026

Copy link
Copy Markdown

Tests

🎉 All green!

🧪 All tests passed
❄️ No new flaky tests detected

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

@dd-octo-sts

dd-octo-sts Bot commented Jun 12, 2026

Copy link
Copy Markdown
Contributor

Overall package size

Self size: 6.25 MB
Deduped: 7.3 MB
No deduping: 7.3 MB

Dependency sizes | name | version | self size | total size | |------|---------|-----------|------------| | import-in-the-middle | 3.0.2 | 85.93 kB | 825.11 kB | | opentracing | 0.14.7 | 194.81 kB | 194.81 kB | | dc-polyfill | 0.1.11 | 25.74 kB | 25.74 kB |

🤖 This report was automatically generated by heaviest-objects-in-the-universe

@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: 0184055bb1

ℹ️ 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 packages/dd-trace/src/config/supported-configurations.json
Comment thread packages/dd-trace/src/opentelemetry/span-helpers.js
@codecov

codecov Bot commented Jun 12, 2026

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 92.31%. Comparing base (f45dfeb) to head (77f2fd7).
⚠️ Report is 2 commits behind head on master.

Additional details and impacted files
@@            Coverage Diff             @@
##           master    #8894      +/-   ##
==========================================
- Coverage   92.85%   92.31%   -0.55%     
==========================================
  Files         876      876              
  Lines       50214    50231      +17     
  Branches     9858     9866       +8     
==========================================
- Hits        46625    46369     -256     
- Misses       3589     3862     +273     
Flag Coverage Δ
aiguard-integration-active 41.45% <ø> (+<0.01%) ⬆️
aiguard-integration-latest 41.46% <ø> (ø)
aiguard-integration-maintenance 41.54% <ø> (ø)
aiguard-macos 34.58% <ø> (-0.08%) ⬇️
aiguard-ubuntu 34.73% <ø> (-0.08%) ⬇️
aiguard-windows 34.40% <ø> (-0.08%) ⬇️
apm-capabilities-tracing-macos 47.86% <100.00%> (+0.01%) ⬆️
apm-capabilities-tracing-ubuntu-active 47.87% <100.00%> (+0.02%) ⬆️
apm-capabilities-tracing-ubuntu-latest 47.87% <100.00%> (+0.02%) ⬆️
apm-capabilities-tracing-ubuntu-maintenance 47.91% <100.00%> (+0.02%) ⬆️
apm-capabilities-tracing-ubuntu-oldest 47.91% <100.00%> (-0.16%) ⬇️
apm-capabilities-tracing-windows 47.87% <100.00%> (+0.02%) ⬆️
apm-integrations-aerospike-18-gte.5.2.0 33.01% <ø> (-0.08%) ⬇️
apm-integrations-aerospike-20-gte.5.5.0 33.03% <ø> (-0.08%) ⬇️
apm-integrations-aerospike-22-gte.5.12.1 33.03% <ø> (-0.08%) ⬇️
apm-integrations-aerospike-22-gte.6.0.0 33.03% <ø> (-0.08%) ⬇️
apm-integrations-aerospike-eol- 32.93% <ø> (-0.08%) ⬇️
apm-integrations-child-process 33.95% <ø> (?)
apm-integrations-confluentinc-kafka-javascript-18 40.02% <ø> (-0.08%) ⬇️
apm-integrations-confluentinc-kafka-javascript-20 40.03% <ø> (-0.08%) ⬇️
apm-integrations-confluentinc-kafka-javascript-22 ?
apm-integrations-confluentinc-kafka-javascript-24 39.93% <ø> (-0.08%) ⬇️
apm-integrations-couchbase-18 33.19% <ø> (+0.08%) ⬆️
apm-integrations-couchbase-eol 33.07% <ø> (-0.08%) ⬇️
apm-integrations-dns 32.95% <ø> (?)
apm-integrations-elasticsearch 33.97% <ø> (-0.08%) ⬇️
apm-integrations-http-latest 41.16% <ø> (-0.07%) ⬇️
apm-integrations-http-maintenance 41.25% <ø> (-0.07%) ⬇️
apm-integrations-http-oldest 41.19% <ø> (-0.06%) ⬇️
apm-integrations-http2 38.31% <ø> (-0.24%) ⬇️
apm-integrations-kafkajs-latest ?
apm-integrations-kafkajs-oldest 40.21% <ø> (+0.02%) ⬆️
apm-integrations-net 33.65% <ø> (-0.08%) ⬇️
apm-integrations-next-11.1.4 36.64% <ø> (ø)
apm-integrations-next-12.3.7 36.64% <ø> (ø)
apm-integrations-next-13.0.0 28.98% <ø> (-0.08%) ⬇️
apm-integrations-next-13.2.0 28.98% <ø> (-0.12%) ⬇️
apm-integrations-next-13.5.11 29.16% <ø> (-0.04%) ⬇️
apm-integrations-next-14.0.0 29.05% <ø> (-0.08%) ⬇️
apm-integrations-next-14.2.35 29.05% <ø> (-0.08%) ⬇️
apm-integrations-next-14.2.6 ?
apm-integrations-next-14.2.7 29.09% <ø> (-0.04%) ⬇️
apm-integrations-next-15.0.0 29.05% <ø> (-0.08%) ⬇️
apm-integrations-next-15.4.0 29.12% <ø> (-0.08%) ⬇️
apm-integrations-next-latest 29.16% <ø> (-0.08%) ⬇️
apm-integrations-prisma-18-gte.6.16.0.and.lt.7.0.0 34.74% <ø> (-0.08%) ⬇️
apm-integrations-prisma-latest-all ?
apm-integrations-restify 35.05% <ø> (-0.08%) ⬇️
apm-integrations-sharedb 32.36% <ø> (-0.08%) ⬇️
apm-integrations-tedious 33.27% <ø> (-0.08%) ⬇️
appsec-express 50.96% <ø> (-0.06%) ⬇️
appsec-fastify 47.67% <ø> (-0.06%) ⬇️
appsec-graphql 47.73% <ø> (-0.06%) ⬇️
appsec-integration-active 36.09% <ø> (ø)
appsec-integration-latest 36.09% <ø> (ø)
appsec-integration-maintenance 36.15% <ø> (ø)
appsec-integration-oldest 36.15% <ø> (ø)
appsec-kafka 40.23% <ø> (-0.08%) ⬇️
appsec-ldapjs 39.76% <ø> (-0.07%) ⬇️
appsec-lodash 39.68% <ø> (-0.07%) ⬇️
appsec-macos 57.13% <ø> (-0.06%) ⬇️
appsec-mongodb-core 43.87% <ø> (-0.06%) ⬇️
appsec-mongoose 44.72% <ø> (-0.06%) ⬇️
appsec-mysql 47.00% <ø> (-0.06%) ⬇️
appsec-next-latest-11.1.4 27.28% <ø> (-0.07%) ⬇️
appsec-next-latest-12.3.7 27.70% <ø> (ø)
appsec-next-latest-13.0.0 29.08% <ø> (-0.08%) ⬇️
appsec-next-latest-13.2.0 29.10% <ø> (-0.08%) ⬇️
appsec-next-latest-13.5.11 29.19% <ø> (-0.08%) ⬇️
appsec-next-latest-14.0.0 29.12% <ø> (-0.08%) ⬇️
appsec-next-latest-14.2.35 29.12% <ø> (-0.08%) ⬇️
appsec-next-latest-14.2.6 29.12% <ø> (-0.08%) ⬇️
appsec-next-latest-14.2.7 29.12% <ø> (-0.08%) ⬇️
appsec-next-latest-15.0.0 29.12% <ø> (-0.08%) ⬇️
appsec-next-latest-latest 29.16% <ø> (?)
appsec-next-oldest-11.1.4 27.33% <ø> (?)
appsec-next-oldest-12.3.7 29.14% <ø> (-0.08%) ⬇️
appsec-next-oldest-13.0.0 29.14% <ø> (-0.08%) ⬇️
appsec-next-oldest-13.5.11 29.50% <ø> (-0.08%) ⬇️
appsec-next-oldest-14.0.0 29.43% <ø> (-0.08%) ⬇️
appsec-next-oldest-14.2.35 29.43% <ø> (-0.08%) ⬇️
appsec-next-oldest-14.2.6 29.43% <ø> (-0.08%) ⬇️
appsec-next-oldest-14.2.7 ?
appsec-next-oldest-15.0.0 29.43% <ø> (-0.08%) ⬇️
appsec-next-oldest-latest 27.90% <ø> (ø)
appsec-node-serialize 38.99% <ø> (-0.07%) ⬇️
appsec-passport 42.61% <ø> (-0.07%) ⬇️
appsec-postgres 46.68% <ø> (-0.06%) ⬇️
appsec-sourcing 38.40% <ø> (-0.07%) ⬇️
appsec-stripe 40.46% <ø> (-0.07%) ⬇️
appsec-template 39.23% <ø> (-0.07%) ⬇️
appsec-ubuntu 57.24% <ø> (-0.06%) ⬇️
appsec-windows 57.05% <ø> (-0.07%) ⬇️
debugger-ubuntu-active 43.51% <ø> (ø)
debugger-ubuntu-latest 43.51% <ø> (ø)
debugger-ubuntu-maintenance 43.63% <ø> (-0.29%) ⬇️
debugger-ubuntu-oldest 43.94% <ø> (ø)
instrumentations-instrumentation-ai 45.33% <ø> (ø)
instrumentations-instrumentation-aws-sdk 44.93% <ø> (ø)
instrumentations-instrumentation-bluebird 27.42% <ø> (-0.08%) ⬇️
instrumentations-instrumentation-body-parser 35.56% <ø> (-0.08%) ⬇️
instrumentations-instrumentation-child_process 33.33% <ø> (-0.08%) ⬇️
instrumentations-instrumentation-cookie-parser 29.31% <ø> (-0.08%) ⬇️
instrumentations-instrumentation-couchbase-18 46.02% <ø> (ø)
instrumentations-instrumentation-couchbase-eol ?
instrumentations-instrumentation-crypto 27.47% <ø> (?)
instrumentations-instrumentation-express 29.52% <ø> (-0.08%) ⬇️
instrumentations-instrumentation-express-mongo-sanitize 29.43% <ø> (-0.08%) ⬇️
instrumentations-instrumentation-express-multi-version 41.47% <ø> (ø)
instrumentations-instrumentation-express-session 35.33% <ø> (-0.08%) ⬇️
instrumentations-instrumentation-fastify 47.86% <ø> (ø)
instrumentations-instrumentation-fetch 44.76% <ø> (ø)
instrumentations-instrumentation-fs 27.18% <ø> (-0.08%) ⬇️
instrumentations-instrumentation-generic-pool 27.02% <ø> (ø)
instrumentations-instrumentation-hono 28.63% <ø> (-0.08%) ⬇️
instrumentations-instrumentation-http 37.90% <ø> (-0.08%) ⬇️
instrumentations-instrumentation-http-client-options 37.50% <ø> (-0.08%) ⬇️
instrumentations-instrumentation-kafkajs 48.94% <ø> (ø)
instrumentations-instrumentation-knex 27.41% <ø> (-0.08%) ⬇️
instrumentations-instrumentation-light-my-request 35.19% <ø> (-0.08%) ⬇️
instrumentations-instrumentation-mongoose 28.52% <ø> (-0.08%) ⬇️
instrumentations-instrumentation-multer 35.23% <ø> (-0.08%) ⬇️
instrumentations-instrumentation-mysql2 33.36% <ø> (-0.08%) ⬇️
instrumentations-instrumentation-openai-lifecycle 46.00% <ø> (ø)
instrumentations-instrumentation-otel-sdk-trace 25.27% <ø> (ø)
instrumentations-instrumentation-passport 39.12% <ø> (-0.07%) ⬇️
instrumentations-instrumentation-passport-http 38.81% <ø> (-0.07%) ⬇️
instrumentations-instrumentation-passport-local 39.27% <ø> (-0.07%) ⬇️
instrumentations-instrumentation-pg 33.08% <ø> (-0.08%) ⬇️
instrumentations-instrumentation-promise 27.37% <ø> (-0.08%) ⬇️
instrumentations-instrumentation-promise-js 27.37% <ø> (-0.08%) ⬇️
instrumentations-instrumentation-q 27.40% <ø> (-0.08%) ⬇️
instrumentations-instrumentation-router 43.07% <ø> (ø)
instrumentations-instrumentation-stripe 27.90% <ø> (-0.08%) ⬇️
instrumentations-instrumentation-url 27.30% <ø> (-0.08%) ⬇️
instrumentations-instrumentation-when 27.38% <ø> (-0.08%) ⬇️
instrumentations-instrumentation-zlib 27.35% <ø> (-0.08%) ⬇️
instrumentations-integration-esbuild-0.16.12-active ?
instrumentations-integration-esbuild-0.16.12-latest 24.59% <ø> (ø)
instrumentations-integration-esbuild-0.16.12-maintenance 18.57% <ø> (ø)
instrumentations-integration-esbuild-0.16.12-oldest 18.56% <ø> (ø)
instrumentations-integration-esbuild-latest-active 24.59% <ø> (ø)
instrumentations-integration-esbuild-latest-latest 24.59% <ø> (ø)
instrumentations-integration-esbuild-latest-maintenance ?
instrumentations-integration-esbuild-latest-oldest 18.56% <ø> (ø)
llmobs-ai 35.08% <ø> (-0.07%) ⬇️
llmobs-anthropic 36.46% <ø> (-0.08%) ⬇️
llmobs-bedrock 35.98% <ø> (-0.07%) ⬇️
llmobs-google-genai 35.74% <ø> (-0.07%) ⬇️
llmobs-langchain 34.76% <ø> (-0.06%) ⬇️
llmobs-openai-latest 39.39% <ø> (-0.07%) ⬇️
llmobs-openai-oldest 39.47% <ø> (?)
llmobs-sdk-active ?
llmobs-sdk-latest 43.43% <ø> (-0.08%) ⬇️
llmobs-sdk-maintenance 43.53% <ø> (-0.08%) ⬇️
llmobs-sdk-oldest ?
llmobs-vertex-ai 35.51% <ø> (-0.08%) ⬇️
master-coverage 92.31% <100.00%> (?)
openfeature-macos 37.39% <ø> (+<0.01%) ⬆️
openfeature-ubuntu ?
openfeature-unit-active 49.95% <ø> (ø)
openfeature-unit-latest 49.95% <ø> (ø)
openfeature-unit-maintenance 50.32% <ø> (ø)
openfeature-unit-oldest 50.32% <ø> (ø)
openfeature-windows 37.27% <ø> (+0.05%) ⬆️
platform-core 45.98% <ø> (ø)
platform-esbuild 46.62% <ø> (ø)
platform-instrumentations-misc 29.32% <ø> (ø)
platform-integration-active 46.60% <79.54%> (+0.06%) ⬆️
platform-integration-latest 46.63% <79.54%> (+0.05%) ⬆️
platform-integration-maintenance 46.74% <79.54%> (+0.11%) ⬆️
platform-integration-oldest 46.89% <79.54%> (+0.06%) ⬆️
platform-shimmer ?
platform-unit-guardrails 44.04% <ø> (ø)
platform-webpack 18.10% <ø> (ø)
plugins-aws-durable-execution-sdk-js 32.74% <ø> (-0.07%) ⬇️
plugins-axios 35.32% <ø> (ø)
plugins-azure-cosmos 35.79% <ø> (-0.08%) ⬇️
plugins-azure-event-hubs ?
plugins-azure-service-bus 35.14% <ø> (ø)
plugins-body-parser 36.32% <ø> (?)
plugins-bullmq 39.41% <ø> (-0.08%) ⬇️
plugins-cassandra 33.48% <ø> (-0.08%) ⬇️
plugins-cookie 40.62% <ø> (ø)
plugins-cookie-parser 40.45% <ø> (ø)
plugins-crypto 42.36% <ø> (ø)
plugins-dd-trace-api 33.19% <ø> (-0.08%) ⬇️
plugins-express-mongo-sanitize 40.51% <ø> (ø)
plugins-express-session 40.37% <ø> (ø)
plugins-fastify 37.64% <ø> (-0.08%) ⬇️
plugins-fetch 33.91% <ø> (-0.08%) ⬇️
plugins-fs 33.61% <ø> (-0.08%) ⬇️
plugins-generic-pool 39.94% <ø> (ø)
plugins-google-cloud-pubsub ?
plugins-grpc 36.39% <ø> (-0.08%) ⬇️
plugins-handlebars 40.51% <ø> (ø)
plugins-hapi 35.46% <ø> (-0.08%) ⬇️
plugins-hono 35.79% <ø> (-0.08%) ⬇️
plugins-ioredis 34.17% <ø> (-0.08%) ⬇️
plugins-jest 27.10% <ø> (ø)
plugins-knex 39.98% <ø> (ø)
plugins-langgraph 32.21% <ø> (-0.08%) ⬇️
plugins-ldapjs 38.96% <ø> (ø)
plugins-light-my-request 40.08% <ø> (ø)
plugins-limitd-client 27.73% <ø> (-0.08%) ⬇️
plugins-lodash 40.12% <ø> (ø)
plugins-mariadb 35.00% <ø> (-0.08%) ⬇️
plugins-memcached 33.56% <ø> (-0.08%) ⬇️
plugins-microgateway-core 34.56% <ø> (-0.08%) ⬇️
plugins-modelcontextprotocol-sdk 32.17% <ø> (-0.08%) ⬇️
plugins-moleculer 36.45% <ø> (?)
plugins-mongodb 35.69% <ø> (-0.08%) ⬇️
plugins-mongodb-core 35.29% <ø> (-0.08%) ⬇️
plugins-mongoose 34.19% <ø> (-0.08%) ⬇️
plugins-multer 40.42% <ø> (ø)
plugins-mysql 34.48% <ø> (+0.06%) ⬆️
plugins-mysql2 34.81% <ø> (-0.08%) ⬇️
plugins-nats 36.19% <ø> (-0.08%) ⬇️
plugins-node-serialize 40.65% <ø> (ø)
plugins-opensearch 33.42% <ø> (-0.08%) ⬇️
plugins-passport-http 40.24% <ø> (ø)
plugins-pino 29.66% <ø> (-0.08%) ⬇️
plugins-postgres ?
plugins-process 42.36% <ø> (ø)
plugins-pug 40.62% <ø> (ø)
plugins-redis 34.08% <ø> (-0.09%) ⬇️
plugins-router 38.04% <ø> (-0.08%) ⬇️
plugins-sequelize 39.90% <ø> (ø)
plugins-test-and-upstream-amqp10 33.70% <ø> (?)
plugins-test-and-upstream-amqplib 39.05% <ø> (-0.09%) ⬇️
plugins-test-and-upstream-apollo 34.65% <ø> (-0.07%) ⬇️
plugins-test-and-upstream-avsc 33.58% <ø> (-0.08%) ⬇️
plugins-test-and-upstream-bunyan 28.87% <ø> (-0.08%) ⬇️
plugins-test-and-upstream-connect 35.91% <ø> (-0.30%) ⬇️
plugins-test-and-upstream-graphql ?
plugins-test-and-upstream-koa 35.64% <ø> (-0.08%) ⬇️
plugins-test-and-upstream-protobufjs 33.81% <ø> (-0.08%) ⬇️
plugins-test-and-upstream-rhea 39.01% <ø> (-0.08%) ⬇️
plugins-undici 34.40% <ø> (-0.07%) ⬇️
plugins-url 42.36% <ø> (ø)
plugins-valkey 33.65% <ø> (-0.07%) ⬇️
plugins-vm 42.36% <ø> (ø)
plugins-winston 29.52% <ø> (-0.08%) ⬇️
plugins-ws 36.94% <ø> (-0.08%) ⬇️
profiling-macos 43.03% <ø> (-0.07%) ⬇️
profiling-ubuntu 43.50% <ø> (-0.07%) ⬇️
profiling-windows 40.73% <ø> (-0.12%) ⬇️
serverless-aws-sdk-latest-aws-sdk 32.92% <ø> (-0.07%) ⬇️
serverless-aws-sdk-latest-bedrockruntime ?
serverless-aws-sdk-latest-client 36.32% <ø> (ø)
serverless-aws-sdk-latest-dynamodb 33.75% <ø> (-0.12%) ⬇️
serverless-aws-sdk-latest-eventbridge 26.82% <ø> (-0.07%) ⬇️
serverless-aws-sdk-latest-kinesis 37.01% <ø> (-0.07%) ⬇️
serverless-aws-sdk-latest-lambda 34.26% <ø> (-0.07%) ⬇️
serverless-aws-sdk-latest-s3 32.17% <ø> (-0.07%) ⬇️
serverless-aws-sdk-latest-serverless-peer-service 39.14% <ø> (-0.08%) ⬇️
serverless-aws-sdk-latest-sns 38.02% <ø> (?)
serverless-aws-sdk-latest-sqs 37.64% <ø> (?)
serverless-aws-sdk-latest-stepfunctions 32.83% <ø> (-0.07%) ⬇️
serverless-aws-sdk-latest-util 46.39% <ø> (ø)
serverless-aws-sdk-oldest-aws-sdk 33.04% <ø> (-0.07%) ⬇️
serverless-aws-sdk-oldest-bedrockruntime 31.91% <ø> (-0.07%) ⬇️
serverless-aws-sdk-oldest-client 36.88% <ø> (ø)
serverless-aws-sdk-oldest-dynamodb 33.90% <ø> (-0.07%) ⬇️
serverless-aws-sdk-oldest-eventbridge 26.90% <ø> (-0.07%) ⬇️
serverless-aws-sdk-oldest-kinesis 37.18% <ø> (-0.07%) ⬇️
serverless-aws-sdk-oldest-lambda 34.36% <ø> (-0.07%) ⬇️
serverless-aws-sdk-oldest-s3 32.30% <ø> (-0.07%) ⬇️
serverless-aws-sdk-oldest-serverless-peer-service 39.22% <ø> (-0.08%) ⬇️
serverless-aws-sdk-oldest-sns 38.12% <ø> (-0.07%) ⬇️
serverless-aws-sdk-oldest-sqs 37.72% <ø> (-0.07%) ⬇️
serverless-aws-sdk-oldest-stepfunctions ?
serverless-aws-sdk-oldest-util 47.13% <ø> (ø)
serverless-azure-durable-functions 36.60% <ø> (ø)
serverless-azure-functions-eventhubs 38.23% <ø> (ø)
serverless-azure-functions-servicebus 38.29% <ø> (ø)
serverless-lambda 34.23% <ø> (-0.10%) ⬇️
test-optimization-cucumber-latest-7.0.0 49.92% <ø> (+0.11%) ⬆️
test-optimization-cucumber-latest-latest 52.66% <ø> (+0.11%) ⬆️
test-optimization-cucumber-oldest-7.0.0 50.01% <ø> (+0.11%) ⬆️
test-optimization-cypress-latest-12.0.0-commonJS 49.12% <ø> (-0.07%) ⬇️
test-optimization-cypress-latest-12.0.0-esm 48.53% <ø> (-0.69%) ⬇️
test-optimization-cypress-latest-14.5.4-commonJS 49.11% <ø> (+0.24%) ⬆️
test-optimization-cypress-latest-14.5.4-esm 49.14% <ø> (+0.07%) ⬆️
test-optimization-cypress-latest-latest-commonJS 49.60% <ø> (+0.07%) ⬆️
test-optimization-cypress-latest-latest-esm 47.98% <ø> (-1.58%) ⬇️
test-optimization-cypress-oldest-12.0.0-commonJS 47.29% <ø> (-1.99%) ⬇️
test-optimization-cypress-oldest-12.0.0-esm 49.06% <ø> (-0.22%) ⬇️
test-optimization-cypress-oldest-14.5.4-commonJS 49.20% <ø> (+0.62%) ⬆️
test-optimization-cypress-oldest-14.5.4-esm 49.23% <ø> (+1.80%) ⬆️
test-optimization-jest-latest-latest 55.36% <ø> (+0.08%) ⬆️
test-optimization-jest-latest-oldest 53.65% <ø> (-0.56%) ⬇️
test-optimization-jest-oldest-latest 55.41% <ø> (+2.57%) ⬆️
test-optimization-jest-oldest-oldest 52.37% <ø> (-1.85%) ⬇️
test-optimization-mocha-latest-latest 53.61% <ø> (+0.08%) ⬆️
test-optimization-mocha-latest-oldest 51.16% <ø> (+0.08%) ⬆️
test-optimization-mocha-oldest-latest 53.74% <ø> (+0.10%) ⬆️
test-optimization-mocha-oldest-oldest 51.08% <ø> (-0.02%) ⬇️
test-optimization-playwright-latest-latest-playwright-active-test-span 44.23% <ø> (+0.41%) ⬆️
test-optimization-playwright-latest-latest-playwright-atr 42.86% <ø> (+0.10%) ⬆️
test-optimization-playwright-latest-latest-playwright-efd 43.30% <ø> (+0.08%) ⬆️
test-optimization-playwright-latest-latest-playwright-final-status 43.37% <ø> (+0.10%) ⬆️
test-optimization-playwright-latest-latest-playwright-impacted-tests ?
test-optimization-playwright-latest-latest-playwright-reporting 42.87% <ø> (+0.06%) ⬆️
test-optimization-playwright-latest-latest-playwright-test-management ?
test-optimization-playwright-latest-oldest-playwright-active-test-span 44.05% <ø> (+0.27%) ⬆️
test-optimization-playwright-latest-oldest-playwright-atr 42.94% <ø> (+0.10%) ⬆️
test-optimization-playwright-latest-oldest-playwright-efd ?
test-optimization-playwright-latest-oldest-playwright-final-status 43.28% <ø> (+0.10%) ⬆️
test-optimization-playwright-latest-oldest-playwright-impacted-tests 42.75% <ø> (ø)
test-optimization-playwright-latest-oldest-playwright-reporting 42.71% <ø> (?)
test-optimization-playwright-latest-oldest-playwright-test-management 44.45% <ø> (+0.10%) ⬆️
test-optimization-playwright-oldest-latest-playwright-active-test-span 44.29% <ø> (+0.07%) ⬆️
test-optimization-playwright-oldest-latest-playwright-atr 42.94% <ø> (+0.08%) ⬆️
test-optimization-playwright-oldest-latest-playwright-efd 43.36% <ø> (+0.08%) ⬆️
test-optimization-playwright-oldest-latest-playwright-final-status 43.45% <ø> (+0.08%) ⬆️
test-optimization-playwright-oldest-latest-playwright-impacted-tests 42.91% <ø> (?)
test-optimization-playwright-oldest-latest-playwright-reporting 42.95% <ø> (+0.08%) ⬆️
test-optimization-playwright-oldest-latest-playwright-test-management 44.59% <ø> (+0.08%) ⬆️
test-optimization-playwright-oldest-oldest-playwright-active-test-span 44.13% <ø> (+0.27%) ⬆️
test-optimization-playwright-oldest-oldest-playwright-atr 43.02% <ø> (+0.10%) ⬆️
test-optimization-playwright-oldest-oldest-playwright-efd ?
test-optimization-playwright-oldest-oldest-playwright-final-status 43.36% <ø> (+0.08%) ⬆️
test-optimization-playwright-oldest-oldest-playwright-impacted-tests 42.84% <ø> (ø)
test-optimization-playwright-oldest-oldest-playwright-reporting 42.77% <ø> (+0.09%) ⬆️
test-optimization-playwright-oldest-oldest-playwright-test-management 44.54% <ø> (+0.10%) ⬆️
test-optimization-selenium-latest 45.20% <ø> (+0.06%) ⬆️
test-optimization-selenium-oldest ?
test-optimization-testopt-active 48.28% <ø> (+0.12%) ⬆️
test-optimization-testopt-latest 48.28% <ø> (+0.12%) ⬆️
test-optimization-testopt-maintenance 48.27% <ø> (+0.13%) ⬆️
test-optimization-testopt-oldest 49.37% <ø> (+0.10%) ⬆️
test-optimization-vitest-latest 49.78% <ø> (-0.94%) ⬇️
test-optimization-vitest-oldest 48.04% <ø> (+0.32%) ⬆️

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Harness.
📢 Have feedback on the report? Share it here.

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

…lemetry semantic conventions for tracing. Concretely, this results in the following changes:

- When emitting OTLP traces we omit Datadog-only attributes 'service.name', 'operation.name', 'span.type', and 'resource.name'
- The OTel Tracing API is updated to _not_ remap the attribute 'http.response.status_code'
- The OTel Tracing recordException API is updated to not write error tags on the span. The exception is entirely captured in a span event, per the OpenTelemetry specification
- The OTel Tracing setStatus API is updated to rewrite the span error message on the last update of the span status
- All behavior is enabled with the environment variable DD_TRACE_OTEL_COMPATIBILITY_ENABLED
@zacharycmontoya
zacharycmontoya force-pushed the zach.montoya/opt-in-otel-semantics branch from 0184055 to 00fabbd Compare June 12, 2026 22:15
@pr-commenter

pr-commenter Bot commented Jun 12, 2026

Copy link
Copy Markdown

Benchmarks

Benchmark execution time: 2026-06-16 16:59:17

Comparing candidate commit 77f2fd7 in PR branch zach.montoya/opt-in-otel-semantics with baseline commit fcefeef in branch master.

📊 Benchmarking dashboard

Found 0 performance improvements and 0 performance regressions! Performance is the same for 1936 metrics, 14 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 ----------------------------------'

Unstable benchmarks

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

scenario:appsec-appsec-enabled-24

  • unstable execution_time [-149.685ms; +157.540ms] or [-5.735%; +6.036%]

scenario:appsec-appsec-enabled-26

  • unstable execution_time [-141.741ms; +191.853ms] or [-5.796%; +7.845%]

scenario:appsec-control-20

  • unstable execution_time [-149.804ms; +119.018ms] or [-8.724%; +6.931%]

scenario:appsec-control-24

  • unstable execution_time [-94296.381µs; +95453.915µs] or [-7.861%; +7.957%]

scenario:appsec-control-26

  • unstable execution_time [-94743.863µs; +92892.797µs] or [-8.044%; +7.887%]

scenario:debugger-line-probe-with-snapshot-default-20

  • unstable max_rss_usage [-10.055MB; +12.654MB] or [-5.493%; +6.913%]

scenario:dogstatsd-with-tags-20

  • unstable cpu_user_time [-278.000ms; +454.796ms] or [-5.850%; +9.571%]
  • unstable execution_time [-278.773ms; +456.592ms] or [-5.778%; +9.463%]

scenario:plugin-graphql-long-with-depth-and-collapse-off-24

  • unstable cpu_user_time [-374.784ms; +366.679ms] or [-8.406%; +8.224%]
  • unstable execution_time [-392623.654µs; +394245.254µs] or [-8.261%; +8.295%]
  • unstable max_rss_usage [-37.805MB; +40.659MB] or [-6.974%; +7.501%]

scenario:plugin-graphql-long-with-depth-off-20

  • unstable max_rss_usage [-12283.756KB; +11963.756KB] or [-8.988%; +8.754%]

scenario:spans-finish-later-26

  • unstable max_rss_usage [-6.156MB; +30.466MB] or [-3.533%; +17.484%]

scenario:test-optimization-large-suite-20

  • unstable max_rss_usage [-5437.962KB; +7047.962KB] or [-6.623%; +8.583%]

marcotc
marcotc previously approved these changes Jun 12, 2026

@marcotc marcotc left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

👍 from the OTel payload point of view.

Comment thread packages/dd-trace/src/opentelemetry/trace/index.js Outdated
Comment thread packages/dd-trace/src/opentelemetry/trace/otlp_http_trace_exporter.js Outdated
Comment thread packages/dd-trace/src/opentelemetry/trace/otlp_transformer.js Outdated
@zacharycmontoya
zacharycmontoya changed the base branch from zach.montoya/fix-otel-trace to master June 15, 2026 17:39
@zacharycmontoya
zacharycmontoya dismissed marcotc’s stale review June 15, 2026 17:39

The base branch was changed.

Comment thread packages/dd-trace/src/opentelemetry/bridge-span-base.js
Comment thread packages/dd-trace/src/opentelemetry/span-helpers.js Outdated
Comment thread packages/dd-trace/src/opentelemetry/span.js Outdated
Comment thread packages/dd-trace/src/opentelemetry/span-helpers.js Outdated
Comment thread packages/dd-trace/src/opentelemetry/span-helpers.js Outdated
Comment thread packages/dd-trace/src/opentelemetry/trace/otlp_http_trace_exporter.js Outdated
Comment thread packages/dd-trace/src/opentelemetry/trace/otlp_http_trace_exporter.js Outdated

@BridgeAR BridgeAR left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

LGTM, while a few calls could likely receive the argument in all situations.

@gh-worker-ownership-write-b05516
gh-worker-ownership-write-b05516 Bot removed the request for review from a team June 16, 2026 16:44
@zacharycmontoya
zacharycmontoya merged commit 68ed9ce into master Jun 16, 2026
801 checks passed
@zacharycmontoya
zacharycmontoya deleted the zach.montoya/opt-in-otel-semantics branch June 16, 2026 18:37
@dd-octo-sts dd-octo-sts Bot mentioned this pull request Jun 17, 2026
tlhunter pushed a commit that referenced this pull request Jun 18, 2026
…guration (#8894)

* Breaking change: Updates the `updateName` function in the OTel Bridge to update the DD span's resource name. Previously, this updated the operation name which was a bug

* Update OpenTelemetry express test with an updated assertion that reflects the updated API implementation

* Fix the accessors of the OTel Span Name to set/retrieve the resource name

* Address PR Feedback: use a private property to store the OTel name

* Address PR feedback: Remove 'setOtelOperationName' from span-helpers since it's only exercised by test code

* Address PR feedback: In 'updateName', check if the span is ended before updating the otel name

* Add a new opt-in configuration to enable stricter adherence to OpenTelemetry semantic conventions for tracing. Concretely, this results in the following changes:
- When emitting OTLP traces we omit Datadog-only attributes 'service.name', 'operation.name', 'span.type', and 'resource.name'
- The OTel Tracing API is updated to _not_ remap the attribute 'http.response.status_code'
- The OTel Tracing recordException API is updated to not write error tags on the span. The exception is entirely captured in a span event, per the OpenTelemetry specification
- The OTel Tracing setStatus API is updated to rewrite the span error message on the last update of the span status
- All behavior is enabled with the environment variable DD_TRACE_OTEL_COMPATIBILITY_ENABLED

* Rename the configuration from DD_TRACE_OTEL_COMPATIBILITY_ENABLED to DD_TRACE_OTEL_SEMANTICS_ENABLED

* Make the new setting DD_TRACE_OTEL_SEMANTICS_ENABLED only configurable via environment variables

* Remove unneeded in-code config

* Place the changes to updateName behind the DD_TRACE_OTEL_SEMANTICS_ENABLED configuration

* Address PR feedback: DD_TRACE_OTEL_SEMANTICS_ENABLED is always defined as a bool, so fix callsites

* Update setOtelAttribute and setOtelAttributes so the otelTraceSemanticsEnabled no longer has a default value - it doesn't need it

* Address PR feedback: Update the OTLP transformer so it does not emit the Datadog "error.message" attribute

* Update span-helpers and its tests so the 'otelTraceSemanticsEnabled' parameter is no longer optional

* Update packages/dd-trace/src/opentelemetry/trace/otlp_http_trace_exporter.js
@dd-octo-sts dd-octo-sts Bot mentioned this pull request Jun 26, 2026
pabloerhard pushed a commit that referenced this pull request Jun 26, 2026
…guration (#8894)

* Breaking change: Updates the `updateName` function in the OTel Bridge to update the DD span's resource name. Previously, this updated the operation name which was a bug

* Update OpenTelemetry express test with an updated assertion that reflects the updated API implementation

* Fix the accessors of the OTel Span Name to set/retrieve the resource name

* Address PR Feedback: use a private property to store the OTel name

* Address PR feedback: Remove 'setOtelOperationName' from span-helpers since it's only exercised by test code

* Address PR feedback: In 'updateName', check if the span is ended before updating the otel name

* Add a new opt-in configuration to enable stricter adherence to OpenTelemetry semantic conventions for tracing. Concretely, this results in the following changes:
- When emitting OTLP traces we omit Datadog-only attributes 'service.name', 'operation.name', 'span.type', and 'resource.name'
- The OTel Tracing API is updated to _not_ remap the attribute 'http.response.status_code'
- The OTel Tracing recordException API is updated to not write error tags on the span. The exception is entirely captured in a span event, per the OpenTelemetry specification
- The OTel Tracing setStatus API is updated to rewrite the span error message on the last update of the span status
- All behavior is enabled with the environment variable DD_TRACE_OTEL_COMPATIBILITY_ENABLED

* Rename the configuration from DD_TRACE_OTEL_COMPATIBILITY_ENABLED to DD_TRACE_OTEL_SEMANTICS_ENABLED

* Make the new setting DD_TRACE_OTEL_SEMANTICS_ENABLED only configurable via environment variables

* Remove unneeded in-code config

* Place the changes to updateName behind the DD_TRACE_OTEL_SEMANTICS_ENABLED configuration

* Address PR feedback: DD_TRACE_OTEL_SEMANTICS_ENABLED is always defined as a bool, so fix callsites

* Update setOtelAttribute and setOtelAttributes so the otelTraceSemanticsEnabled no longer has a default value - it doesn't need it

* Address PR feedback: Update the OTLP transformer so it does not emit the Datadog "error.message" attribute

* Update span-helpers and its tests so the 'otelTraceSemanticsEnabled' parameter is no longer optional

* Update packages/dd-trace/src/opentelemetry/trace/otlp_http_trace_exporter.js
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