diff --git a/javascript/sentry-conventions/src/attributes.ts b/javascript/sentry-conventions/src/attributes.ts index 041ac192..46189e66 100644 --- a/javascript/sentry-conventions/src/attributes.ts +++ b/javascript/sentry-conventions/src/attributes.ts @@ -3766,6 +3766,8 @@ export type DB_REDIS_CONNECTION_TYPE = string; * Attribute defined in OTEL: No * Visibility: public * + * Aliases: {@link REDIS_KEY} `redis.key` + * * @example "user:2047:city" */ export const DB_REDIS_KEY = 'db.redis.key'; @@ -11019,6 +11021,30 @@ export const REACT_VERSION = 'react.version'; */ export type REACT_VERSION_TYPE = string; +// Path: model/attributes/redis/redis__key.json + +/** + * The key the Redis command is operating on. `redis.key` + * + * Attribute Value Type: `string` {@link REDIS_KEY_TYPE} + * + * Apply Scrubbing: manual + * + * Attribute defined in OTEL: No + * Visibility: public + * + * Aliases: {@link DB_REDIS_KEY} `db.redis.key` + * + * @deprecated Use {@link DB_REDIS_KEY} (db.redis.key) instead - This attribute is being deprecated in favor of db.redis.key, which is the preferred replacement. + * @example "user:2047:city" + */ +export const REDIS_KEY = 'redis.key'; + +/** + * Type for {@link REDIS_KEY} redis.key + */ +export type REDIS_KEY_TYPE = string; + // Path: model/attributes/release.json /** @@ -15502,6 +15528,7 @@ export const ATTRIBUTE_TYPE: Record = { 'process.runtime.version': 'string', 'query.': 'string', 'react.version': 'string', + 'redis.key': 'string', release: 'string', 'remix.action_form_data.': 'string', replay_id: 'string', @@ -16184,6 +16211,7 @@ export type AttributeName = | typeof PROCESS_RUNTIME_VERSION | typeof QUERY_KEY | typeof REACT_VERSION + | typeof REDIS_KEY | typeof RELEASE | typeof REMIX_ACTION_FORM_DATA_KEY | typeof REPLAY_ID @@ -18647,7 +18675,11 @@ export const ATTRIBUTE_METADATA: Record = { isInOtel: false, visibility: 'public', example: 'user:2047:city', - changelog: [{ version: '0.6.0', prs: [326], description: 'Added db.redis.key attribute' }], + aliases: ['redis.key'], + changelog: [ + { version: 'next', description: 'Added redis.key as an alias' }, + { version: '0.6.0', prs: [326], description: 'Added db.redis.key attribute' }, + ], }, 'db.redis.parameters': { brief: 'The array of command parameters given to a redis command.', @@ -23156,6 +23188,22 @@ export const ATTRIBUTE_METADATA: Record = { example: '18.2.0', changelog: [{ version: '0.7.0', prs: [368], description: 'Added react.version attribute' }], }, + 'redis.key': { + brief: 'The key the Redis command is operating on.', + type: 'string', + applyScrubbing: { + key: 'manual', + }, + isInOtel: false, + visibility: 'public', + example: 'user:2047:city', + deprecation: { + replacement: 'db.redis.key', + reason: 'This attribute is being deprecated in favor of db.redis.key, which is the preferred replacement.', + }, + aliases: ['db.redis.key'], + changelog: [{ version: 'next', description: 'Added redis.key attribute, deprecated in favor of db.redis.key' }], + }, release: { brief: 'The sentry release.', type: 'string', @@ -25894,6 +25942,7 @@ export type Attributes = { [PROCESS_RUNTIME_VERSION]?: PROCESS_RUNTIME_VERSION_TYPE; [QUERY_KEY]?: QUERY_KEY_TYPE; [REACT_VERSION]?: REACT_VERSION_TYPE; + [REDIS_KEY]?: REDIS_KEY_TYPE; [RELEASE]?: RELEASE_TYPE; [REMIX_ACTION_FORM_DATA_KEY]?: REMIX_ACTION_FORM_DATA_KEY_TYPE; [REPLAY_ID]?: REPLAY_ID_TYPE; diff --git a/model/attributes/db/db__redis__key.json b/model/attributes/db/db__redis__key.json index 68f673c3..f416a653 100644 --- a/model/attributes/db/db__redis__key.json +++ b/model/attributes/db/db__redis__key.json @@ -7,8 +7,13 @@ }, "is_in_otel": false, "example": "user:2047:city", + "alias": ["redis.key"], "visibility": "public", "changelog": [ + { + "version": "next", + "description": "Added redis.key as an alias" + }, { "version": "0.6.0", "prs": [326], diff --git a/model/attributes/redis/redis__key.json b/model/attributes/redis/redis__key.json new file mode 100644 index 00000000..dfbbc939 --- /dev/null +++ b/model/attributes/redis/redis__key.json @@ -0,0 +1,23 @@ +{ + "key": "redis.key", + "brief": "The key the Redis command is operating on.", + "type": "string", + "apply_scrubbing": { + "key": "manual" + }, + "is_in_otel": false, + "example": "user:2047:city", + "alias": ["db.redis.key"], + "deprecation": { + "_status": "backfill", + "replacement": "db.redis.key", + "reason": "This attribute is being deprecated in favor of db.redis.key, which is the preferred replacement." + }, + "visibility": "public", + "changelog": [ + { + "version": "next", + "description": "Added redis.key attribute, deprecated in favor of db.redis.key" + } + ] +} diff --git a/python/src/sentry_conventions/attributes.py b/python/src/sentry_conventions/attributes.py index 90122d51..f20e4014 100644 --- a/python/src/sentry_conventions/attributes.py +++ b/python/src/sentry_conventions/attributes.py @@ -248,6 +248,7 @@ class _AttributeNamesMeta(type): "PERFORMANCE_ACTIVATIONSTART", "PERFORMANCE_TIMEORIGIN", "QUERY_KEY", + "REDIS_KEY", "RELEASE", "REPLAY_ID", "RESOURCE_DEPLOYMENT_ENVIRONMENT", @@ -2415,6 +2416,7 @@ class ATTRIBUTE_NAMES(metaclass=_AttributeNamesMeta): Apply Scrubbing: manual Defined in OTEL: No Visibility: public + Aliases: redis.key Example: "user:2047:city" """ @@ -6476,6 +6478,19 @@ class ATTRIBUTE_NAMES(metaclass=_AttributeNamesMeta): Example: "18.2.0" """ + # Path: model/attributes/redis/redis__key.json + REDIS_KEY: Literal["redis.key"] = "redis.key" + """The key the Redis command is operating on. + + Type: str + Apply Scrubbing: manual + Defined in OTEL: No + Visibility: public + Aliases: db.redis.key + DEPRECATED: Use db.redis.key instead - This attribute is being deprecated in favor of db.redis.key, which is the preferred replacement. + Example: "user:2047:city" + """ + # Path: model/attributes/release.json RELEASE: Literal["release"] = "release" """The sentry release. @@ -11117,7 +11132,9 @@ class ATTRIBUTE_NAMES(metaclass=_AttributeNamesMeta): is_in_otel=False, visibility=Visibility.PUBLIC, example="user:2047:city", + aliases=["redis.key"], changelog=[ + ChangelogEntry(version="next", description="Added redis.key as an alias"), ChangelogEntry( version="0.6.0", prs=[326], description="Added db.redis.key attribute" ), @@ -15943,6 +15960,26 @@ class ATTRIBUTE_NAMES(metaclass=_AttributeNamesMeta): ), ], ), + "redis.key": AttributeMetadata( + brief="The key the Redis command is operating on.", + type=AttributeType.STRING, + apply_scrubbing=ApplyScrubbingInfo(key=ApplyScrubbing.MANUAL), + is_in_otel=False, + visibility=Visibility.PUBLIC, + example="user:2047:city", + deprecation=DeprecationInfo( + replacement="db.redis.key", + reason="This attribute is being deprecated in favor of db.redis.key, which is the preferred replacement.", + status=DeprecationStatus.BACKFILL, + ), + aliases=["db.redis.key"], + changelog=[ + ChangelogEntry( + version="next", + description="Added redis.key attribute, deprecated in favor of db.redis.key", + ), + ], + ), "release": AttributeMetadata( brief="The sentry release.", type=AttributeType.STRING, @@ -18742,6 +18779,7 @@ class ATTRIBUTE_NAMES(metaclass=_AttributeNamesMeta): "process.runtime.version": str, "query.": str, "react.version": str, + "redis.key": str, "release": str, "remix.action_form_data.": str, "replay_id": str,