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

[v2] contrib/net/http: Make DD_TRACE_HTTP_CLIENT_TAG_QUERY_STRING false by default #3020

Merged
merged 1 commit into from
Dec 10, 2024

Conversation

mtoffl01
Copy link
Contributor

@mtoffl01 mtoffl01 commented Dec 9, 2024

What does this PR do?

By default, query string is not collected on http client spans.

Motivation

Without the ability to obfuscate the query string (like what DD_TRACE_OBFUSCATION_QUERY_STRING_REGEXP does for http server spans), collecting it by default poses a security risk. Thus, we are disabling it by default, allowing users to opt-in to the feature if they so choose.

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.
  • For internal contributors, a matching PR should be created to the v2-dev branch and reviewed by @DataDog/apm-go.

Unsure? Have a question? Request a review!

@mtoffl01 mtoffl01 requested review from a team as code owners December 9, 2024 19:30
@mtoffl01 mtoffl01 requested a review from tonyredondo December 9, 2024 19:30
@mtoffl01 mtoffl01 marked this pull request as draft December 9, 2024 19:30
@mtoffl01 mtoffl01 changed the base branch from main to v2-dev December 9, 2024 20:16
@pr-commenter
Copy link

pr-commenter bot commented Dec 9, 2024

Benchmarks

Benchmark execution time: 2024-12-09 20:11:22

Comparing candidate commit b095107 in PR branch mtoff/disable-client-querystring-v2 with baseline commit 63e7470 in branch main.

Some scenarios are present only in baseline or only in candidate runs. If you didn't create or remove some scenarios in your branch, this maybe a sign of crashed benchmarks 💥💥💥
Check Gitlab CI job log to find if any benchmark has crashed.

Scenarios present only in baseline:

  • BenchmarkStartRequestSpan-24
  • BenchmarkSampleWAFContext-24

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

scenario:BenchmarkHttpServeTrace-24

  • 🟥 allocated_mem [+194 bytes; +231 bytes] or [+2.031%; +2.419%]
  • 🟥 allocations [+5; +5] or [+6.329%; +6.329%]
  • 🟥 execution_time [+413.113ns; +544.487ns] or [+2.526%; +3.329%]

scenario:BenchmarkOTelApiWithCustomTags/otel_api-24

  • 🟥 execution_time [+291.797ns; +372.803ns] or [+4.125%; +5.270%]

scenario:BenchmarkPartialFlushing/Disabled-24

  • 🟥 execution_time [+9.210ms; +11.684ms] or [+3.438%; +4.362%]

scenario:BenchmarkPartialFlushing/Enabled-24

  • 🟥 execution_time [+8.166ms; +12.094ms] or [+2.994%; +4.434%]

scenario:BenchmarkSetTagString-24

  • 🟥 execution_time [+4.144ns; +6.896ns] or [+3.741%; +6.225%]

scenario:BenchmarkSingleSpanRetention/no-rules-24

  • 🟥 execution_time [+8.839µs; +12.365µs] or [+3.737%; +5.228%]

scenario:BenchmarkSingleSpanRetention/with-rules/match-all-24

  • 🟥 execution_time [+8.403µs; +11.415µs] or [+3.531%; +4.796%]

scenario:BenchmarkSingleSpanRetention/with-rules/match-half-24

  • 🟥 execution_time [+8.054µs; +11.804µs] or [+3.382%; +4.956%]

scenario:BenchmarkTracerAddSpans-24

  • 🟥 allocated_mem [+56 bytes; +57 bytes] or [+2.461%; +2.478%]
  • 🟥 execution_time [+104.228ns; +144.572ns] or [+2.678%; +3.715%]

@github-actions github-actions bot added the apm:ecosystem contrib/* related feature requests or bugs label Dec 9, 2024
@mtoffl01 mtoffl01 marked this pull request as ready for review December 9, 2024 22:17
@RomainMuller RomainMuller merged commit 2696801 into v2-dev Dec 10, 2024
5 checks passed
@RomainMuller RomainMuller deleted the mtoff/disable-client-querystring-v2 branch December 10, 2024 09:05
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.

2 participants