Semantic conventions for AWS SDK client spans

Status: Development

Context propagation

See compatibility.

AWS SDK spans

Status: Development

This span describes an AWS SDK client call.

Span name MUST be of the format Service.Operation as per the AWS HTTP API, e.g., DynamoDB.GetItem, S3.ListBuckets. This is equivalent to concatenating rpc.service and rpc.method with . and consistent with the naming guidelines for RPC client spans.

AWS SDK span attributes are based on the request or response parameters in AWS SDK API calls. The conventions have been collected over time based on feedback from AWS users of tracing and will continue to increase as new interesting conventions are found.

Span kind SHOULD be CLIENT.

Span status SHOULD follow the Recording Errors document.

Attributes:

KeyStabilityRequirement LevelValue TypeDescriptionExample Values
rpc.systemDevelopmentRequiredstringThe value aws-api.aws-api
aws.extended_request_idDevelopmentConditionally Required If available.stringThe AWS extended request ID as returned in the response header x-amz-id-2.wzHcyEWfmOGDIE5QOhTAqFDoDWP3y8IUvpNINCwL9N4TEHbUw0/gZJ+VZTmCNCWR7fezEN3eCiQ=
aws.request_idDevelopmentRecommendedstringThe AWS request ID as returned in the response headers x-amzn-requestid, x-amzn-request-id or x-amz-request-id.79b9da39-b7ae-508a-a6bc-864b2829c622; C9ER4AJX75574TDJ
cloud.regionDevelopmentRecommendedstringThe AWS Region where the requested service is being accessed. [1]us-east-1; us-west-2
rpc.methodDevelopmentRecommendedstringThe name of the operation corresponding to the request, as returned by the AWS SDKGetItem; PutItem
rpc.serviceDevelopmentRecommendedstringThe name of the service to which a request is made, as returned by the AWS SDK.DynamoDB; S3

[1] cloud.region: Specifies the AWS Region that the SDK client targets for a given AWS service call. The attribute’s value should adhere to the AWS Region codes outlined in the AWS documentation.


rpc.system has the following list of well-known values. If one of them applies, then the respective value MUST be used; otherwise, a custom value MAY be used.

ValueDescriptionStability
apache_dubboApache DubboDevelopment
connect_rpcConnect RPCDevelopment
dotnet_wcf.NET WCFDevelopment
grpcgRPCDevelopment
java_rmiJava RMIDevelopment
jsonrpcJSON-RPCDevelopment
onc_rpcONC RPC (Sun RPC)Development

AWS service specific attributes

The following Semantic Conventions extend the general AWS SDK attributes for specific AWS services:

  • AWS DynamoDB: Semantic Conventions for AWS DynamoDB.
  • AWS S3: Semantic Conventions for AWS S3.
  • AWS Bedrock: Semantic Conventions for AWS Bedrock.
  • AWS SNS: Semantic Conventions for AWS SNS.
  • AWS SQS: Semantic Conventions for AWS SQS.