- A
Enable detailed CloudWatch metrics for ECS and Fargate, including CPU and memory.
Why wrong: CPU and memory metrics do not provide API-level latency breakdowns.
- B
Enable CloudWatch Logs Insights to query API logs for slow requests.
Why wrong: CloudWatch Logs Insights can search logs but does not provide distributed tracing or latency breakdowns per endpoint across microservices.
- C
Use AWS X-Ray to instrument the application and collect trace data.
AWS X-Ray provides end-to-end tracing with segment details, allowing you to see latency per API endpoint and downstream dependencies.
- D
Deploy the AWS Distro for OpenTelemetry collector on each task to send metrics to CloudWatch.
Why wrong: OpenTelemetry can be used for traces and metrics, but the question asks for latency breakdowns; X-Ray is more directly suited and simpler.
- E
Set up VPC Flow Logs to analyze network latency between services.
Why wrong: VPC Flow Logs capture network metadata, not application request latency.
Quick Answer
The answer is AWS X-Ray, as it provides the most granular visibility into API latency breakdown per endpoint in microservices. Unlike CloudWatch Logs or Container Insights, which offer aggregated metrics or log-based queries, X-Ray captures end-to-end trace data as requests travel through distributed services on Amazon ECS with Fargate, revealing detailed latency contributions from downstream calls, database queries, and external HTTP requests. On the AWS Certified DevOps Engineer Professional DOP-C02 exam, this question tests your ability to distinguish between monitoring tools that show high-level health versus those that pinpoint root causes of slow responses—a common trap is choosing CloudWatch Logs Insights, which requires manual correlation and lacks automatic trace segmentation. Remember the mnemonic: X-Ray eXposes the exact path—each hop in your microservices gets a detailed latency stamp, making it the only tool that breaks down API performance endpoint by endpoint.
DOP-C02 Monitoring and Logging Practice Question
This DOP-C02 practice question tests your understanding of monitoring and logging. The scenario asks you to isolate a root cause — eliminate options that address a different problem before choosing. After answering, compare your reasoning against the explanation and wrong-answer breakdown below. Once you have made your selection, read the full explanation to reinforce the concept and understand why each distractor is designed to mislead on exam day.
A company is running a microservices application on Amazon ECS with AWS Fargate. The operations team needs to monitor application performance and troubleshoot slow API responses. They currently use Amazon CloudWatch Logs for container logs and have enabled Container Insights. However, they are unable to see detailed latency breakdowns per API endpoint. Which solution would provide the most granular visibility into API performance?
Answer choices
Why each option matters
Answer the question above first, then reveal the full breakdown to understand why each option is right or wrong.
Correct answer & explanation
Use AWS X-Ray to instrument the application and collect trace data.
AWS X-Ray provides end-to-end tracing of requests as they travel through microservices, capturing detailed latency breakdowns per API endpoint, including downstream calls, database queries, and external HTTP requests. This gives the operations team the granular visibility needed to pinpoint exactly where slow responses occur, unlike aggregated metrics or log-based queries.
Key principle: Answer the scenario, not the keyword: identify the specific constraint before choosing the most familiar-sounding option.
Answer analysis
Option-by-option breakdown
For each option: why learners choose it and why it is or isn't the right answer here.
- ✗
Enable detailed CloudWatch metrics for ECS and Fargate, including CPU and memory.
Why it's wrong here
CPU and memory metrics do not provide API-level latency breakdowns.
- ✗
Enable CloudWatch Logs Insights to query API logs for slow requests.
Why it's wrong here
CloudWatch Logs Insights can search logs but does not provide distributed tracing or latency breakdowns per endpoint across microservices.
- ✓
Use AWS X-Ray to instrument the application and collect trace data.
Why this is correct
AWS X-Ray provides end-to-end tracing with segment details, allowing you to see latency per API endpoint and downstream dependencies.
Related concept
Read the scenario before looking for a memorised answer.
- ✗
Deploy the AWS Distro for OpenTelemetry collector on each task to send metrics to CloudWatch.
Why it's wrong here
OpenTelemetry can be used for traces and metrics, but the question asks for latency breakdowns; X-Ray is more directly suited and simpler.
- ✗
Set up VPC Flow Logs to analyze network latency between services.
Why it's wrong here
VPC Flow Logs capture network metadata, not application request latency.
Common exam traps
Common exam trap: answer the scenario, not the keyword
The trap here is that candidates confuse infrastructure-level metrics (CPU, memory, network) or log-based querying with the distributed tracing capability needed to break down latency per API endpoint, overlooking that only X-Ray provides end-to-end trace segments with sub-millisecond timing per service call.
Detailed technical explanation
How to think about this question
X-Ray uses trace IDs and segment documents to reconstruct the full path of a request, recording timing data (start time, end time, duration) for each subsegment (e.g., DynamoDB query, HTTP call). The X-Ray SDK automatically instruments supported frameworks (e.g., Express, Spring) and propagates trace headers via the `X-Amzn-Trace-Id` HTTP header, enabling distributed tracing across service boundaries. In a real-world scenario, a single API call might fan out to three microservices and two databases; X-Ray's service map visually highlights which hop contributes the most latency, something no other option achieves.
KKey Concepts to Remember
- Read the scenario before looking for a memorised answer.
- Find the constraint that changes the correct option.
- Eliminate answers that are true in general but not in this case.
TExam Day Tips
- Watch for words such as best, first, most likely and least administrative effort.
- Review why wrong options are wrong, not only why the correct option is correct.
Key takeaway
Answer the scenario, not the keyword: identify the specific constraint before choosing the most familiar-sounding option.
Real-world example
How this comes up in practice
A healthcare organisation deploys an application with a public-facing web tier and a private database tier. The database subnet has no public IP and only accepts connections from the web tier's security group. Questions like this test whether you can design cloud network isolation using VNets/VPCs, subnets, and security group rules.
What to study next
Got this wrong? Here's your next step.
Identify which exam domain this question belongs to, review the core concept, then practise similar questions from the same domain.
- →
Monitoring and Logging — study guide chapter
Learn the concepts, then practise the questions
- →
Monitoring and Logging practice questions
Targeted practice on this topic area only
- →
All DOP-C02 questions
1,740 questions across all exam domains
- →
AWS Certified DevOps Engineer Professional DOP-C02 study guide
Full concept coverage aligned to exam objectives
- →
DOP-C02 practice test guide
How to use practice tests most effectively before exam day
Related practice questions
Related DOP-C02 practice-question pages
Use these pages to review the topic behind this question. This is how one missed question becomes focused revision.
Configuration Management and IaC practice questions
Practise DOP-C02 questions linked to Configuration Management and IaC.
Resilient Cloud Solutions practice questions
Practise DOP-C02 questions linked to Resilient Cloud Solutions.
Monitoring and Logging practice questions
Practise DOP-C02 questions linked to Monitoring and Logging.
Incident and Event Response practice questions
Practise DOP-C02 questions linked to Incident and Event Response.
Security and Compliance practice questions
Practise DOP-C02 questions linked to Security and Compliance.
SDLC Automation practice questions
Practise DOP-C02 questions linked to SDLC Automation.
DOP-C02 fundamentals practice questions
Practise DOP-C02 questions linked to DOP-C02 fundamentals.
DOP-C02 scenario practice questions
Practise DOP-C02 questions linked to DOP-C02 scenario.
DOP-C02 troubleshooting practice questions
Practise DOP-C02 questions linked to DOP-C02 troubleshooting.
Practice this exam
Start a free DOP-C02 practice session
Short sessions build daily habit. Longer sessions build exam-day stamina. Try a timed session to simulate real conditions.
FAQ
Questions learners often ask
What does this DOP-C02 question test?
Monitoring and Logging — This question tests Monitoring and Logging — Read the scenario before looking for a memorised answer..
What is the correct answer to this question?
The correct answer is: Use AWS X-Ray to instrument the application and collect trace data. — AWS X-Ray provides end-to-end tracing of requests as they travel through microservices, capturing detailed latency breakdowns per API endpoint, including downstream calls, database queries, and external HTTP requests. This gives the operations team the granular visibility needed to pinpoint exactly where slow responses occur, unlike aggregated metrics or log-based queries.
What should I do if I get this DOP-C02 question wrong?
Identify which exam domain this question belongs to, review the core concept, then practise similar questions from the same domain.
What is the key concept behind this question?
Read the scenario before looking for a memorised answer.
About these practice questions
Courseiva creates original exam-style practice questions with explanations and wrong-answer analysis. It does not publish real exam questions, exam dumps, or protected exam content. Learn why practice questions differ from exam dumps →
Same concept, more angles
3 more ways this is tested on DOP-C02
These questions test the same concept from different angles. Work through them to make sure you can recognise it however the exam phrases it.
Variation 1. A company runs a microservices application on Amazon ECS with Fargate. The operations team notices that some services are experiencing intermittent high latency, but CPU and memory metrics appear normal. They need to identify the root cause. Which approach should they use?
hard- A.Enable detailed CloudWatch Logs and use CloudWatch Logs Insights to query logs for slow requests.
- B.Use Amazon Managed Service for Prometheus to collect custom metrics and set up dashboards.
- C.Set up CloudWatch Synthetics canaries to monitor the endpoints and measure response times.
- ✓ D.Instrument the application with the AWS X-Ray SDK and use the X-Ray console to analyze traces.
Why D: Option D is correct because AWS X-Ray provides end-to-end tracing to pinpoint latency issues in distributed applications. Option A is wrong because CloudWatch Logs Insights alone does not trace requests across services. Option B is wrong because Prometheus metrics are aggregated and may not correlate individual requests. Option C is wrong because CloudWatch Synthetics canaries test endpoints but cannot trace internal service calls.
Variation 2. A company runs a serverless application using AWS Lambda, Amazon API Gateway, and Amazon DynamoDB. The application is used by thousands of users. Recently, the operations team noticed an increase in 5xx errors from API Gateway. The team has enabled CloudWatch Logs for the Lambda functions and API Gateway. They see the errors are sporadic and not correlated with high traffic. The Lambda function's error count in CloudWatch is also increasing. The team wants to identify the specific requests that are failing and understand the error details. Which solution should the team implement?
medium- A.Use CloudWatch Logs Insights to query the Lambda logs for ERROR messages and correlate with API Gateway logs
- B.Enable VPC Flow Logs for the Lambda function's VPC to capture network traffic
- ✓ C.Enable AWS X-Ray active tracing on the Lambda functions and API Gateway to capture detailed request traces and error details
- D.Enable AWS CloudTrail to log API Gateway API calls and analyze the logs
Why C: Option B is correct because X-Ray provides end-to-end tracing and can capture errors with detailed metadata. It integrates with Lambda and API Gateway to trace requests and identify failures. Option A is wrong because CloudWatch Logs Insights would require querying all logs, which is less efficient for tracing. Option C is wrong because CloudTrail captures API calls, not application-level request details. Option D is wrong because VPC Flow Logs are for network traffic, not application errors.
Variation 3. A company runs a serverless application using AWS Lambda and Amazon API Gateway. The application processes user uploads to an S3 bucket. The operations team uses CloudWatch Logs for monitoring, but they are finding it difficult to correlate logs across multiple Lambda functions that handle different parts of the workflow. The team wants to trace requests as they flow through the application and identify bottlenecks or errors. The team has already enabled CloudWatch Logs for all Lambda functions. What should the team do to achieve end-to-end request tracing?
medium- A.Use CloudWatch Contributor Insights to analyze the log data and identify the top contributors to latency.
- B.Use AWS CloudTrail to log all API calls and correlate them with CloudWatch Logs.
- C.Create a CloudWatch ServiceLens service map to visualize the application components.
- ✓ D.Enable AWS X-Ray on the Lambda functions and API Gateway to trace requests end-to-end.
Why D: Option C is correct because AWS X-Ray provides end-to-end tracing and integrates with Lambda and API Gateway. Option A is wrong because CloudWatch Contributor Insights analyzes top contributors but does not trace requests across services. Option B is wrong because CloudWatch ServiceLens provides service maps but relies on X-Ray for tracing. Option D is wrong because CloudTrail logs API calls, not application-level tracing.
Keep practising
More DOP-C02 practice questions
- A company uses AWS CodePipeline with a multi-branch strategy. A new feature branch triggers a pipeline that runs unit te…
- A development team uses AWS CodeBuild to compile a Java application and run unit tests. The build takes 30 minutes, but…
- A company uses AWS CodePipeline with multiple stages: Source (Amazon S3), Build (AWS CodeBuild), and Deploy (AWS CodeDep…
- A company uses AWS CodeCommit for source control. Developers frequently push large binary files (e.g., compiled JARs) to…
- An organization uses AWS CodePipeline to orchestrate deployments to multiple environments (dev, test, prod). Each enviro…
- A company uses AWS Key Management Service (KMS) to encrypt data at rest in Amazon S3. The security team wants to ensure…
Last reviewed: Jun 11, 2026
This DOP-C02 practice question is part of Courseiva's free Amazon Web Services certification practice question bank. Courseiva provides original exam-style practice questions with explanations, topic-based practice, mock exams, readiness tracking, and study analytics to help learners prepare for the DOP-C02 exam.
Question Discussion
Share a tip, memory trick, or ask about the reasoning behind this question. Do not post real exam questions, leaked content, braindumps, or copyrighted exam material. Comments are moderated and may be removed without notice.
Sign in to join the discussion.