The main downside of Lambda, in particular for user facing applications is that the incentives of the cloud provider and you are completely opposed. You (the developer) want a bunch of warm lambdas ready to serve user requests and the cloud provider is looking to minimize costs by keeping the number of running lambdas as low as possible. It's the incentive model that fundamentally makes Lambda a poor choice for these types of applications.
Other downsides include the fact that Lambdas have fixed memory sizes. If you have units of work that vary in amount of memory required you're basically stuck paying the costs of the largest units of work unless you can implement some sort of routing logic somewhere else. My company ran into this issue using lambdas to process some data where the 99% of requests were fine running in 256mb but a few required more. There was so way to know ahead of time how much memory the computation would require ahead of time. We ended up finding a way to deal with it but in the short term we had to bump the lambda memory limits.
That doesn't even get into the problems with testing.
In my experience, Lambdas are best used as glue between AWS components, message processors and cron style tasks.
> the incentives of the cloud provider and you are completely opposed
I think this is a little overstated. The cloud provider wants their customers to be happy while minimizing costs (and therefore costs to the customer). It's not truly a perverse incentive scenario.
Disagree with "completely opposed". Cloud providers want to make money, sure, but in general everyone in the ecosystem benefits if every CPU cycle is used efficiently. Any overhead goes out of both AWS's and your pockets and instead to the electricity provider, server manufacturer, cooling service.
Other downsides include the fact that Lambdas have fixed memory sizes. If you have units of work that vary in amount of memory required you're basically stuck paying the costs of the largest units of work unless you can implement some sort of routing logic somewhere else. My company ran into this issue using lambdas to process some data where the 99% of requests were fine running in 256mb but a few required more. There was so way to know ahead of time how much memory the computation would require ahead of time. We ended up finding a way to deal with it but in the short term we had to bump the lambda memory limits.
That doesn't even get into the problems with testing.
In my experience, Lambdas are best used as glue between AWS components, message processors and cron style tasks.