A utility company collects smart meter usage every 5 minutes. Data arrives via Amazon API Gateway, goes to an AWS Lambda function, and is stored in an Amazon DynamoDB table. During a pilot, Lambda ran 3–5 seconds, but as meters scale, Lambda durations increased to 1–2 minutes, and more metric types increased duration further. There are many ProvisionedThroughputExceededException errors on DynamoDB PUTs and many TooManyRequestsException errors from Lambda. Which combination of changes will resolve the problems? (Choose two.)
Choose an answer
Tap an option to check your answer.
Correct answer: Increase the write capacity units on the DynamoDB table., Stream the data into an Amazon Kinesis data stream from API Gateway and process the data in batches..
Why this is the answer
Increasing the write capacity units (WCUs) on the DynamoDB table directly addresses the ProvisionedThroughputExceededException errors. These errors occur when the write requests exceed the table's provisioned capacity, causing throttling. By increasing WCUs, the table can handle a higher volume of writes, resolving the bottleneck. Streaming data into an Amazon Kinesis Data Stream from API Gateway and processing it in batches addresses both the Lambda TooManyRequestsException and the increased Lambda duration. Kinesis acts as a buffer, decoupling the ingestion rate from the processing rate. This allows Lambda functions to process data in larger, more efficient batches, reducing the number of invocations and the overhead per record, thereby lowering the TooManyRequestsException errors and improving overall processing efficiency. Increasing Lambda memory might reduce execution time for a single invocation but doesn't solve the underlying issue of too many invocations or DynamoDB throttling. Increasing payload size would exacerbate the processing duration and DynamoDB write issues. Using an SQS FIFO queue for individual messages would still result in many Lambda invocations and potentially long durations per message, similar to the current setup, and wouldn't inherently solve the DynamoDB throughput issue.
Pass your exam — without the endless answer hunt
Get every verified question and explanation for this exam in one place, and save hours of prep. 1,000+ certifications · 20+ languages · free to start.
Pass your exam faster → No card needed