How to Trace Multi-Service Lambda Performance Without Code Changes?

Serverless Monitoring & Observability

A developer created an AWS Lambda function that performs a series of operations that involve multiple AWS services. The function's duration time is higher than normal. To determine the cause of the issue, the developer must investigate traffic between the services without changing the function code. Which solution will meet these requirements?

  1. Enable AWS X-Ray active tracing in the Lambda function. Review the logs in X-Ray. Source Reference Answer
  2. Configure AWS CloudTrail. View the trail logs that are associated with the Lambda function.
  3. Review the AWS Config logs in Amazon CloudWatch.
  4. Review the Amazon CloudWatch logs that are associated with the Lambda function.

Community Votes

A
100%

100% of anonymous learners picked answer A. Votes are pick records left by other test-takers — they are not the verified answer.

Community Insight

The scenario tests your ability to differentiate between logging and distributed tracing tools, with the common trap being the selection of CloudWatch Logs due to its familiarity despite lacking cross-service visibility.

This question evaluates your knowledge of AWS observability tools for serverless architectures, specifically focusing on distributed tracing. Industry experts and test-takers universally agree that AWS X-Ray is the optimal solution for mapping inter-service traffic and isolating latency bottlenecks without modifying source code.

Candidates frequently choose Option D (CloudWatch Logs) because it is the default monitoring tool for Lambda, but it only captures standard output streams and cannot visualize request flows or measure timing across multiple AWS services.

Community Discussion (5 comments)

65703c1 👍 2 Selected: A
A is the correct answer.
KarBiswa 👍 2 Selected: A
X ray option
monishvster 👍 2 Selected: A
Should be A
hungnv6_rikkei 👍 4 Selected: A
A. Enable AWS X-Ray active tracing in the Lambda function. Review the logs in X-Ray. X-Ray provides insights into the duration and performance of each component, helping you identify the root cause of performance issues without modifying the function code.
CrescentShared 👍 3 Selected: A
between the services

Comments & Corrections

No comments yet — spotted an error or have a note? Share it below.

Log in to comment, report an error, or add a note about this question.

Submitted for moderation before publishing. Keep it helpful and respectful.

Expert Analysis

Why the Answer Is Correct

AWS X-Ray is purpose-built for distributed tracing and automatically generates a service map that visualizes how requests traverse multiple AWS services. Enabling active tracing requires zero code changes for supported SDKs, yet it captures precise timing data, metadata, and error states for every downstream call. By analyzing these traces, developers can instantly isolate which specific service interaction is driving the elevated duration. This direct correlation between trace data and performance metrics makes it the definitive troubleshooting choice.

Why the Other Options Are Wrong

Option B (CloudTrail) focuses on API auditing and compliance recording, providing no granular runtime performance data or application-level latency breakdowns. Option C (AWS Config) tracks infrastructure state changes and configuration drift, making it entirely irrelevant to real-time execution analysis. Option D (CloudWatch Logs) captures standard application output and exceptions but lacks the architectural context needed to map dependencies or measure inter-service communication delays.

Community Comment Notes

Test-takers overwhelmingly validate Option A as the correct choice based on the explicit requirement to analyze traffic between services. Comment [1] correctly emphasizes that X-Ray delivers component-level duration insights, directly satisfying the constraint of avoiding code modifications. Comment [2] highlights the critical phrase "between the services," which serves as a definitive keyword for selecting a distributed tracing solution over isolated log aggregators. The unanimous voting pattern confirms this aligns perfectly with current AWS certification expectations.

Official Reference

Exam Strategy

When troubleshooting serverless performance, prioritize tools that offer architectural visualization and automatic instrumentation when code modification is prohibited. Always scan for keywords like "trace," "service map," or "inter-service calls" to quickly eliminate logging-only options and select the appropriate distributed tracing service.

Related Analysis

Practice All DVA-C02 Questions

Access 100 questions with complete answers and detailed explanations.

View Full DVA-C02 Practice Test →

← Back to DVA-C02 Study Guide