exam questions

Exam AWS Certified Developer - Associate DVA-C02 All Questions

View all questions & answers for the AWS Certified Developer - Associate DVA-C02 exam

Exam AWS Certified Developer - Associate DVA-C02 topic 1 question 66 discussion

A company has a critical application on AWS. The application exposes an HTTP API by using Amazon API Gateway. The API is integrated with an AWS Lambda function. The application stores data in an Amazon RDS for MySQL DB instance with 2 virtual CPUs (vCPUs) and 64 GB of RAM.

Customers have reported that some of the API calls return HTTP 500 Internal Server Error responses. Amazon CloudWatch Logs shows errors for “too many connections.” The errors occur during peak usage times that are unpredictable.

The company needs to make the application resilient. The database cannot be down outside of scheduled maintenance hours.

Which solution will meet these requirements?

  • A. Decrease the number of vCPUs for the DB instance. Increase the max_connections setting.
  • B. Use Amazon RDS Proxy to create a proxy that connects to the DB instance. Update the Lambda function to connect to the proxy.
  • C. Add a CloudWatch alarm that changes the DB instance class when the number of connections increases to more than 1,000.
  • D. Add an Amazon EventBridge rule that increases the max_connections setting of the DB instance when CPU utilization is above 75%.
Show Suggested Answer Hide Answer
Suggested Answer: B 🗳️

Comments

Chosen Answer:
This is a voting comment (?). It is better to Upvote an existing comment if you don't have anything to add.
Switch to a voting comment New
MrTee
Highly Voted 1 year, 6 months ago
Selected Answer: B
The best solution to meet these requirements would be to use Amazon RDS Proxy to create a proxy that connects to the DB instance and update the Lambda function to connect to the proxy.
upvoted 11 times
...
sumanshu
Most Recent 4 months ago
Selected Answer: B
A) Eliminated - Decreasing the number of vCPUs will worsen performance. B) When your Lambda function wants to query the database, instead of opening a new connection every time (which is what causes "too many connections"), it talks to the RDS Proxy. For example, if 100 Lambda functions try to connect at the same time, instead of opening 100 database connections, the RDS Proxy might only open 10 and reuse them. C) Eliminated - It incurs unnecessary costs for increased capacity, even if the issue is caused by connection management.
upvoted 3 times
...
65703c1
5 months, 1 week ago
Selected Answer: B
B is the correct answer.
upvoted 1 times
...
SerialiDr
9 months, 3 weeks ago
Selected Answer: B
Amazon RDS Proxy is designed to handle a large number of simultaneous connections efficiently. It sits between your application and your RDS database to pool and share database connections, improving database efficiency and application scalability. This approach can reduce the number of connections to the database and handle unpredictable peak loads more effectively.
upvoted 3 times
...
hsinchang
1 year, 1 month ago
Selected Answer: B
B: RDS Proxy establishes and manages the necessary connection pools to your database so that your Lambda function creates fewer database connections¹. RDS Proxy also handles failovers and retries automatically, which improves the availability of your application. A will reduce the performance and capacity of the database. C may incur additional charges for scaling up the DB instance. It may also cause downtime during the scaling process, which violates the requirement that the database cannot be down outside of scheduled maintenance hours. D may not react fast enough to handle unpredictable peak usage times. It may also cause memory issues if the max_connections setting is too high.
upvoted 1 times
...
love777
1 year, 2 months ago
Selected Answer: B
Adding an Amazon EventBridge rule to increase the max_connections setting based on CPU utilization is not directly addressing the issue of too many connections. Additionally, focusing solely on CPU utilization might not be the best metric for handling connection-related issues.
upvoted 2 times
...
tttamtttam
1 year, 3 months ago
Selected Answer: B
I think D is incorrect because it increases the number of connections based on the CPU consumption not the number of connections.
upvoted 1 times
...
Naj_64
1 year, 3 months ago
Selected Answer: D
https://repost.aws/knowledge-center/rds-mysql-max-connections
upvoted 1 times
...
csG13
1 year, 4 months ago
Selected Answer: B
It’s B. RDS proxy can handle many open connections to the database.
upvoted 3 times
...
awsdummie
1 year, 5 months ago
Selected Answer: D
There should not be any downtime. Create an Event bridge rule to update the max_connections parameter in Parameter group of DB instance.
upvoted 1 times
...
Community vote distribution
A (35%)
C (25%)
B (20%)
Other
Most Voted
A voting comment increases the vote count for the chosen answer by one.

Upvoting a comment with a selected answer will also increase the vote count towards that answer by one. So if you see a comment that you already agree with, you can upvote it instead of posting a new comment.

SaveCancel
Loading ...
exam
Someone Bought Contributor Access for:
SY0-701
London, 1 minute ago