Skip to content

[ruby] Add support for enhanced config reporting in ruby#6643

Merged
vpellan merged 1 commit intomainfrom
vpellan/ruby-telemetry-enhanced-config-reporting
Mar 30, 2026
Merged

[ruby] Add support for enhanced config reporting in ruby#6643
vpellan merged 1 commit intomainfrom
vpellan/ruby-telemetry-enhanced-config-reporting

Conversation

@vpellan
Copy link
Copy Markdown
Contributor

@vpellan vpellan commented Mar 30, 2026

Motivation

Wrapping up config viz for 26Q1

Changes

Programmatically activate logs injection if CONFIG_CHAINING_TEST env var is detected on Ruby weblogs. Add ruby in EXPECTED_CONFIGS. Disable easy-wins that are now failing (they were not supposed to pass anyway). They will be reenabled once DataDog/dd-trace-rb#5483 is merged

Workflow

  1. ⚠️ Create your PR as draft ⚠️
  2. Work on you PR until the CI passes
  3. Mark it as ready for review
    • Test logic is modified? -> Get a review from RFC owner.
    • Framework is modified, or non obvious usage of it -> get a review from R&P team

🚀 Once your PR is reviewed and the CI green, you can merge it!

🛟 #apm-shared-testing 🛟

Reviewer checklist

  • Anything but tests/ or manifests/ is modified ? I have the approval from R&P team
  • A docker base image is modified?
    • the relevant build-XXX-image label is present
  • A scenario is added, removed or renamed?

@vpellan vpellan requested review from a team as code owners March 30, 2026 11:43
@vpellan vpellan requested review from anna-git and paullegranddc and removed request for a team March 30, 2026 11:43
@github-actions
Copy link
Copy Markdown
Contributor

CODEOWNERS have been resolved as:

manifests/ruby.yml                                                      @DataDog/ruby-guild @DataDog/asm-ruby
tests/test_telemetry.py                                                 @DataDog/libdatadog-telemetry @DataDog/apm-sdk-capabilities @DataDog/system-tests-core
utils/build/docker/ruby/rack/config.ru                                  @DataDog/ruby-guild @DataDog/asm-ruby @DataDog/system-tests-core
utils/build/docker/ruby/rails42/config/initializers/datadog.rb          @DataDog/ruby-guild @DataDog/asm-ruby @DataDog/system-tests-core
utils/build/docker/ruby/rails52/config/initializers/datadog.rb          @DataDog/ruby-guild @DataDog/asm-ruby @DataDog/system-tests-core
utils/build/docker/ruby/rails61/config/initializers/datadog.rb          @DataDog/ruby-guild @DataDog/asm-ruby @DataDog/system-tests-core
utils/build/docker/ruby/rails72/config/initializers/datadog.rb          @DataDog/ruby-guild @DataDog/asm-ruby @DataDog/system-tests-core
utils/build/docker/ruby/rails80/config/initializers/datadog.rb          @DataDog/ruby-guild @DataDog/asm-ruby @DataDog/system-tests-core
utils/build/docker/ruby/sinatra14/app.rb                                @DataDog/ruby-guild @DataDog/asm-ruby @DataDog/system-tests-core
utils/build/docker/ruby/sinatra22/app.rb                                @DataDog/ruby-guild @DataDog/asm-ruby @DataDog/system-tests-core
utils/build/docker/ruby/sinatra32/app.rb                                @DataDog/ruby-guild @DataDog/asm-ruby @DataDog/system-tests-core
utils/build/docker/ruby/sinatra41/app.rb                                @DataDog/ruby-guild @DataDog/asm-ruby @DataDog/system-tests-core

Copy link
Copy Markdown

@chatgpt-codex-connector chatgpt-codex-connector bot left a comment

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: ac93d5952e

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


Datadog.configure do |c|
c.diagnostics.debug = true
c.tracing.log_injection = true if ENV['CONFIG_CHAINING_TEST'] == 'true'
Copy link
Copy Markdown

Choose a reason for hiding this comment

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

P2 Badge Guard c.tracing access behind capability check

CONFIG_CHAINING_TEST now triggers c.tracing.log_injection = true unconditionally, but this initializer still explicitly supports legacy tracer config objects right below via c.respond_to?(:tracing). For tracer versions that do not expose c.tracing, enabling this scenario env var causes a boot-time exception before the fallback path can run, so the Ruby weblog fails to start. Please guard this new assignment with the same capability check (and apply the same fix to the other Ruby weblog initializers changed in this commit).

Useful? React with 👍 / 👎.

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

datadog-datadog-prod-us1-2 bot commented Mar 30, 2026

✅ Tests

🎉 All green!

❄️ No new flaky tests detected
🧪 All tests passed

This comment will be updated automatically if new data arrives.
🔗 Commit SHA: ac93d59 | Docs | Datadog PR Page | Was this helpful? React with 👍/👎 or give us feedback!

@vpellan vpellan enabled auto-merge (squash) March 30, 2026 14:14
@vpellan vpellan merged commit 57bce52 into main Mar 30, 2026
1956 of 1961 checks passed
@vpellan vpellan deleted the vpellan/ruby-telemetry-enhanced-config-reporting branch March 30, 2026 15:42
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants