AWS Certified SysOps Administrator – Associate — Question 3
A company is running a serverless application on AWS Lambda. The application stores data in an Amazon RDS for MySQL DB instance. Usage has steadily increased, and recently there have been numerous "too many connections" errors when the Lambda function attempts to connect to the database. The company already has configured the database to use the maximum max_connections value that is possible.
What should a SysOps administrator do to resolve these errors?
Answer options
- A. Create a read replica of the database. Use Amazon Route 53 to create a weighted DNS record that contains both databases.
- B. Use Amazon RDS Proxy to create a proxy. Update the connection string in the Lambda function.
- C. Increase the value in the max_connect_errors parameter in the parameter group that the database uses.
- D. Update the Lambda function's reserved concurrency to a higher value.
Correct answer: B
Explanation
The correct answer is B because Amazon RDS Proxy helps manage database connections efficiently, allowing the Lambda function to handle more concurrent connections without hitting the max_connections limit. Option A is incorrect as creating a read replica does not directly address the connection limit issue. Option C is not valid because increasing max_connect_errors does not solve the problem of exceeding max_connections. Option D also doesn't resolve the connection error, as increasing reserved concurrency only scales the Lambda function but does not affect database connection limits.