Containers or Serverless Functions : When to choose What - cheatsheet for you.
Arnauv Kaushik
Cloud Solutions Architect @ Microsoft ||Azure and AWS certified || AWS Educate Challenge winner || Drummer || MCU geek || dog lover
Recently I attended the AWS Innovate sessions organized by Amazon Web Services (AWS) which had a session presented by Karan Thanvi , same as the title.
Here I am sharing the key takeaways that can help you decide, and save some research and time!
Containers :
Trending since last couple of years or so due to?their optimized resource utilization, portability when compared to traditional VMs,
One negative point would be that they run 24X7 waiting for a request and this adds up the cost.
Serverless :
With Serverless we always have these 4 assured properties :?
- No need to provision and manage servers.
- Never pay for ideal resources.
- Service auto-scales.
- Inherently Highly Available.?
So when it comes to Serverless Functions, they are always invoked, NEVER sitting idle to listen to a request.
AWS Lambda service provides us Event Source Mapping that listens to messages/events and triggers the function.
Comparison results :
COST?
For containers you pay per instance, for serverless functions you pay per use.
领英推荐
FLEXIBILITY?
Containers offer more flexibility, like
SIMPLICITY?
Bridging the gap : SERVERLESS CONTAINERS
What if we use containers, the serverless way, to get the best of both worlds.
Here are the two choices :?
Fargate : Run containers without needing to fine-grain control over underlying infra.
App Runner : App Runner takes it one step further, with no need to configure networking or cluster orchestration even.
I hope this article helps you understand the fundamental differences and primary use cases for both containers and serverless functions, also highlighting that things are not black and white anymore, thanks to serverless containers!
If you have any questions, feel free to reach out! I'll be happy to help from my experience.
I'll be sharing more posts and articles based on cloud trends and updates mixed with hands-on labs!
Data Analyst @ OpenSky Data Systems | Microsoft Certified: Power BI Data Analyst Associate
4 个月Interesting
Solutions Architect - Startups @ AWS
4 个月Thank you Arnauv Kaushik :) hope you had enjoyed the session!
| ????DevOps Engineer | ?? Cloud Engineer | ?? AWS Architect | ?? System Design | ??HashiCorp Certified Terraform Associate | ?? 2x Kubernetes Certified CKA/CKAD | ?? Linux Certified
4 个月Very helpful