nerdexam
Amazon

DVA-C02 · Question #529

An AWS Lambda function that handles application requests uses the default Lambda logging mechanism to log the timestamp, processing time, and status of requests. A developer needs to create Amazon…

The correct answer is D. Use the CloudWatch embedded metric format (EMF) for the structure of the log statements to. The CloudWatch Embedded Metric Format (EMF) allows Lambda to emit structured log entries that CloudWatch automatically extracts into custom metrics in a specified namespace.

Submitted by certguy· Mar 5, 2026Monitoring and Troubleshooting

Question

An AWS Lambda function that handles application requests uses the default Lambda logging mechanism to log the timestamp, processing time, and status of requests. A developer needs to create Amazon CloudWatch metrics based on the logs. The developer needs to write the metrics to a custom CloudWatch metrics namespace. Which solution will meet these requirements?

Options

  • AUse Amazon CloudWatch Logs Insights to generate custom metrics from the logs by using
  • BUse Amazon CloudWatch RUM to generate custom metrics from the logs by using CloudWatch
  • CUse Amazon CloudWatch Logs Insights to generate custom metrics from the logs by using JSON
  • DUse the CloudWatch embedded metric format (EMF) for the structure of the log statements to

How the community answered

(32 responses)
  • A
    3% (1)
  • B
    9% (3)
  • C
    19% (6)
  • D
    69% (22)

Why each option

The CloudWatch Embedded Metric Format (EMF) allows Lambda to emit structured log entries that CloudWatch automatically extracts into custom metrics in a specified namespace.

AUse Amazon CloudWatch Logs Insights to generate custom metrics from the logs by using

CloudWatch Logs Insights is an interactive query tool for analyzing log data; it does not automatically publish metrics to a custom namespace on an ongoing basis.

BUse Amazon CloudWatch RUM to generate custom metrics from the logs by using CloudWatch

CloudWatch RUM (Real User Monitoring) collects client-side performance data from browsers and is unrelated to server-side Lambda log processing.

CUse Amazon CloudWatch Logs Insights to generate custom metrics from the logs by using JSON

Using CloudWatch Logs Insights with JSON-based queries allows ad-hoc analysis but still does not automatically publish ongoing metrics to a custom CloudWatch metrics namespace.

DUse the CloudWatch embedded metric format (EMF) for the structure of the log statements toCorrect

EMF enables Lambda functions to write specially structured JSON log statements that the CloudWatch Logs agent parses asynchronously to extract metric values. Because the namespace, metric name, and dimensions are embedded directly in the log format, CloudWatch automatically creates the metrics in the custom namespace without any additional configuration or manual metric publication calls.

Concept tested: CloudWatch Embedded Metric Format for custom Lambda metrics

Source: https://docs.aws.amazon.com/AmazonCloudWatch/latest/monitoring/CloudWatch_Embedded_Metric_Format_Specification.html

Community Discussion

No community discussion yet for this question.

Full DVA-C02 Practice