DVA-C02 exam dumps

DVA-C02 practice question 5 of 399

AWS Certified Developer - Associate. Associate level, Amazon Web Services. Free question with the correct answer and a full explanation.

DVA-C02 Question 5

Single answer

You are developing a serverless application using AWS Lambda. Your function processes images uploaded to an S3 bucket and stores metadata in an Amazon DynamoDB table. After deployment, you notice that some images are not processed and the Lambda function logs show throttling errors when writing to DynamoDB. What is the best way to address this issue?

  1. A

    Increase the write capacity of the DynamoDB table to handle the higher throughput.

  2. B

    Enable DynamoDB Auto Scaling to dynamically adjust the table's write capacity.

  3. C

    Configure the Lambda function to retry failed writes to DynamoDB using an exponential backoff strategy.

  4. D

    Use the S3 Event Notification feature to ensure that each image triggers exactly one Lambda invocation.

Show answer and explanation

Correct answer: B

Explanation

The issue here is caused by insufficient write capacity in the DynamoDB table, leading to throttling errors. Enabling DynamoDB Auto Scaling allows the table to automatically scale its capacity to match the workload, avoiding these errors while maintaining cost efficiency. Other options either address symptoms of the issue or do not resolve the core problem of write capacity limits.

  • A. Incorrect.

    Increasing the write capacity manually can work, but it's not ideal as it doesn't adjust dynamically with fluctuating workloads. This approach may lead to over-provisioning or under-provisioning of capacity.

  • B. Correct.

    Enabling DynamoDB Auto Scaling is the best option as it allows the table to automatically adjust its read and write capacity in response to changing traffic patterns, preventing throttling errors.

  • C. Incorrect.

    Configuring retries with exponential backoff can reduce the impact of throttling errors, but it doesn't address the root cause, which is insufficient write capacity in DynamoDB.

  • D. Incorrect.

    Using the S3 Event Notification feature ensures that each image triggers a Lambda invocation, but it does not solve the DynamoDB throttling issue.

Timed practice exam

Take a DVA-C02 practice test under exam conditions

65 questions in 130 minutes, drawn from this bank, with a score report and a per-question review when you finish.

Start timed exam