Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

DEBUG-3182 DI railtie #4272

Merged
merged 17 commits into from
Jan 14, 2025
Merged

DEBUG-3182 DI railtie #4272

merged 17 commits into from
Jan 14, 2025

Conversation

p-datadog
Copy link
Member

What does this PR do?

Adds a Railtie for dynamic instrumentation. The railtie delays loading of DI contrib code (currently, ActiveRecord serializer) until Rails components have been loaded.

Also adds an integration test verifying AR serialization works correctly.

Motivation:

Improving DI reliability

Change log entry

Yes: improve loading of dynamic instrumentation components

Additional Notes:

How to test the change?

An integration test is added in this PR

@datadog-datadog-prod-us1
Copy link
Contributor

datadog-datadog-prod-us1 bot commented Jan 9, 2025

Datadog Report

Branch report: di-railtie
Commit report: 9fd1b0b
Test service: dd-trace-rb

✅ 0 Failed, 22181 Passed, 1477 Skipped, 4m 50.91s Total Time

@pr-commenter
Copy link

pr-commenter bot commented Jan 9, 2025

Benchmarks

Benchmark execution time: 2025-01-14 19:26:55

Comparing candidate commit 9fd1b0b in PR branch di-railtie with baseline commit 08743d9 in branch master.

Found 0 performance improvements and 0 performance regressions! Performance is the same for 31 metrics, 2 unstable metrics.

@codecov-commenter
Copy link

codecov-commenter commented Jan 13, 2025

Codecov Report

Attention: Patch coverage is 85.71429% with 2 lines in your changes missing coverage. Please review.

Project coverage is 97.71%. Comparing base (08743d9) to head (9fd1b0b).
Report is 2 commits behind head on master.

Files with missing lines Patch % Lines
lib/datadog/di/contrib.rb 81.81% 2 Missing ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##           master    #4272      +/-   ##
==========================================
- Coverage   97.72%   97.71%   -0.01%     
==========================================
  Files        1355     1356       +1     
  Lines       82433    82445      +12     
  Branches     4213     4216       +3     
==========================================
+ Hits        80555    80564       +9     
- Misses       1878     1881       +3     

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

@p-datadog p-datadog added this to the 2.9.0 milestone Jan 13, 2025
@p-datadog p-datadog merged commit 5361e8e into master Jan 14, 2025
378 checks passed
@p-datadog p-datadog deleted the di-railtie branch January 14, 2025 20:07
@p-datadog p-datadog mentioned this pull request Jan 15, 2025
p-datadog pushed a commit that referenced this pull request Jan 15, 2025
* master: (161 commits)
  Bump to version 2.9.0 (#4293)
  Increase type checking coverage (#4290)
  DEBUG-3329 rename datadog/di/init to datadog/di/preload (#4288)
  update supported versions workflow (#4289)
  DEBUG-3182 DI railtie (#4272)
  DEBUG-3328 report DI status in environment logger summary (#4285)
  Move out ostruct gem from test group for Ruby 3.5
  DEBUG-3316 verify code tracking works in forked processes (#4284)
  Fix rebase issue in Rack::RequestMiddleware
  Improve code style in AppSec rack middlewares
  Improve variable naming in Rack::RequestBodyMiddleware
  Improve variable naming in Rack::RequestMiddleware
  Simplify Rack::RequestMiddleware
  Switch AppSec rack blocking to throw
  Extract to .gitlab/scripts
  Implement polling vaccine
  Update RBS signatures
  Add new RSpec negate matcher not_change
  Replace direct AppSec::Processor::Context calls
  Change AppSec::Context exposed interface
  ...
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.

4 participants