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

fix(ddtrace/tracer): refactor DogStatsD URL resolution using agent-reported StatsD port #2995

Merged
merged 5 commits into from
Nov 27, 2024

Conversation

darccio
Copy link
Member

@darccio darccio commented Nov 27, 2024

What does this PR do?

It's a follow-up from #2931, that introduced a new behaviour to make sure metrics are reported properly by overriding any user-provided host:port address using the agent-reported StatsD port from the agent /info endpoint.

Motivation

Fixing a bug causing runtime metrics to not be reported when using WithDogstatsdAddr with UDS paths.

Reviewer's Checklist

  • Changed code has unit tests for its functionality at or near 100% coverage.
  • System-Tests covering this feature have been added and enabled with the va.b.c-dev version tag.
  • There is a benchmark for any new code, or changes to existing code.
  • If this interacts with the agent in a new way, a system test has been added.
  • Add an appropriate team label so this PR gets put in the right place for the release notes.
  • Non-trivial go.mod changes, e.g. adding new modules, are reviewed by @DataDog/dd-trace-go-guild.

Unsure? Have a question? Request a review!

@darccio darccio requested a review from a team as a code owner November 27, 2024 13:59
Comment on lines -687 to -689
type agentConfig struct {
DefaultEnv string `json:"default_env"`
}
Copy link
Member Author

Choose a reason for hiding this comment

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

Just some housekeeping. Linting reported this type as unused.

@pr-commenter
Copy link

pr-commenter bot commented Nov 27, 2024

Benchmarks

Benchmark execution time: 2024-11-27 14:35:55

Comparing candidate commit 9a69867 in PR branch dario.castane/incident-32698-followup with baseline commit e9a64d3 in branch main.

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

scenario:BenchmarkHttpServeTrace-24

  • 🟩 execution_time [-459.831ns; -400.169ns] or [-2.829%; -2.462%]

@darccio darccio merged commit 63e7470 into main Nov 27, 2024
159 of 160 checks passed
@darccio darccio deleted the dario.castane/incident-32698-followup branch November 27, 2024 17:17
darccio added a commit that referenced this pull request Nov 27, 2024
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