Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
57 changes: 56 additions & 1 deletion javascript/sentry-conventions/src/attributes.ts
Original file line number Diff line number Diff line change
Expand Up @@ -8477,6 +8477,30 @@ export const LCP_URL = 'lcp.url';
*/
export type LCP_URL_TYPE = string;

// Path: model/attributes/litestar/litestar__middleware_name.json

/**
* The name of the Litestar middleware. `litestar.middleware_name`
*
* Attribute Value Type: `string` {@link LITESTAR_MIDDLEWARE_NAME_TYPE}
*
* Apply Scrubbing: manual
*
* Attribute defined in OTEL: No
* Visibility: public
*
* Aliases: {@link MIDDLEWARE_NAME} `middleware.name`
*
* @deprecated Use {@link MIDDLEWARE_NAME} (middleware.name) instead - This attribute is being deprecated in favor of middleware.name, which is the framework-agnostic replacement.
* @example "AuthenticationMiddleware"
*/
export const LITESTAR_MIDDLEWARE_NAME = 'litestar.middleware_name';

/**
* Type for {@link LITESTAR_MIDDLEWARE_NAME} litestar.middleware_name
*/
export type LITESTAR_MIDDLEWARE_NAME_TYPE = string;

// Path: model/attributes/logger/logger__name.json

/**
Expand Down Expand Up @@ -9649,6 +9673,8 @@ export type METHOD_TYPE = string;
* Attribute defined in OTEL: No
* Visibility: public
*
* Aliases: {@link LITESTAR_MIDDLEWARE_NAME} `litestar.middleware_name`
*
* @example "AuthenticationMiddleware"
*/
export const MIDDLEWARE_NAME = 'middleware.name';
Expand Down Expand Up @@ -15386,6 +15412,7 @@ export const ATTRIBUTE_TYPE: Record<string, AttributeType> = {
'lcp.renderTime': 'integer',
'lcp.size': 'integer',
'lcp.url': 'string',
'litestar.middleware_name': 'string',
'logger.name': 'string',
'mcp.cancelled.reason': 'string',
'mcp.cancelled.request_id': 'string',
Expand Down Expand Up @@ -16068,6 +16095,7 @@ export type AttributeName =
| typeof LCP_RENDERTIME
| typeof LCP_SIZE
| typeof LCP_URL
| typeof LITESTAR_MIDDLEWARE_NAME
| typeof LOGGER_NAME
| typeof MCP_CANCELLED_REASON
| typeof MCP_CANCELLED_REQUEST_ID
Expand Down Expand Up @@ -21634,6 +21662,28 @@ export const ATTRIBUTE_METADATA: Record<AttributeName, AttributeMetadata> = {
aliases: ['browser.web_vital.lcp.url'],
changelog: [{ version: '0.5.0', prs: [233] }, { version: '0.1.0', prs: [127] }, { version: '0.0.0' }],
},
'litestar.middleware_name': {
brief: 'The name of the Litestar middleware.',
type: 'string',
applyScrubbing: {
key: 'manual',
},
isInOtel: false,
visibility: 'public',
example: 'AuthenticationMiddleware',
deprecation: {
replacement: 'middleware.name',
reason:
'This attribute is being deprecated in favor of middleware.name, which is the framework-agnostic replacement.',
},
aliases: ['middleware.name'],
changelog: [
{
version: 'next',
description: 'Added litestar.middleware_name attribute, deprecated in favor of middleware.name',
},
],
},
'logger.name': {
brief: 'The name of the logger that generated this event.',
type: 'string',
Expand Down Expand Up @@ -22347,7 +22397,11 @@ export const ATTRIBUTE_METADATA: Record<AttributeName, AttributeMetadata> = {
isInOtel: false,
visibility: 'public',
example: 'AuthenticationMiddleware',
changelog: [{ version: '0.6.0', prs: [336], description: 'Added middleware.name attribute' }],
aliases: ['litestar.middleware_name'],
changelog: [
{ version: 'next', description: 'Added litestar.middleware_name as an alias' },
{ version: '0.6.0', prs: [336], description: 'Added middleware.name attribute' },
],
},
'navigation.type': {
brief: 'The type of navigation done by a client-side router.',
Expand Down Expand Up @@ -25778,6 +25832,7 @@ export type Attributes = {
[LCP_RENDERTIME]?: LCP_RENDERTIME_TYPE;
[LCP_SIZE]?: LCP_SIZE_TYPE;
[LCP_URL]?: LCP_URL_TYPE;
[LITESTAR_MIDDLEWARE_NAME]?: LITESTAR_MIDDLEWARE_NAME_TYPE;
[LOGGER_NAME]?: LOGGER_NAME_TYPE;
[MCP_CANCELLED_REASON]?: MCP_CANCELLED_REASON_TYPE;
[MCP_CANCELLED_REQUEST_ID]?: MCP_CANCELLED_REQUEST_ID_TYPE;
Expand Down
23 changes: 23 additions & 0 deletions model/attributes/litestar/litestar__middleware_name.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
{
"key": "litestar.middleware_name",
"brief": "The name of the Litestar middleware.",
"type": "string",
"apply_scrubbing": {
"key": "manual"
},
"is_in_otel": false,
"example": "AuthenticationMiddleware",
"alias": ["middleware.name"],
"deprecation": {
"_status": "backfill",
"replacement": "middleware.name",
"reason": "This attribute is being deprecated in favor of middleware.name, which is the framework-agnostic replacement."
},
"visibility": "public",
"changelog": [
{
"version": "next",
"description": "Added litestar.middleware_name attribute, deprecated in favor of middleware.name"
}
]
}
5 changes: 5 additions & 0 deletions model/attributes/middleware/middleware__name.json
Original file line number Diff line number Diff line change
Expand Up @@ -7,8 +7,13 @@
},
"is_in_otel": false,
"example": "AuthenticationMiddleware",
"alias": ["litestar.middleware_name"],
"visibility": "public",
"changelog": [
{
"version": "next",
"description": "Added litestar.middleware_name as an alias"
},
{
"version": "0.6.0",
"prs": [336],
Expand Down
42 changes: 42 additions & 0 deletions python/src/sentry_conventions/attributes.py
Original file line number Diff line number Diff line change
Expand Up @@ -220,6 +220,7 @@ class _AttributeNamesMeta(type):
"LCP_SIZE",
"LCP_URL",
"LCP",
"LITESTAR_MIDDLEWARE_NAME",
"MCP_PROMPT_NAME",
"MCP_REQUEST_ID",
"MCP_RESOURCE_PROTOCOL",
Expand Down Expand Up @@ -5067,6 +5068,21 @@ class ATTRIBUTE_NAMES(metaclass=_AttributeNamesMeta):
Example: 2500
"""

# Path: model/attributes/litestar/litestar__middleware_name.json
LITESTAR_MIDDLEWARE_NAME: Literal["litestar.middleware_name"] = (
"litestar.middleware_name"
)
"""The name of the Litestar middleware.

Type: str
Apply Scrubbing: manual
Defined in OTEL: No
Visibility: public
Aliases: middleware.name
DEPRECATED: Use middleware.name instead - This attribute is being deprecated in favor of middleware.name, which is the framework-agnostic replacement.
Example: "AuthenticationMiddleware"
"""

# Path: model/attributes/logger/logger__name.json
LOGGER_NAME: Literal["logger.name"] = "logger.name"
"""The name of the logger that generated this event.
Expand Down Expand Up @@ -5732,6 +5748,7 @@ class ATTRIBUTE_NAMES(metaclass=_AttributeNamesMeta):
Apply Scrubbing: manual
Defined in OTEL: No
Visibility: public
Aliases: litestar.middleware_name
Example: "AuthenticationMiddleware"
"""

Expand Down Expand Up @@ -14327,6 +14344,26 @@ class ATTRIBUTE_NAMES(metaclass=_AttributeNamesMeta):
),
],
),
"litestar.middleware_name": AttributeMetadata(
brief="The name of the Litestar middleware.",
type=AttributeType.STRING,
apply_scrubbing=ApplyScrubbingInfo(key=ApplyScrubbing.MANUAL),
is_in_otel=False,
visibility=Visibility.PUBLIC,
example="AuthenticationMiddleware",
deprecation=DeprecationInfo(
replacement="middleware.name",
reason="This attribute is being deprecated in favor of middleware.name, which is the framework-agnostic replacement.",
status=DeprecationStatus.BACKFILL,
),
aliases=["middleware.name"],
changelog=[
ChangelogEntry(
version="next",
description="Added litestar.middleware_name attribute, deprecated in favor of middleware.name",
),
],
),
"logger.name": AttributeMetadata(
brief="The name of the logger that generated this event.",
type=AttributeType.STRING,
Expand Down Expand Up @@ -15094,7 +15131,11 @@ class ATTRIBUTE_NAMES(metaclass=_AttributeNamesMeta):
is_in_otel=False,
visibility=Visibility.PUBLIC,
example="AuthenticationMiddleware",
aliases=["litestar.middleware_name"],
changelog=[
ChangelogEntry(
version="next", description="Added litestar.middleware_name as an alias"
),
ChangelogEntry(
version="0.6.0",
prs=[336],
Expand Down Expand Up @@ -18626,6 +18667,7 @@ class ATTRIBUTE_NAMES(metaclass=_AttributeNamesMeta):
"lcp.size": int,
"lcp.url": str,
"lcp": float,
"litestar.middleware_name": str,
"logger.name": str,
"mcp.cancelled.reason": str,
"mcp.cancelled.request_id": str,
Expand Down
Loading