Hacker News new | ask | show | jobs
by tasn 1321 days ago
Having maintained a service that uses Lambda. I think Lambda is probably fine for one-shot tasks, or taking from a queue (which is what it was built for), but I would never use it for API endpoints.

The main issues: 1. Unpredictable performance - latency (with cold start), concurrency limits (how quickly can we scale to X concurrent requests), etc? We spent many hours with AWS support before moving away from lambda. 2. Short running process are terrible in many ways - no DB connection pooling, no in memory cache.

I'd be much more happy if AWS fixed scale-up speed of ECS tasks so you can scale up your services in a reasonable time, than having these one-shot tasks.

1 comments

Our app is mostly hit during business hours. So we wrote a pinger to "wake up" the back end lambdas when a user visits the website (not log in, just hit the site anywhere) *and* it's been more than 5 minutes since the last ping. It's not perfect but it helps a lot with the cold start times.
Our problem wasn't with zero traffic cold starts (nothing is calling the Lambda), but rather with scaling up cold starts (oh damn, traffic! We need more lambdas!).