Database Connection Pooling with Aurora Serverless & Lambdas
Hi - I am having issues with high latency in connecting lambdas and a Postgres Aurora Serverless cluster via the Data API. After some research, it looks like Connection Pooling is the best solution. However, it looks RDS Proxy (the AWS native connection pooling solution) doesn't support Aurora Serverless. Does anyone know a workaround for this (while still using Aurora Serverless)?
Hello AWS Customer,
Yes you are correct, RDS Proxy is not supported for Aurora serverless as of now. As the document: https://aws.amazon.com/blogs/database/best-practices-for-working-with-amazon-aurora-serverless/ mentions, You have two choices with Aurora Serverless: manage your own application connection pooling or use the Amazon RDS Data API. The Data API reduces the effort of managing database connections or connection pools. The Data API doesn’t require a persistent connection to the DB cluster. Instead, it provides a secure HTTP endpoint, backed by a connection pool. So, you can choose between them for connection management. From the above document, apart from application connection pooling and data api section, you can also refer sections such as Minimizing pause and resume time, Pre-warming.
For more information on Data API, you can refer: https://docs.aws.amazon.com/AmazonRDS/latest/AuroraUserGuide/data-api.html
I hope this helps! If you are facing latency issues with your lambdas or any other issues, i would recommend you to open a new support case with AWS Premium support so the latency can be troubleshooted to see if there any issues.
Relevant questions
Does AWS Glue work with Serverless Aurora DB clusters?
Accepted Answerasked 3 years agoAurora Serverless v2 without VPC
asked 21 days agoDatabase Connection Pooling with Aurora Serverless & Lambdas
asked 3 months agoCannot connect remotely to serverless Aurora MySQL
asked 3 years agoCloudFormation - Aurora Fast Cloning
Accepted Answerasked 4 months agoMigration from Aurora to Aurora Serverless?
Accepted Answerasked 3 years agoAurora Serverless Query Editor: restrict to read-only queries
asked 4 months agoRDS Serverless DB Auto-Scale Fail
asked 4 months ago(Serverless) Amazon Aurora MySQL 1 end of life on February 28, 2023
asked 2 months agoMove RDS postgresql database to Aurora Serverless
Accepted Answerasked 3 years ago