Hacker News new | comments | ask | show | jobs | submit login

This is extremely frustrating. One of the biggest use cases for wanting to use Aurora serverless is connecting to MySQL using lambda functions -- Function as a Service apps that can still use rdbms. The problem is that RDS endpoints only exist inside vpcs, and cold starting a lambda function with a vpc network interface can take 10+ seconds, making it useless for an API. I had hoped that, given they were making a serverless MySQL service, they'd make sure it actually plays well with lambda. Nope. Same problems regular RDS has. No better method of securing the connection beyond vpc firewall rules. Amazon, it's been a problem since lambda was launched and it hasn't been fixed. Either fix lambda vpc cold start times, or provide a better way to connect lambda to RDS. Just burying the problem only pisses off your customers when they try to buy into your hype.

And since it always comes up:

* Yes, there is plenty of reason to want to use MySQL with lambda. Wanting to run software on FaaS does not mean wanting to abandon rdbms. For a small app, dynamodb is overkill; for a small app that turns into a large app, dynamodb is a money pit.

* No, adding scheduled heartbeat requests to the lambda functions so they never have to cold start is not a real, long term, scalable solution. It's a hack, it doesn't solve the problem if your app actually scales up, and infrastructure shouldn't depend on horrible hacks to function correctly.

I was disappointed to see this as well. I have just recently started to learn a bit more about lambda and the rds/vpc thing has been a bit of a sticking point. I had thought aurora-serverless would fix the vpc issue, I appreciate the autoscaling but I think at this point I’d still rather use rds/Postgres if it has to be in a vpc anyway. Assuming I’ll save more time using postgresql advanced features than money on the autoscaling.

I guess everyone is just using DynamoDB with their lambda functions, but I miss a lot of the power Postgres has.

What's missing is support for Cloudformation. Why? Because then someone will write a plug-in for the Serverless framework. Then using Aurora Serverless will be simple, no trying to create VPC's as it will be all scripted behind the scenes for you. There's only a single piece remaining and then Serverless will totally boom.

That’s only part of it, the long startup time is still there, even with cloud formation support. You can easily hack it all together with serverless framework now, and I’m really loving it for learning things but that startup time is going to be a problem for anything customer facing.

Creating a custom lambda backed resource and calling it from Cloud Formation is not hard. I’m currently using two - one to create a secure parameter in Parameter Store and one to create an AMI from an EC2 instance that I then use to create s launch configuration.

I’m sorry that you’re frustrated by our incremental improvement. This solves many problems for many people and I’m sorry it doesn’t solve your specific use case. That said, the problems you mentioned are definitely on the roadmap. Give us some time. We’re not burying the problem.

VPC NICs for Lambda were released in February 2016, and API Gateway + Lambda is heavily pushed as a use case. It's been 2 1/2 years, numerous new features have been released since then, both for Lamda and RDS, and this has not been resolved. The problem was apparent as soon as the feature was released. There are hundreds of blog articles about the problem, all of which tell you to just never let your Lambda instances thaw to try to combat it. Numerous frameworks for Lambda include automated plugins to schedule warming the lambda function every 5 minutes. It's been an issue since day 1, and for 2 years a solution has been "coming soon".

If my use case is small, that is only true because everyone else gave up on this use case, because it doesn't work, or resigned themselves to using a terrible hack to get it to work. Even though AWS Marketing heavily implies it's a great workflow, and leaves developers to run face first into its problems.

To be clear though, are you saying that there's a roadmap for fixing Lambda in VPC, or a roadmap for connecting to Aurora with Lambda without being in a VPC? At this point I'd take the latter and forget about the rest.

You're welcome to email me randhunt@amazon.com

Applications are open for YC Summer 2019

Guidelines | FAQ | Support | API | Security | Lists | Bookmarklet | Legal | Apply to YC | Contact