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

Add dynamically configurable sampling rules #3598

Merged
merged 1 commit into from
Apr 29, 2024
Merged

Add dynamically configurable sampling rules #3598

merged 1 commit into from
Apr 29, 2024

Conversation

marcotc
Copy link
Member

@marcotc marcotc commented Apr 17, 2024

What does this PR do?

tracing_sampling_rules is now provided in the dynamic remote configuration payload, and configures the local trace sampling rules.

Also, each sampling rule has a new field, called provenance, which allows us to track through the decision-maker tag (_dd.p.dm) where is sampling decision came from. This even applies for locally configured rules, which get the default value of local provenance.

How to test the change?
There are units tests for all changes, plus system tests for integration testing: DataDog/system-tests#2361

Unsure? Have a question? Request a review!

@marcotc marcotc requested a review from ZStriker19 April 17, 2024 21:00
@marcotc marcotc self-assigned this Apr 17, 2024
@marcotc marcotc requested review from a team as code owners April 17, 2024 21:00
@codecov-commenter
Copy link

Codecov Report

Attention: Patch coverage is 96.51163% with 3 lines in your changes are missing coverage. Please review.

Project coverage is 98.24%. Comparing base (36e37fc) to head (39a6034).

Files Patch % Lines
lib/datadog/tracing/configuration/dynamic.rb 82.35% 3 Missing ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##           master    #3598      +/-   ##
==========================================
- Coverage   98.24%   98.24%   -0.01%     
==========================================
  Files        1255     1255              
  Lines       74569    74641      +72     
  Branches     3540     3548       +8     
==========================================
+ Hits        73263    73332      +69     
- Misses       1306     1309       +3     

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

Copy link
Contributor

@TonyCTHsu TonyCTHsu left a comment

Choose a reason for hiding this comment

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

Since I have already compile the changelog for 2.0 in 2.0.0.beta1. Could you add this entry under the [Unreleased] section at Changelog.md.

@marcotc
Copy link
Member Author

marcotc commented Apr 19, 2024

@TonyCTHsu would you like me to change https://github.com/DataDog/dd-trace-rb/blob/master/CHANGELOG.md directly in this PR?

@TonyCTHsu
Copy link
Contributor

@TonyCTHsu would you like me to change https://github.com/DataDog/dd-trace-rb/blob/master/CHANGELOG.md directly in this PR?

That is also feasible 🎉

@marcotc marcotc merged commit 370d7b1 into master Apr 29, 2024
207 checks passed
@marcotc marcotc deleted the rc-rules branch April 29, 2024 20:19
@github-actions github-actions bot added this to the 2.0.0 milestone Apr 29, 2024
@TonyCTHsu TonyCTHsu mentioned this pull request Jun 6, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants