When is AWS Lambda More Expensive Than Heroku?

02-Nov-2020 1241
I was talking to a friend of mine yesterday, and he mentioned that his company had a Django app deployed on AWS Lambda. I asked why, and one of his main reasons was that it's cheap.That got me intrigued - a Rails-like webapp, on Lambda, and it's cheap? Could that really be the case?To get my biases out front: I think most developers choose Lambda when what they really wanted was autoscaling on EC2 or Heroku. However, I'd like to lay out the case here that servers can be cheaper than serverless, and why that's the case.Our example scenario will be a typical web application:250 millisecond response times10 requests per second (600 requests/minute)Uses about 256MB of memory per processSince Lambda only does your "computing", we'll just compare computing costs alone. So, we're talking about Lambda costs versus Heroku web dyno costs.
Use coupon code:

RUBYONRAILS

to get 30% discount on our bundle!
Prepare for your next tech interview with our comprehensive collection of programming interview guides. Covering JavaScript, Ruby on Rails, React, and Python, these highly-rated books offer thousands of essential questions and answers to boost your interview success. Buy our 'Ultimate Job Interview Preparation eBook Bundle' featuring 2200+ questions across multiple languages. Ultimate Job Interview Preparation eBook Bundle