-
Notifications
You must be signed in to change notification settings - Fork 375
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
peer.service adjustment for sql propagation with DBM #3127
Conversation
Codecov Report
@@ Coverage Diff @@
## master #3127 +/- ##
=======================================
Coverage 98.16% 98.16%
=======================================
Files 1323 1323
Lines 75292 75318 +26
Branches 3476 3476
=======================================
+ Hits 73908 73934 +26
Misses 1384 1384
📣 We’re building smart automated test selection to slash your CI/CD build times. Learn more |
spec/datadog/tracing/contrib/sql_comment_propagation_examples.rb
Outdated
Show resolved
Hide resolved
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
One minor nit.
@@ -102,6 +103,63 @@ | |||
end | |||
end | |||
|
|||
context 'when tracing is enabled with peer.service' do |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The description does not match the scenario, it only need a span_op with a specific tag
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I disagree, the main thing here is to mock a situation when tracing is enabled with peer.service
, ensuring that the peer.service
value is getting set as the dddbs
tag.
it only need a span_op with a specific tag
That's what the peer.service feature does. It adds a tag
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Sorry, I meant that the test could be simplified, for example,
We don't need
Datadog.configure do |c|
c.env = 'production'
c.service = "Traders' Joe"
c.version = '1.0.0'
end
Because, the method is stateless, only depends on the input.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The description should be
context 'when given a span operation tagged with`peer.service`' do
This reverts commit 1c5860d.
This PR addresses the issue of DBM relying on
service_name
for their own service names prior topeer.service
. Now since all services are flattened, the DBM map is inaccurate and a better tag to create a more accurate map is to usepeer.service