Skip to content

Rename statement_sanitizer to query_sanitization#17116

Merged
trask merged 2 commits intoopen-telemetry:mainfrom
trask:rename-query-sanitizer
Apr 2, 2026
Merged

Rename statement_sanitizer to query_sanitization#17116
trask merged 2 commits intoopen-telemetry:mainfrom
trask:rename-query-sanitizer

Conversation

@trask
Copy link
Copy Markdown
Member

@trask trask commented Mar 27, 2026

This PR renames the preferred declarative database configuration terminology:

The old declarative names are still accepted for compatibility, but they are now deprecated.

Following the stable database terminology change from statement to query.

And aligning with telemetry builder configuration option names.

@github-actions github-actions Bot added the test native This label can be applied to PRs to trigger them to run native tests label Mar 27, 2026
@trask trask force-pushed the rename-query-sanitizer branch from 78cf133 to c4a09b2 Compare March 27, 2026 01:50
@trask trask marked this pull request as ready for review March 27, 2026 03:47
@trask trask requested a review from a team as a code owner March 27, 2026 03:47
Boolean deprecatedValue = config.get("statement_sanitizer").getBoolean("enabled");
if (deprecatedValue != null) {
logger.warning(
"statement_sanitizer is deprecated in declarative configuration"
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

how do you know that user is using declarative configuration not the system properties?

@trask trask force-pushed the rename-query-sanitizer branch from c4a09b2 to 24d1469 Compare March 30, 2026 00:37
@trask trask marked this pull request as draft March 30, 2026 00:37
@trask trask force-pushed the rename-query-sanitizer branch 6 times, most recently from d9249d3 to a475555 Compare March 31, 2026 19:33
@trask trask force-pushed the rename-query-sanitizer branch from a475555 to 30f8054 Compare April 1, 2026 01:41
@trask trask marked this pull request as ready for review April 2, 2026 01:50
SPECIAL_MAPPINGS.put(
"java.common.database.statement_sanitizer.enabled",
"java.common.db.query_sanitization.enabled",
"otel.instrumentation.common.db-statement-sanitizer.enabled");
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

should the system properties also be renamed?

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

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

yeah, I'll send follow-up

@trask trask merged commit 5ead3fa into open-telemetry:main Apr 2, 2026
182 of 183 checks passed
@trask trask deleted the rename-query-sanitizer branch April 2, 2026 17:28
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

test native This label can be applied to PRs to trigger them to run native tests

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants