Skip to content

Fix application service names beneath inferred proxy spans - #12553

Merged
gh-worker-dd-mergequeue-cf854d[bot] merged 2 commits into
masterfrom
matthew.li/fix-inferred-proxy-service-inheritance
Sep 21, 2026
Merged

gh-worker-dd-mergequeue-cf854d[bot] merged 2 commits into
masterfrom
matthew.li/fix-inferred-proxy-service-inheritance

Conversation

@mhlidd

@mhlidd mhlidd commented Sep 17, 2026 •

Copy link
Copy Markdown
Contributor

What Does This Do

Fix application descendant spans incorrectly using the gateway service name when both
DD_TRACE_INFERRED_PROXY_SERVICES_ENABLED and DD_TRACE_REMOVE_INTEGRATION_SERVICE_NAMES_ENABLED are
enabled.

For example, with application service checkout and inferred gateway service gateway.example.com:

  • The inferred proxy span correctly uses gateway.example.com.
  • The application entry span correctly uses checkout.
  • Before this change, application descendants are incorrectly overwritten with gateway.example.com.
  • After this change, those descendants retain checkout, including its service-name source.

When the local root is an inferred proxy, skip the root-service override and preserve the service name
and source already resolved for the child span.

Motivation

An inferred proxy identifies an upstream gateway. Its service name should not replace the application
service on downstream application spans when integration service names are removed.

Additional Notes

Contributor Checklist

Jira ticket: [PROJ-IDENT]

@datadog-datadog-prod-us1

This comment has been minimized.

@dd-octo-sts

dd-octo-sts Bot commented Sep 17, 2026 •

Copy link
Copy Markdown
Contributor

🟢 Java Benchmark SLOs — All performance SLOs passed

Suite Status
Startup 🟢 pass

SLO thresholds are defined here based on automatically generated metrics. A warning is raised when results are within 5% of the threshold.

PR vs. master results
Scenario Candidate master Δ (95% CI of mean)
startup:insecure-bank:iast:Agent 13.96 s 13.87 s [-0.1%; +1.3%] (no difference)
startup:insecure-bank:tracing:Agent 12.91 s 12.95 s [-1.0%; +0.4%] (no difference)
startup:petclinic:appsec:Agent 17.12 s 17.03 s [-0.4%; +1.5%] (no difference)
startup:petclinic:iast:Agent 17.02 s 17.06 s [-1.0%; +0.5%] (no difference)
startup:petclinic:profiling:Agent 16.53 s 16.70 s [-1.8%; -0.2%] (maybe better)
startup:petclinic:sca:Agent 17.01 s 16.93 s [-0.6%; +1.5%] (no difference)
startup:petclinic:tracing:Agent 15.80 s 16.19 s [-6.7%; +1.8%] (no difference)

Commit: d0f09048 · CI Pipeline · Benchmarking Platform UI


Load and DaCapo benchmarks can be triggered manually in the GitLab pipeline. Results will appear in the Benchmarking Platform UI after completion.

@mhlidd mhlidd changed the title prevent inferred proxy service names from overriding application chil… Prevent Inferred Proxy Service Names from Overriding Application Child Span Services Sep 18, 2026
@mhlidd mhlidd changed the title Prevent Inferred Proxy Service Names from Overriding Application Child Span Services Fix application service names beneath inferred proxy spans Sep 18, 2026
@mhlidd mhlidd added type: bug fix Bug fix comp: core Tracer core tag: ai generated Largely based on code generated by an AI or LLM labels Sep 18, 2026
@mhlidd
mhlidd marked this pull request as ready for review September 18, 2026 15:38
@mhlidd
mhlidd requested a review from a team as a code owner September 18, 2026 15:38
@mhlidd
mhlidd requested review from sarahchen6 and removed request for a team September 18, 2026 15:38

@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: c93f17f93e

ℹ️ 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".

Comment thread dd-trace-core/src/main/java/datadog/trace/core/CoreTracer.java Outdated
Comment thread dd-trace-core/src/main/java/datadog/trace/core/CoreTracer.java Outdated

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

Datadog Autotest: PASS

More details

The inferred-proxy check keeps the application service name on child spans. The standard root-span behavior stays unchanged.

Was this helpful? React 👍 or 👎

Open Bits AI session

🤖 Datadog Autotest · Commit c93f17f · What is Autotest? · @DataDog review to ask questions · Any feedback? Reach out in #autotest

@mhlidd
mhlidd enabled auto-merge September 18, 2026 20:04
@mhlidd
mhlidd added this pull request to the merge queue Sep 21, 2026
@dd-octo-sts

dd-octo-sts Bot commented Sep 21, 2026

Copy link
Copy Markdown
Contributor

/merge

@gh-worker-devflow-routing-ef8351

gh-worker-devflow-routing-ef8351 Bot commented Sep 21, 2026 •

Copy link
Copy Markdown

View all feedbacks in Devflow UI.

2026-09-21 13:17:44 UTC ℹ️ Start processing command /merge


2026-09-21 13:17:50 UTC ℹ️ MergeQueue: pull request added to the queue

The expected merge time in master is approximately 1h (p90).


2026-09-21 14:19:33 UTC ℹ️ MergeQueue: This merge request was merged

@github-merge-queue
github-merge-queue Bot removed this pull request from the merge queue due to failed status checks Sep 21, 2026
@gh-worker-dd-mergequeue-cf854d
gh-worker-dd-mergequeue-cf854d Bot merged commit 2cfe4bc into master Sep 21, 2026
605 checks passed
@gh-worker-dd-mergequeue-cf854d
gh-worker-dd-mergequeue-cf854d Bot deleted the matthew.li/fix-inferred-proxy-service-inheritance branch September 21, 2026 14:19
@github-actions github-actions Bot added this to the 1.67.0 milestone Sep 21, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

comp: core Tracer core tag: ai generated Largely based on code generated by an AI or LLM type: bug fix Bug fix

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants