Tracing Amazon SDK calls with the X-Ray SDK for Node.js
When your application makes calls to Amazon Web Services services to store data, write to a queue, or send notifications, the X-Ray SDK for Node.js tracks the calls downstream in subsegments. Traced Amazon Web Services services, and resources that you access within those services (for example, an Amazon S3 bucket or Amazon SQS queue), appear as downstream nodes on the trace map in the X-Ray console.
Instrument Amazon SDK clients that you create via the Amazon SDK for JavaScript V2 or Amazon SDK for JavaScript V3. Each Amazon SDK version provides different methods for instrumenting Amazon SDK clients.
Note
Currently, the Amazon X-Ray SDK for Node.js returns less segment information when instrumenting Amazon SDK for JavaScript V3 clients, as compared to instrumenting V2 clients. For instance, subsegments representing calls to DynamoDB will not return the table name. If you need this segment information in your traces, consider using the Amazon SDK for JavaScript V2.