Skip to content

Add Locale.ROOT to ConfigStrings Environment Variable Normalization#11979

Merged
gh-worker-dd-mergequeue-cf854d[bot] merged 2 commits into
masterfrom
mhlidd/add_locale_to_config_strings
Jul 17, 2026
Merged

Add Locale.ROOT to ConfigStrings Environment Variable Normalization#11979
gh-worker-dd-mergequeue-cf854d[bot] merged 2 commits into
masterfrom
mhlidd/add_locale_to_config_strings

Conversation

@mhlidd

@mhlidd mhlidd commented Jul 16, 2026

Copy link
Copy Markdown
Contributor

What Does This Do

Previously, Turkish Locale would uppercase i -> a dotted I. This led to issues w/ our telemetry monitors after hitting the backend, sparking false alarms that were were not properly capturing config telemetry.

This PR also replaces a duplicate function systemPropertyNameToEnvironmentVariableName to toEnvVar.

Motivation

Additional Notes

Contributor Checklist

Jira ticket: [PROJ-IDENT]

@mhlidd
mhlidd requested a review from a team as a code owner July 16, 2026 20:31
@dd-octo-sts

dd-octo-sts Bot commented Jul 16, 2026

Copy link
Copy Markdown
Contributor

Hi! 👋 Thanks for your pull request! 🎉

To help us review it, please make sure to:

  • Add at least one type, and one component or instrumentation label to the pull request

If you need help, please check our contributing guidelines.

@mhlidd
mhlidd requested review from PerfectSlayer and bm1549 July 16, 2026 20:32
@mhlidd mhlidd added type: bug fix Bug fix comp: config Configuration labels Jul 16, 2026

@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 PR correctly fixes a locale-sensitive bug where Turkish systems would corrupt config telemetry by converting 'i' → 'İ' (dotted I) instead of 'I'. Adding Locale.ROOT to toUpperCase() and toLowerCase() ensures all environment variable name conversions use ASCII-invariant transformations. The deprecated systemPropertyNameToEnvironmentVariableName() is safely removed and replaced with the fixed toEnvVar() at its only call site. The new test forces Turkish locale and verifies the fix prevents the corruption.

Was this helpful? React 👍 or 👎

📊 Validated against 6 scenarios · Open Bits AI session

🤖 Datadog Autotest · Commit f326662 · What is Autotest? · Any feedback? Reach out in #autotest

@bm1549 bm1549 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.

LGTM since it solves the issue at hand, but I do wonder how many of the remaining toUpperCase / toLowerCase instances may be causing similar problems we just haven't found yet

https://github.com/search?q=repo%3ADataDog%2Fdd-trace-java+Case%28%29&type=code

@datadog-datadog-prod-us1

datadog-datadog-prod-us1 Bot commented Jul 16, 2026

Copy link
Copy Markdown
Contributor

🎯 Code Coverage (details)
Patch Coverage: 50.00%
Overall Coverage: 57.26% (-0.04%)

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

@dd-octo-sts

dd-octo-sts Bot commented Jul 16, 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.94 s 13.90 s [-0.4%; +0.9%] (no difference)
startup:insecure-bank:tracing:Agent 12.91 s 13.02 s [-1.6%; -0.0%] (maybe better)
startup:petclinic:appsec:Agent 16.95 s 16.75 s [+0.2%; +2.3%] (maybe worse)
startup:petclinic:iast:Agent 16.39 s 16.97 s [-7.7%; +0.9%] (no difference)
startup:petclinic:profiling:Agent 16.64 s 16.83 s [-2.3%; +0.1%] (no difference)
startup:petclinic:sca:Agent 16.92 s 16.77 s [-0.2%; +1.9%] (no difference)
startup:petclinic:tracing:Agent 16.12 s 16.09 s [-0.7%; +1.1%] (no difference)

Commit: d2e62e8c · 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.

Comment on lines +18 to +19
@BeforeEach
void forceTurkishLocale() {

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.

❔ question: ‏Not sure it makes sense to force the Turkish locale for all tests (the current one and all comings next)
What about limiting it to the related test case instead?

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

Good Catch, I'll just add it to the test case itself

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

fixed in d2e62e8

@mhlidd
mhlidd added this pull request to the merge queue Jul 17, 2026
@dd-octo-sts

dd-octo-sts Bot commented Jul 17, 2026

Copy link
Copy Markdown
Contributor

/merge

@gh-worker-devflow-routing-ef8351

gh-worker-devflow-routing-ef8351 Bot commented Jul 17, 2026

Copy link
Copy Markdown

View all feedbacks in Devflow UI.

2026-07-17 17:48:39 UTC ℹ️ Start processing command /merge


2026-07-17 17:48:45 UTC ℹ️ MergeQueue: pull request added to the queue

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


2026-07-17 18:13:20 UTCMergeQueue: The build pipeline contains failing jobs for this merge request

Build pipeline has failing jobs for 92d254c:

⚠️ Do NOT retry failed jobs directly (why?).

What to do next?

  • Investigate the failures and when ready, re-add your pull request to the queue!
  • If your PR checks are green, try to rebase/merge. It might be because the CI run is a bit old.
  • Any question, go check the FAQ.
Details

Since those jobs are not marked as being allowed to fail, the pipeline will most likely fail.
Therefore, and to allow other builds to be processed, this merge request has been rejected and the pipeline got canceled.

@github-merge-queue
github-merge-queue Bot removed this pull request from the merge queue due to failed status checks Jul 17, 2026
@mhlidd
mhlidd added this pull request to the merge queue Jul 17, 2026
@dd-octo-sts

dd-octo-sts Bot commented Jul 17, 2026

Copy link
Copy Markdown
Contributor

/merge

@gh-worker-devflow-routing-ef8351

gh-worker-devflow-routing-ef8351 Bot commented Jul 17, 2026

Copy link
Copy Markdown

View all feedbacks in Devflow UI.

2026-07-17 18:50:31 UTC ℹ️ Start processing command /merge


2026-07-17 18:50:37 UTC ℹ️ MergeQueue: pull request added to the queue

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


2026-07-17 19:55:44 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 Jul 17, 2026
@gh-worker-dd-mergequeue-cf854d
gh-worker-dd-mergequeue-cf854d Bot merged commit e41dc82 into master Jul 17, 2026
781 of 783 checks passed
@gh-worker-dd-mergequeue-cf854d
gh-worker-dd-mergequeue-cf854d Bot deleted the mhlidd/add_locale_to_config_strings branch July 17, 2026 19:55
@github-actions github-actions Bot added this to the 1.65.0 milestone Jul 17, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

comp: config Configuration type: bug fix Bug fix

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants