diff --git a/javascript/sentry-conventions/src/attributes.ts b/javascript/sentry-conventions/src/attributes.ts index 644461a67..6696e517c 100644 --- a/javascript/sentry-conventions/src/attributes.ts +++ b/javascript/sentry-conventions/src/attributes.ts @@ -15555,6 +15555,7 @@ export type RPC_GRPC_STATUS_CODE_TYPE = number; * Aliases: {@link AWS_OPERATION_NAME} `aws.operation_name` * * @example "com.example.ExampleService/exampleMethod" + * @example "GetObject" */ export const RPC_METHOD = 'rpc.method'; @@ -15599,6 +15600,8 @@ export type RPC_RESPONSE_STATUS_CODE_TYPE = string; * Visibility: public * * @example "myService.BestService" + * @example "S3" + * @example "APIGateway" */ export const RPC_SERVICE = 'rpc.service'; @@ -33808,11 +33811,14 @@ export const ATTRIBUTE_METADATA: Record = { isInOtel: true, visibility: 'public', example: 'com.example.ExampleService/exampleMethod', + examples: ['com.example.ExampleService/exampleMethod', 'GetObject'], aliases: ['aws.operation_name'], changelog: [ + { version: 'next', description: 'Added AWS SDK example and additional context' }, { version: '0.19.0', prs: [536], description: 'Added aws.operation_name as an alias' }, { version: '0.7.0', prs: [351], description: 'Added rpc.method attribute' }, ], + additionalContext: ['For AWS SDK calls, this is the operation name only, as the SDK reports it, e.g. `GetObject`.'], }, 'rpc.response.status_code': { brief: 'Status code of the RPC returned by the RPC server or generated by the client.', @@ -33840,7 +33846,15 @@ export const ATTRIBUTE_METADATA: Record = { isInOtel: true, visibility: 'public', example: 'myService.BestService', - changelog: [{ version: '0.1.0', prs: [127] }, { version: '0.0.0' }], + examples: ['myService.BestService', 'S3', 'APIGateway'], + changelog: [ + { version: 'next', description: 'Added AWS SDK examples and additional context' }, + { version: '0.1.0', prs: [127] }, + { version: '0.0.0' }, + ], + additionalContext: [ + 'For AWS SDK calls, this is the AWS service ID with all whitespace removed (`S3`, `APIGateway` for `API Gateway`).', + ], }, 'rpc.system': { brief: 'A string identifying the remoting system.', diff --git a/model/attributes/rpc/rpc__method.json b/model/attributes/rpc/rpc__method.json index 788843c98..5b867fec9 100644 --- a/model/attributes/rpc/rpc__method.json +++ b/model/attributes/rpc/rpc__method.json @@ -1,15 +1,22 @@ { "key": "rpc.method", "brief": "The fully-qualified logical name of the method from the RPC interface perspective.", + "additional_context": [ + "For AWS SDK calls, this is the operation name only, as the SDK reports it, e.g. `GetObject`." + ], "type": "string", "apply_scrubbing": { "key": "manual" }, "is_in_otel": true, - "example": "com.example.ExampleService/exampleMethod", + "examples": ["com.example.ExampleService/exampleMethod", "GetObject"], "visibility": "public", "alias": ["aws.operation_name"], "changelog": [ + { + "version": "next", + "description": "Added AWS SDK example and additional context" + }, { "version": "0.19.0", "prs": [536], diff --git a/model/attributes/rpc/rpc__service.json b/model/attributes/rpc/rpc__service.json index 5fa34caf5..d01456b3b 100644 --- a/model/attributes/rpc/rpc__service.json +++ b/model/attributes/rpc/rpc__service.json @@ -1,14 +1,21 @@ { "key": "rpc.service", "brief": "The full (logical) name of the service being called, including its package name, if applicable.", + "additional_context": [ + "For AWS SDK calls, this is the AWS service ID with all whitespace removed (`S3`, `APIGateway` for `API Gateway`)." + ], "type": "string", "apply_scrubbing": { "key": "manual" }, "is_in_otel": true, - "example": "myService.BestService", + "examples": ["myService.BestService", "S3", "APIGateway"], "visibility": "public", "changelog": [ + { + "version": "next", + "description": "Added AWS SDK examples and additional context" + }, { "version": "0.1.0", "prs": [127] diff --git a/model/description/object.json b/model/description/object.json new file mode 100644 index 000000000..a1b550dc3 --- /dev/null +++ b/model/description/object.json @@ -0,0 +1,26 @@ +{ + "brief": "Object storage", + "operations": [ + { + "name": "Object", + "brief": "An operation on an object storage system such as Cloudflare R2, Amazon S3, and compatible services.", + "ops": [ + "object.get", + "object.head", + "object.put", + "object.copy", + "object.delete", + "object.list", + "object.upload_part", + "object.multipart_upload.abort", + "object.multipart_upload.create", + "object.multipart_upload.complete" + ], + "templates": [ + "{{rpc.service}}.{{rpc.method}} {{aws.s3.bucket}}", + "R2.{{cloudflare.r2.operation}} {{cloudflare.r2.bucket}}" + ], + "examples": ["S3.GetObject invoices", "S3.DeleteObjects invoices", "R2.GetObject MY_BUCKET"] + } + ] +} diff --git a/model/name/object.json b/model/name/object.json new file mode 100644 index 000000000..34a345185 --- /dev/null +++ b/model/name/object.json @@ -0,0 +1,25 @@ +{ + "brief": "Object storage", + "operations": [ + { + "name": "Object", + "brief": "An operation on an object storage system such as Amazon S3, Cloudflare R2, and compatible services.", + "is_in_otel": true, + "otel_notes": "OpenTelemetry has no Object Storage conventions. It names S3 calls like any other AWS SDK span, `{rpc.service}.{rpc.method}`, which the first template matches.", + "ops": [ + "object.get", + "object.head", + "object.put", + "object.copy", + "object.delete", + "object.list", + "object.upload_part", + "object.multipart_upload.abort", + "object.multipart_upload.create", + "object.multipart_upload.complete" + ], + "templates": ["{{rpc.service}}.{{rpc.method}}", "R2.{{cloudflare.r2.operation}}", "Object storage operation"], + "examples": ["S3.GetObject", "R2.GetObject", "Object storage operation"] + } + ] +} diff --git a/python/src/sentry_conventions/attributes.py b/python/src/sentry_conventions/attributes.py index 6b1f9e863..e65d324d8 100644 --- a/python/src/sentry_conventions/attributes.py +++ b/python/src/sentry_conventions/attributes.py @@ -9251,6 +9251,7 @@ class ATTRIBUTE_NAMES(metaclass=_AttributeNamesMeta): Visibility: public Aliases: aws.operation_name Example: "com.example.ExampleService/exampleMethod" + Example: "GetObject" """ # Path: model/attributes/rpc/rpc__response__status_code.json @@ -9276,6 +9277,8 @@ class ATTRIBUTE_NAMES(metaclass=_AttributeNamesMeta): Defined in OTEL: Yes Visibility: public Example: "myService.BestService" + Example: "S3" + Example: "APIGateway" """ # Path: model/attributes/rpc/rpc__system.json @@ -25461,8 +25464,13 @@ class ATTRIBUTE_NAMES(metaclass=_AttributeNamesMeta): is_in_otel=True, visibility=Visibility.PUBLIC, example="com.example.ExampleService/exampleMethod", + examples=["com.example.ExampleService/exampleMethod", "GetObject"], aliases=["aws.operation_name"], changelog=[ + ChangelogEntry( + version="next", + description="Added AWS SDK example and additional context", + ), ChangelogEntry( version="0.19.0", prs=[536], @@ -25472,6 +25480,9 @@ class ATTRIBUTE_NAMES(metaclass=_AttributeNamesMeta): version="0.7.0", prs=[351], description="Added rpc.method attribute" ), ], + additional_context=[ + "For AWS SDK calls, this is the operation name only, as the SDK reports it, e.g. `GetObject`." + ], ), "rpc.response.status_code": AttributeMetadata( brief="Status code of the RPC returned by the RPC server or generated by the client.", @@ -25506,10 +25517,18 @@ class ATTRIBUTE_NAMES(metaclass=_AttributeNamesMeta): is_in_otel=True, visibility=Visibility.PUBLIC, example="myService.BestService", + examples=["myService.BestService", "S3", "APIGateway"], changelog=[ + ChangelogEntry( + version="next", + description="Added AWS SDK examples and additional context", + ), ChangelogEntry(version="0.1.0", prs=[127]), ChangelogEntry(version="0.0.0"), ], + additional_context=[ + "For AWS SDK calls, this is the AWS service ID with all whitespace removed (`S3`, `APIGateway` for `API Gateway`)." + ], ), "rpc.system": AttributeMetadata( brief="A string identifying the remoting system.",