Skip to content

feat(http): [Data Collection 12] Apply query parameter policy#5810

Draft
adinauer wants to merge 1 commit into
feat/data-collection-http-response-headersfrom
feat/data-collection-query-params
Draft

feat(http): [Data Collection 12] Apply query parameter policy#5810
adinauer wants to merge 1 commit into
feat/data-collection-http-response-headersfrom
feat/data-collection-query-params

Conversation

@adinauer

@adinauer adinauer commented Jul 22, 2026

Copy link
Copy Markdown
Member

PR Stack (Data Collection)


📜 Description

Apply the query-parameter Data Collection policy to automatic HTTP request data, spans, breadcrumbs, and failed-request events.

The policy is used by Servlet, Spring MVC/WebFlux, OpenTelemetry, OkHttp, Ktor, Apollo 2/3/4, OpenFeign, RestTemplate, and WebClient. Explicit Data Collection supports off, deny-list, and allow-list behavior. Built-in sensitive parameter names are always filtered, including when allow-listed. Encoded parameter names are decoded for matching while the original query encoding is retained.

When Data Collection is absent, integrations continue to attach raw query values as before.

💡 Motivation and Context

Query strings were collected automatically without a dedicated privacy control. This wires the existing dataCollection.queryParams option across Java HTTP integration paths while preserving the legacy bridge for applications that have not configured Data Collection.

Refs #5666

💚 How did you test it?

  • ./gradlew spotlessApply apiDump
  • ./gradlew :sentry:apiCheck
  • Core resolver, URL, and query-filter tests
  • Servlet and OpenTelemetry query tests
  • OkHttp query integration test
  • Full Ktor, Apollo 2/3/4, OpenFeign, Spring, Spring Jakarta, and Spring 7 test suites
  • git diff --check

📝 Checklist

  • I added GH Issue ID & Linear ID
  • I added tests to verify the changes.
  • No new PII added or SDK only sends newly added PII if sendDefaultPII is enabled.
  • I updated the docs if needed.
  • I updated the wizard if needed.
  • Review from the native team if needed.
  • No breaking change or entry added to the changelog.
  • No breaking change for hybrid SDKs or communicated to hybrid SDKs.
  • Public API changes reviewed by another Mobile SDK team member or implemented according to the develop docs spec.

🔮 Next steps

Migrate cookie collection and complete the remaining Data Collection configuration and integration work.

#skip-changelog

⚠️ Merge this PR using a merge commit (not squash). Only the collection branch is squash-merged into main.

Filter automatically collected URL query parameters according to Data Collection settings across server, client, tracing, breadcrumb, and failed-request integrations.

Preserve raw query values when Data Collection is absent and always filter built-in sensitive parameter names in explicit mode.

Refs #5666

Co-Authored-By: Claude <noreply@anthropic.com>
@github-actions

Copy link
Copy Markdown
Contributor
Messages
📖 Do not forget to update Sentry-docs with your feature once the pull request gets approved.

Generated by 🚫 dangerJS against d9a1422

@sentry

sentry Bot commented Jul 22, 2026

Copy link
Copy Markdown

📲 Install Builds

Android

🔗 App Name App ID Version Configuration
SDK Size io.sentry.tests.size 8.48.0 (1) release

⚙️ sentry-android Build Distribution Settings

@github-actions

Copy link
Copy Markdown
Contributor

Performance metrics 🚀

  Plain With Sentry Diff
Startup time 319.94 ms 371.16 ms 51.22 ms
Size 0 B 0 B 0 B

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.

1 participant