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

contrib/database/sql: allow peer.service to be set explicitly and add into propagated context #2679

Merged
merged 5 commits into from
May 22, 2024

Conversation

tabgok
Copy link
Contributor

@tabgok tabgok commented May 1, 2024

What does this PR do?

This PR does two things:

  1. Adds peer.service to the SQL Connection context if set explicitly by a user via the Traced Connector Context or tag
  2. Adds ddprs=peer.service to the SQL Comment propagation when full mode is enabled

Motivation

This change allows the DBM and APM service maps to line up

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!

@tabgok tabgok requested a review from a team as a code owner May 1, 2024 17:18
@github-actions github-actions bot added the apm:ecosystem contrib/* related feature requests or bugs label May 1, 2024
@tabgok tabgok marked this pull request as draft May 1, 2024 17:33
@pr-commenter
Copy link

pr-commenter bot commented May 1, 2024

Benchmarks

Benchmark execution time: 2024-05-22 14:35:14

Comparing candidate commit 26753a3 in PR branch teague.bick/AIT-10033/dbm-peer-entity with baseline commit 14d15d5 in branch main.

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

contrib/database/sql/conn.go Outdated Show resolved Hide resolved
@tabgok tabgok force-pushed the teague.bick/AIT-10033/dbm-peer-entity branch from 520f307 to 6d3dac2 Compare May 10, 2024 12:31
@tabgok tabgok requested a review from rarguelloF May 10, 2024 12:35
@tabgok tabgok marked this pull request as ready for review May 10, 2024 13:05
@tabgok tabgok requested a review from a team as a code owner May 10, 2024 13:05
ddtrace/tracer/sqlcomment.go Outdated Show resolved Hide resolved
contrib/database/sql/conn.go Show resolved Hide resolved
contrib/database/sql/conn.go Outdated Show resolved Hide resolved
@tabgok tabgok force-pushed the teague.bick/AIT-10033/dbm-peer-entity branch from ccdb257 to dde9ab3 Compare May 15, 2024 12:23
@tabgok tabgok requested a review from rarguelloF May 16, 2024 12:28
contrib/database/sql/conn.go Outdated Show resolved Hide resolved
contrib/database/sql/conn.go Outdated Show resolved Hide resolved
@tabgok tabgok requested a review from rarguelloF May 20, 2024 12:13
@tabgok tabgok enabled auto-merge (squash) May 20, 2024 12:47
@tabgok tabgok self-assigned this May 20, 2024
@tabgok tabgok disabled auto-merge May 22, 2024 12:36
@tabgok tabgok changed the title contrib/database/sql: allow peer.service to be set explicitly and add… contrib/database/sql: allow peer.service to be set explicitly and add into propagated context May 22, 2024
@tabgok tabgok enabled auto-merge (squash) May 22, 2024 13:24
@tabgok tabgok disabled auto-merge May 22, 2024 13:34
@tabgok
Copy link
Contributor Author

tabgok commented May 22, 2024

/merge

@dd-devflow
Copy link

dd-devflow bot commented May 22, 2024

❌ MergeQueue

You are not allowed to use the merge queue towards main.

If you need support, contact us on Slack #devflow with those details!

@darccio
Copy link
Contributor

darccio commented May 22, 2024

@tabgok I'll handle the merge.

@darccio darccio merged commit b0aa1b8 into main May 22, 2024
158 checks passed
@darccio darccio deleted the teague.bick/AIT-10033/dbm-peer-entity branch May 22, 2024 14:59
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
apm:ecosystem contrib/* related feature requests or bugs
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

4 participants