feat(trace_exporter): enable telemetry in stats exporter#2160
Conversation
|
Warning This pull request is not mergeable via GitHub because a downstack PR is open. Once all requirements are satisfied, merge this PR as a stack on Graphite.
This stack of pull requests is managed by Graphite. Learn more about stacking. |
🎉 All green!🧪 All tests passed 🎯 Code Coverage (details) 🔗 Commit SHA: 7059117 | Docs | Datadog PR Page | Give us feedback! |
📚 Documentation Check Results📦
|
Clippy Allow Annotation ReportComparing clippy allow annotations between branches:
Summary by Rule
Annotation Counts by File
Annotation Stats by Crate
About This ReportThis report tracks Clippy allow annotations for specific rules, showing how they've changed in this PR. Decreasing the number of these annotations generally improves code quality. |
🔒 Cargo Deny Results📦
|
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: e641e9a507
ℹ️ 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".
| metadata: &self.metadata, | ||
| endpoint_url: &self.endpoint.url, | ||
| shared_runtime: &self.shared_runtime, | ||
| dogstatsd: self.dogstatsd.clone(), |
There was a problem hiding this comment.
Gate stats DogStatsD metrics behind health-metrics opt-in
When stats computation is enabled and the agent supports it, forwarding self.dogstatsd here lets StatsExporter emit datadog.tracer.stats.collapsed_spans whenever spans are collapsed, even if the caller only configured set_dogstatsd_url() and did not call enable_health_metrics(). That bypasses the documented/default-disabled health-metrics guard used by emit_metric and emit_send_result, so users can start seeing DogStatsD health metrics despite leaving the feature disabled; pass None here unless self.health_metrics_enabled is true.
Useful? React with 👍 / 👎.
e641e9a to
adc72e5
Compare
98f8c1d to
fffe30d
Compare
adc72e5 to
dc75ab9
Compare
fffe30d to
e5c0f96
Compare
dc75ab9 to
372e45e
Compare
e5c0f96 to
d97928e
Compare
372e45e to
4dd43bf
Compare
d97928e to
c84447e
Compare
4dd43bf to
7059117
Compare
ajgajg1134
left a comment
There was a problem hiding this comment.
This looks good to me but I'm definitely not an expert in this area (yet? 😛)
Artifact Size Benchmark Reportaarch64-alpine-linux-musl
aarch64-unknown-linux-gnu
libdatadog-x64-windows
libdatadog-x86-windows
x86_64-alpine-linux-musl
x86_64-unknown-linux-gnu
|

What does this PR do?
Enable sending telemetry and health metrics from the stats exporter.
Motivation
What inspired you to submit this pull request?
Additional Notes
Anything else we should know when reviewing?
How to test the change?
Describe here in detail how the change can be validated.