DVA-C02 exam dumps

DVA-C02 practice question 326 of 399

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

DVA-C02 Question 326

Single answer

You are developing a serverless application using AWS Lambda. The application processes images uploaded to an S3 bucket and stores metadata in a DynamoDB table. You notice that under high load, some Lambda functions are failing with 'ProvisionedThroughputExceededException' errors when writing to DynamoDB. What is the best way to resolve this issue?

  1. A

    Enable DynamoDB Auto Scaling for the table.

  2. B

    Use the DynamoDB BatchWriteItem API instead of individual writes.

  3. C

    Increase the provisioned throughput of the DynamoDB table manually.

  4. D

    Add retries with exponential backoff to your Lambda function's code.

Show answer and explanation

Correct answer: A

Explanation

The 'ProvisionedThroughputExceededException' occurs when the DynamoDB table exceeds its provisioned write or read capacity. Enabling DynamoDB Auto Scaling is the best solution as it allows the table to dynamically adjust its capacity based on demand, ensuring the application can handle high loads without manual intervention or suboptimal workarounds.

  • A. Correct.

    Enabling DynamoDB Auto Scaling allows the table to automatically adjust its read and write capacity based on traffic patterns, which is the best solution for handling high and variable loads.

  • B. Incorrect.

    Using the BatchWriteItem API is useful for reducing the number of API calls, but it does not address the root issue of throughput being exceeded during high load.

  • C. Incorrect.

    Manually increasing the provisioned throughput may temporarily resolve the issue, but it is not a scalable or cost-effective solution under fluctuating workloads.

  • D. Incorrect.

    Adding retries with exponential backoff can help mitigate transient errors, but it does not address the primary problem of insufficient throughput capacity.

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