From ef645c369b0fae47faaf61d45392cd8a8f78d85b Mon Sep 17 00:00:00 2001 From: Lukas Stracke Date: Mon, 27 Jul 2026 11:32:33 +0200 Subject: [PATCH 1/2] feat(attributes): Deprecate `http.query` and `http.fragment` in favour of `url.query` and `url.fragment` --- .../sentry-conventions/src/attributes.ts | 22 +++++++++++++++++++ model/attributes/http/http__fragment.json | 5 +++++ model/attributes/http/http__query.json | 5 +++++ model/attributes/url/url__fragment.json | 1 + model/attributes/url/url__query.json | 1 + python/src/sentry_conventions/attributes.py | 18 +++++++++++++++ 6 files changed, 52 insertions(+) diff --git a/javascript/sentry-conventions/src/attributes.ts b/javascript/sentry-conventions/src/attributes.ts index 3916ccec..4ee17e65 100644 --- a/javascript/sentry-conventions/src/attributes.ts +++ b/javascript/sentry-conventions/src/attributes.ts @@ -8723,6 +8723,9 @@ export type HTTP_FLAVOR_TYPE = string; * Attribute defined in OTEL: No * Visibility: public * + * Aliases: {@link URL_FRAGMENT} `url.fragment` + * + * @deprecated Use {@link URL_FRAGMENT} (url.fragment) instead * @example "#details" */ export const HTTP_FRAGMENT = 'http.fragment'; @@ -8792,6 +8795,9 @@ export type HTTP_METHOD_TYPE = string; * Attribute defined in OTEL: No * Visibility: public * + * Aliases: {@link URL_QUERY} `url.query` + * + * @deprecated Use {@link URL_QUERY} (url.query) instead * @example "?foo=bar&bar=baz" */ export const HTTP_QUERY = 'http.query'; @@ -15940,6 +15946,8 @@ export type URL_DOMAIN_TYPE = string; * Attribute defined in OTEL: Yes * Visibility: public * + * Aliases: {@link HTTP_FRAGMENT} `http.fragment` + * * @example "details" */ export const URL_FRAGMENT = 'url.fragment'; @@ -16056,6 +16064,8 @@ export type URL_PORT_TYPE = number; * Attribute defined in OTEL: Yes * Visibility: public * + * Aliases: {@link HTTP_QUERY} `http.query` + * * @example "foo=bar&bar=baz" */ export const URL_QUERY = 'url.query'; @@ -24320,6 +24330,11 @@ export const ATTRIBUTE_METADATA: Record = { isInOtel: false, visibility: 'public', example: '#details', + deprecation: { + replacement: 'url.fragment', + status: 'backfill', + }, + aliases: ['url.fragment'], changelog: [{ version: '0.0.0' }], }, 'http.host': { @@ -24366,6 +24381,11 @@ export const ATTRIBUTE_METADATA: Record = { isInOtel: false, visibility: 'public', example: '?foo=bar&bar=baz', + deprecation: { + replacement: 'url.query', + status: 'backfill', + }, + aliases: ['url.query'], changelog: [{ version: '0.0.0' }], }, 'http.request.body.data': { @@ -28755,6 +28775,7 @@ export const ATTRIBUTE_METADATA: Record = { isInOtel: true, visibility: 'public', example: 'details', + aliases: ['http.fragment'], changelog: [{ version: '0.0.0' }], }, 'url.full': { @@ -28821,6 +28842,7 @@ export const ATTRIBUTE_METADATA: Record = { isInOtel: true, visibility: 'public', example: 'foo=bar&bar=baz', + aliases: ['http.query'], changelog: [{ version: '0.0.0' }], }, 'url.same_origin': { diff --git a/model/attributes/http/http__fragment.json b/model/attributes/http/http__fragment.json index f9d21b77..5668a6d8 100644 --- a/model/attributes/http/http__fragment.json +++ b/model/attributes/http/http__fragment.json @@ -5,6 +5,11 @@ "apply_scrubbing": { "key": "auto" }, + "deprecation": { + "_status": "backfill", + "replacement": "url.fragment" + }, + "alias": ["url.fragment"], "is_in_otel": false, "example": "#details", "visibility": "public", diff --git a/model/attributes/http/http__query.json b/model/attributes/http/http__query.json index d0cb0588..96442512 100644 --- a/model/attributes/http/http__query.json +++ b/model/attributes/http/http__query.json @@ -6,6 +6,11 @@ "key": "auto", "reason": "Query string values can contain sensitive information. Clients should attempt to scrub parameters that might contain sensitive information." }, + "deprecation": { + "_status": "backfill", + "replacement": "url.query" + }, + "alias": ["url.query"], "is_in_otel": false, "example": "?foo=bar&bar=baz", "visibility": "public", diff --git a/model/attributes/url/url__fragment.json b/model/attributes/url/url__fragment.json index a7b8bce3..26bf101f 100644 --- a/model/attributes/url/url__fragment.json +++ b/model/attributes/url/url__fragment.json @@ -5,6 +5,7 @@ "apply_scrubbing": { "key": "auto" }, + "alias": ["http.fragment"], "is_in_otel": true, "example": "details", "visibility": "public", diff --git a/model/attributes/url/url__query.json b/model/attributes/url/url__query.json index c5450c5b..6d3535d4 100644 --- a/model/attributes/url/url__query.json +++ b/model/attributes/url/url__query.json @@ -6,6 +6,7 @@ "key": "auto", "reason": "Query string values can contain sensitive information. Clients should attempt to scrub parameters that might contain sensitive information." }, + "alias": ["http.query"], "is_in_otel": true, "example": "foo=bar&bar=baz", "visibility": "public", diff --git a/python/src/sentry_conventions/attributes.py b/python/src/sentry_conventions/attributes.py index 49a20210..e54bd469 100644 --- a/python/src/sentry_conventions/attributes.py +++ b/python/src/sentry_conventions/attributes.py @@ -221,8 +221,10 @@ class _AttributeNamesMeta(type): "HARDWARECONCURRENCY", "HTTP_CLIENT_IP", "HTTP_FLAVOR", + "HTTP_FRAGMENT", "HTTP_HOST", "HTTP_METHOD", + "HTTP_QUERY", "_HTTP_REQUEST_METHOD", "HTTP_RESPONSE_CONTENT_LENGTH", "HTTP_RESPONSE_TRANSFER_SIZE", @@ -5260,6 +5262,8 @@ class ATTRIBUTE_NAMES(metaclass=_AttributeNamesMeta): Apply Scrubbing: auto Defined in OTEL: No Visibility: public + Aliases: url.fragment + DEPRECATED: Use url.fragment instead Example: "#details" """ @@ -5297,6 +5301,8 @@ class ATTRIBUTE_NAMES(metaclass=_AttributeNamesMeta): Apply Scrubbing: auto - Query string values can contain sensitive information. Clients should attempt to scrub parameters that might contain sensitive information. Defined in OTEL: No Visibility: public + Aliases: url.query + DEPRECATED: Use url.query instead Example: "?foo=bar&bar=baz" """ @@ -9229,6 +9235,7 @@ class ATTRIBUTE_NAMES(metaclass=_AttributeNamesMeta): Apply Scrubbing: auto Defined in OTEL: Yes Visibility: public + Aliases: http.fragment Example: "details" """ @@ -9289,6 +9296,7 @@ class ATTRIBUTE_NAMES(metaclass=_AttributeNamesMeta): Apply Scrubbing: auto - Query string values can contain sensitive information. Clients should attempt to scrub parameters that might contain sensitive information. Defined in OTEL: Yes Visibility: public + Aliases: http.query Example: "foo=bar&bar=baz" """ @@ -15976,6 +15984,10 @@ class ATTRIBUTE_NAMES(metaclass=_AttributeNamesMeta): is_in_otel=False, visibility=Visibility.PUBLIC, example="#details", + deprecation=DeprecationInfo( + replacement="url.fragment", status=DeprecationStatus.BACKFILL + ), + aliases=["url.fragment"], changelog=[ ChangelogEntry(version="0.0.0"), ], @@ -16029,6 +16041,10 @@ class ATTRIBUTE_NAMES(metaclass=_AttributeNamesMeta): is_in_otel=False, visibility=Visibility.PUBLIC, example="?foo=bar&bar=baz", + deprecation=DeprecationInfo( + replacement="url.query", status=DeprecationStatus.BACKFILL + ), + aliases=["url.query"], changelog=[ ChangelogEntry(version="0.0.0"), ], @@ -20634,6 +20650,7 @@ class ATTRIBUTE_NAMES(metaclass=_AttributeNamesMeta): is_in_otel=True, visibility=Visibility.PUBLIC, example="details", + aliases=["http.fragment"], changelog=[ ChangelogEntry(version="0.0.0"), ], @@ -20700,6 +20717,7 @@ class ATTRIBUTE_NAMES(metaclass=_AttributeNamesMeta): is_in_otel=True, visibility=Visibility.PUBLIC, example="foo=bar&bar=baz", + aliases=["http.query"], changelog=[ ChangelogEntry(version="0.0.0"), ], From b25bbcc9e1a4796ed8a659b4a2579f270e093622 Mon Sep 17 00:00:00 2001 From: Lukas Stracke Date: Mon, 27 Jul 2026 13:10:03 +0200 Subject: [PATCH 2/2] add reason --- javascript/sentry-conventions/src/attributes.ts | 6 ++++-- model/attributes/http/http__fragment.json | 3 ++- model/attributes/http/http__query.json | 3 ++- python/src/sentry_conventions/attributes.py | 12 ++++++++---- 4 files changed, 16 insertions(+), 8 deletions(-) diff --git a/javascript/sentry-conventions/src/attributes.ts b/javascript/sentry-conventions/src/attributes.ts index 4ee17e65..c17b6b81 100644 --- a/javascript/sentry-conventions/src/attributes.ts +++ b/javascript/sentry-conventions/src/attributes.ts @@ -8725,7 +8725,7 @@ export type HTTP_FLAVOR_TYPE = string; * * Aliases: {@link URL_FRAGMENT} `url.fragment` * - * @deprecated Use {@link URL_FRAGMENT} (url.fragment) instead + * @deprecated Use {@link URL_FRAGMENT} (url.fragment) instead - `url.fragment` is supported by OTel and conceptually more fitting. * @example "#details" */ export const HTTP_FRAGMENT = 'http.fragment'; @@ -8797,7 +8797,7 @@ export type HTTP_METHOD_TYPE = string; * * Aliases: {@link URL_QUERY} `url.query` * - * @deprecated Use {@link URL_QUERY} (url.query) instead + * @deprecated Use {@link URL_QUERY} (url.query) instead - `url.query` is supported by OTel and conceptually more fitting. * @example "?foo=bar&bar=baz" */ export const HTTP_QUERY = 'http.query'; @@ -24332,6 +24332,7 @@ export const ATTRIBUTE_METADATA: Record = { example: '#details', deprecation: { replacement: 'url.fragment', + reason: '`url.fragment` is supported by OTel and conceptually more fitting.', status: 'backfill', }, aliases: ['url.fragment'], @@ -24383,6 +24384,7 @@ export const ATTRIBUTE_METADATA: Record = { example: '?foo=bar&bar=baz', deprecation: { replacement: 'url.query', + reason: '`url.query` is supported by OTel and conceptually more fitting.', status: 'backfill', }, aliases: ['url.query'], diff --git a/model/attributes/http/http__fragment.json b/model/attributes/http/http__fragment.json index 5668a6d8..67cb6971 100644 --- a/model/attributes/http/http__fragment.json +++ b/model/attributes/http/http__fragment.json @@ -7,7 +7,8 @@ }, "deprecation": { "_status": "backfill", - "replacement": "url.fragment" + "replacement": "url.fragment", + "reason": "`url.fragment` is supported by OTel and conceptually more fitting." }, "alias": ["url.fragment"], "is_in_otel": false, diff --git a/model/attributes/http/http__query.json b/model/attributes/http/http__query.json index 96442512..9e16a1ec 100644 --- a/model/attributes/http/http__query.json +++ b/model/attributes/http/http__query.json @@ -8,7 +8,8 @@ }, "deprecation": { "_status": "backfill", - "replacement": "url.query" + "replacement": "url.query", + "reason": "`url.query` is supported by OTel and conceptually more fitting." }, "alias": ["url.query"], "is_in_otel": false, diff --git a/python/src/sentry_conventions/attributes.py b/python/src/sentry_conventions/attributes.py index e54bd469..253e2696 100644 --- a/python/src/sentry_conventions/attributes.py +++ b/python/src/sentry_conventions/attributes.py @@ -5263,7 +5263,7 @@ class ATTRIBUTE_NAMES(metaclass=_AttributeNamesMeta): Defined in OTEL: No Visibility: public Aliases: url.fragment - DEPRECATED: Use url.fragment instead + DEPRECATED: Use url.fragment instead - `url.fragment` is supported by OTel and conceptually more fitting. Example: "#details" """ @@ -5302,7 +5302,7 @@ class ATTRIBUTE_NAMES(metaclass=_AttributeNamesMeta): Defined in OTEL: No Visibility: public Aliases: url.query - DEPRECATED: Use url.query instead + DEPRECATED: Use url.query instead - `url.query` is supported by OTel and conceptually more fitting. Example: "?foo=bar&bar=baz" """ @@ -15985,7 +15985,9 @@ class ATTRIBUTE_NAMES(metaclass=_AttributeNamesMeta): visibility=Visibility.PUBLIC, example="#details", deprecation=DeprecationInfo( - replacement="url.fragment", status=DeprecationStatus.BACKFILL + replacement="url.fragment", + reason="`url.fragment` is supported by OTel and conceptually more fitting.", + status=DeprecationStatus.BACKFILL, ), aliases=["url.fragment"], changelog=[ @@ -16042,7 +16044,9 @@ class ATTRIBUTE_NAMES(metaclass=_AttributeNamesMeta): visibility=Visibility.PUBLIC, example="?foo=bar&bar=baz", deprecation=DeprecationInfo( - replacement="url.query", status=DeprecationStatus.BACKFILL + replacement="url.query", + reason="`url.query` is supported by OTel and conceptually more fitting.", + status=DeprecationStatus.BACKFILL, ), aliases=["url.query"], changelog=[