SlideShare a Scribd company logo
1 of 15
Download to read offline
AWS Fargate vs. Lambda
Agenda AWS Fargate: An overview
AWS Lambda: An overview
Fargate vs. Lambda: Development
Fargate vs. Lambda: Performance
Fargate vs. Lambda: Pricing
Fargate vs. Lambda: Operational compatibility
Fargate vs. Lambda: Scalability and maintenance
Fargate vs. Lambda: Security
Key characteristics and use cases of AWS Fargate
Key characteristics and use cases of AWS Lambda
AWS Fargate: An overview
Fargate is a serverless compute engine that allows you
to run containers without managing the infrastructure.
It complements ECS/EKS and makes launching
container-based applications much more effortless.
Therefore, you can focus on building your applications
while AWS does the heavy lifting of provisioning,
configuring, and scaling servers or clusters.
All you need to do is define the infrastructure
parameters, and Fargate will launch the containers for
you.
AWS Lambda: An overview
Lambda, an event-driven compute engine, is another
serverless technology from AWS.
It reduces the operational overhead of managing the
infrastructure with a pay-per-use model and no upfront
cost.
In addition, it enables you to run code in response to
events and automatically provisions for and manages the
compute resources required.
AWS Fargate vs. Lambda: Development
Developers can build locally using Docker and run the
container images directly in the cloud with Fargate.
It takes care of everything in-between.
Developing with Docker is quite popular as its features
can be used for easily managing multiple containers,
network configurations, resource requirements, etc., and
it has larger community support.
Recently, AWS and its community have developed
numerous tools to develop, create, and manage Lambda
functions seamlessly.
Earlier, developing with Lambda was a complex process
as it lacked a straightforward procedure to run Lambda
functions in the cloud, along with runtime restrictions.
Fargate: Lambda:
AWS Fargate vs. Lambda: Performance
Typically, the startup time for Fargate containers is 60-90
seconds which is more than Lambda.
However, Fargate has dedicated resources and no
runtime limitations, so the environment remains in a warm
state.
But it may take more startup time if there is a sudden
spike of requests, and it takes longer to scale up.
The initial Lambda startup takes 5 seconds, following
which the same functions have a negligible startup time.
But a Lambda function stops running after 15 minutes
until triggered by an event, causing cold starts.
However, there are multiple ways and techniques to
reduce and prevent Lambda cold starts that you can read
in our blog post on how to avoid Lambda cold starts.
Fargate: Lambda:
AWS Fargate vs. Lambda: Pricing
AWS Fargate pricing is calculated per second based on
the allocated memory, vCPUs, OSs, CPU infrastructure,
and storage resources used.
AWS Lambda pricing is calculated per millisecond based
on the number of requests, the memory and runtime used
by functions, and the network traffic.
Fargate: Lambda:
AWS Fargate vs. Lambda: Operational compatibility
It comes with additional complexity as you still have to
register your containers with ECS.
But it offers significantly more flexibility in that you have
full access to the configuration of each container.
It entirely abstracts the whole infrastructure layer, allowing
you to focus on your critical application functionalities.
But its operational flexibility is restricted as it limits
temporary disk space to 512MB and includes a 50MB
deployment package.
Fargate: Lambda:
AWS Fargate vs. Lambda: Scalability and maintenance
In the case of Fargate, you need to set up autoscaling.
Also, you need to shut down Fargate tasks on a manual
or scheduled basis as it cannot scale to 0, adding to
maintenance.
Moreover, in Fargate, the developers must keep the base
container images updated.
So it again adds to the maintenance but allows for more
control.
Lambda functions are scalable by design, so they
automatically launch instances to meet the increases in
demand.
Apart from rapid auto-scaling, it can also scale to 0. So,
you don’t have to pay for idle applications, which is useful
for low traffic workloads.
This ability of Lambda to scale from 0-1000 rapidly is
essential for spiky and unpredictable traffic.
Fargate: Lambda:
AWS Fargate vs. Lambda: Security
With Fargate, permissions are associated with containers
or pods the tasks are run in.
All Fargate tasks run in their individual, isolated compute
environments without sharing any underlying resources
(kernel, CPU/memory, Elastic Network Interface) with
other tasks.
With Lambda, you can set up IAM roles that each function
or service will assume.
AWS Identity and Access Management (IAM) modules
ensure that only the right users can access the function or
the application.
Moreover, functions have dedicated execution
environments that are never shared with other functions.
Fargate: Lambda:
Key characteristics
and use cases of
AWS Fargate
Deploys and scales applications easily, from single-use utility
applications to entirely containerized microservices
architectures.
Eliminates the operational overhead of choosing server types,
patching, sizing, cluster scheduling, optimizing cluster packing,
and more.
Allows you to pay only for what you use as Fargate’s fully
managed container environment automatically allocates the
required compute power-on-demand.
Integrates with a range of sibling AWS services for networking,
CI/CD, security, monitoring, etc.
Allows developers to have workload isolation.
Improves security with isolated compute environments.
When to use AWS
Fargate
Long-running compute jobs that are longer than 15 minutes
Applications that require more compute than Lambda offers, i.e.,
more than 3GB of memory
Applications with predictable scaling and where longer start
times are acceptable
Latency-sensitive and storage-intensive applications
Applications that need inter-container communication
Containerized machine learning applications
Key characteristics
and use cases of
AWS Lambda
Reduces costs because you only pay for the resources you use.
Scales automatically to handle a few requests per day or even
thousands of requests per second.
Reduces operational overhead such as administration,
maintenance, security patching, resizing, and adding servers for
any type of application or backend services.
Allows developers to spend more time on innovation with quicker
iterations.
Supports multiple programming languages.
Allows packaging and deploying of functions as container
images, expanding its use cases.
Easily integrates with other innovative AWS services.
When to use AWS
Lambda
Web applications and websites that require dynamic scaling to
handle excessive traffic loads at peak hours and save money
when there is no traffic.
For applications that can be easily expressed as single functions
with predictable usage of resources on each invocation.
Event-driven workloads and apps.
Custom mobile and IoT backends.
Asynchronous, small jobs to be managed in tandem.
File processing and automated file synchronization.
Real-time log analysis and data processing.
IT automation.
Contact Us
Email Address
contactus@simform.com
Website
www.simform.com
Social Presence
twitter.com/simform
facebook.com/simform
linkedin.com/company/simform/

More Related Content

More from Simform

Containerization Best Practices.pdf
Containerization Best Practices.pdfContainerization Best Practices.pdf
Containerization Best Practices.pdfSimform
 
Web Application Development Cost.pdf
Web Application Development Cost.pdfWeb Application Development Cost.pdf
Web Application Development Cost.pdfSimform
 
Containerization Use Cases.pdf
Containerization Use Cases.pdfContainerization Use Cases.pdf
Containerization Use Cases.pdfSimform
 
Database DevOps.pdf
Database DevOps.pdfDatabase DevOps.pdf
Database DevOps.pdfSimform
 
Leading DevOps Tools for 2022.pdf
Leading DevOps Tools for 2022.pdfLeading DevOps Tools for 2022.pdf
Leading DevOps Tools for 2022.pdfSimform
 
Agile vs. DevOps.pdf
Agile vs. DevOps.pdfAgile vs. DevOps.pdf
Agile vs. DevOps.pdfSimform
 
DevOps Automation.pdf
DevOps Automation.pdfDevOps Automation.pdf
DevOps Automation.pdfSimform
 
How to Build Real-time Application with Node.js.pdf
How to Build Real-time Application with Node.js.pdfHow to Build Real-time Application with Node.js.pdf
How to Build Real-time Application with Node.js.pdfSimform
 
Microservice Best Practices The 8020 Way.pdf
Microservice Best Practices The 8020 Way.pdfMicroservice Best Practices The 8020 Way.pdf
Microservice Best Practices The 8020 Way.pdfSimform
 
Docker Use Cases.pdf
Docker Use Cases.pdfDocker Use Cases.pdf
Docker Use Cases.pdfSimform
 
Microservices Design Principles.pdf
Microservices Design Principles.pdfMicroservices Design Principles.pdf
Microservices Design Principles.pdfSimform
 
7 Biggest Web Development Challenges You Can’t Ignore in 2022_2.pdf
7 Biggest Web Development Challenges You Can’t Ignore in 2022_2.pdf7 Biggest Web Development Challenges You Can’t Ignore in 2022_2.pdf
7 Biggest Web Development Challenges You Can’t Ignore in 2022_2.pdfSimform
 
A Guide on What Are Microservices: Pros, Cons, Use Cases, and More
A Guide on What Are Microservices: Pros, Cons, Use Cases, and MoreA Guide on What Are Microservices: Pros, Cons, Use Cases, and More
A Guide on What Are Microservices: Pros, Cons, Use Cases, and MoreSimform
 
Types of Software Testing: Definition, Objectives and Advantages
Types of Software Testing: Definition, Objectives and AdvantagesTypes of Software Testing: Definition, Objectives and Advantages
Types of Software Testing: Definition, Objectives and AdvantagesSimform
 
Capital One DevOps Case Study: A Bank with the Heart of Tech Company
Capital One DevOps Case Study: A Bank with the Heart of Tech CompanyCapital One DevOps Case Study: A Bank with the Heart of Tech Company
Capital One DevOps Case Study: A Bank with the Heart of Tech CompanySimform
 
How to implement DevOps for Enterprise
How to implement DevOps for EnterpriseHow to implement DevOps for Enterprise
How to implement DevOps for EnterpriseSimform
 
Serverless Security Checklist
Serverless Security ChecklistServerless Security Checklist
Serverless Security ChecklistSimform
 
Tech Stack for an App Like Airbnb
Tech Stack for an App Like AirbnbTech Stack for an App Like Airbnb
Tech Stack for an App Like AirbnbSimform
 
Case studies of Test Driven Development
Case studies of Test Driven DevelopmentCase studies of Test Driven Development
Case studies of Test Driven DevelopmentSimform
 
Everything You Need to Know About FaceApp
Everything You Need to Know About FaceAppEverything You Need to Know About FaceApp
Everything You Need to Know About FaceAppSimform
 

More from Simform (20)

Containerization Best Practices.pdf
Containerization Best Practices.pdfContainerization Best Practices.pdf
Containerization Best Practices.pdf
 
Web Application Development Cost.pdf
Web Application Development Cost.pdfWeb Application Development Cost.pdf
Web Application Development Cost.pdf
 
Containerization Use Cases.pdf
Containerization Use Cases.pdfContainerization Use Cases.pdf
Containerization Use Cases.pdf
 
Database DevOps.pdf
Database DevOps.pdfDatabase DevOps.pdf
Database DevOps.pdf
 
Leading DevOps Tools for 2022.pdf
Leading DevOps Tools for 2022.pdfLeading DevOps Tools for 2022.pdf
Leading DevOps Tools for 2022.pdf
 
Agile vs. DevOps.pdf
Agile vs. DevOps.pdfAgile vs. DevOps.pdf
Agile vs. DevOps.pdf
 
DevOps Automation.pdf
DevOps Automation.pdfDevOps Automation.pdf
DevOps Automation.pdf
 
How to Build Real-time Application with Node.js.pdf
How to Build Real-time Application with Node.js.pdfHow to Build Real-time Application with Node.js.pdf
How to Build Real-time Application with Node.js.pdf
 
Microservice Best Practices The 8020 Way.pdf
Microservice Best Practices The 8020 Way.pdfMicroservice Best Practices The 8020 Way.pdf
Microservice Best Practices The 8020 Way.pdf
 
Docker Use Cases.pdf
Docker Use Cases.pdfDocker Use Cases.pdf
Docker Use Cases.pdf
 
Microservices Design Principles.pdf
Microservices Design Principles.pdfMicroservices Design Principles.pdf
Microservices Design Principles.pdf
 
7 Biggest Web Development Challenges You Can’t Ignore in 2022_2.pdf
7 Biggest Web Development Challenges You Can’t Ignore in 2022_2.pdf7 Biggest Web Development Challenges You Can’t Ignore in 2022_2.pdf
7 Biggest Web Development Challenges You Can’t Ignore in 2022_2.pdf
 
A Guide on What Are Microservices: Pros, Cons, Use Cases, and More
A Guide on What Are Microservices: Pros, Cons, Use Cases, and MoreA Guide on What Are Microservices: Pros, Cons, Use Cases, and More
A Guide on What Are Microservices: Pros, Cons, Use Cases, and More
 
Types of Software Testing: Definition, Objectives and Advantages
Types of Software Testing: Definition, Objectives and AdvantagesTypes of Software Testing: Definition, Objectives and Advantages
Types of Software Testing: Definition, Objectives and Advantages
 
Capital One DevOps Case Study: A Bank with the Heart of Tech Company
Capital One DevOps Case Study: A Bank with the Heart of Tech CompanyCapital One DevOps Case Study: A Bank with the Heart of Tech Company
Capital One DevOps Case Study: A Bank with the Heart of Tech Company
 
How to implement DevOps for Enterprise
How to implement DevOps for EnterpriseHow to implement DevOps for Enterprise
How to implement DevOps for Enterprise
 
Serverless Security Checklist
Serverless Security ChecklistServerless Security Checklist
Serverless Security Checklist
 
Tech Stack for an App Like Airbnb
Tech Stack for an App Like AirbnbTech Stack for an App Like Airbnb
Tech Stack for an App Like Airbnb
 
Case studies of Test Driven Development
Case studies of Test Driven DevelopmentCase studies of Test Driven Development
Case studies of Test Driven Development
 
Everything You Need to Know About FaceApp
Everything You Need to Know About FaceAppEverything You Need to Know About FaceApp
Everything You Need to Know About FaceApp
 

AWS Fargate vs. Lambda.pdf

  • 2. Agenda AWS Fargate: An overview AWS Lambda: An overview Fargate vs. Lambda: Development Fargate vs. Lambda: Performance Fargate vs. Lambda: Pricing Fargate vs. Lambda: Operational compatibility Fargate vs. Lambda: Scalability and maintenance Fargate vs. Lambda: Security Key characteristics and use cases of AWS Fargate Key characteristics and use cases of AWS Lambda
  • 3. AWS Fargate: An overview Fargate is a serverless compute engine that allows you to run containers without managing the infrastructure. It complements ECS/EKS and makes launching container-based applications much more effortless. Therefore, you can focus on building your applications while AWS does the heavy lifting of provisioning, configuring, and scaling servers or clusters. All you need to do is define the infrastructure parameters, and Fargate will launch the containers for you.
  • 4. AWS Lambda: An overview Lambda, an event-driven compute engine, is another serverless technology from AWS. It reduces the operational overhead of managing the infrastructure with a pay-per-use model and no upfront cost. In addition, it enables you to run code in response to events and automatically provisions for and manages the compute resources required.
  • 5. AWS Fargate vs. Lambda: Development Developers can build locally using Docker and run the container images directly in the cloud with Fargate. It takes care of everything in-between. Developing with Docker is quite popular as its features can be used for easily managing multiple containers, network configurations, resource requirements, etc., and it has larger community support. Recently, AWS and its community have developed numerous tools to develop, create, and manage Lambda functions seamlessly. Earlier, developing with Lambda was a complex process as it lacked a straightforward procedure to run Lambda functions in the cloud, along with runtime restrictions. Fargate: Lambda:
  • 6. AWS Fargate vs. Lambda: Performance Typically, the startup time for Fargate containers is 60-90 seconds which is more than Lambda. However, Fargate has dedicated resources and no runtime limitations, so the environment remains in a warm state. But it may take more startup time if there is a sudden spike of requests, and it takes longer to scale up. The initial Lambda startup takes 5 seconds, following which the same functions have a negligible startup time. But a Lambda function stops running after 15 minutes until triggered by an event, causing cold starts. However, there are multiple ways and techniques to reduce and prevent Lambda cold starts that you can read in our blog post on how to avoid Lambda cold starts. Fargate: Lambda:
  • 7. AWS Fargate vs. Lambda: Pricing AWS Fargate pricing is calculated per second based on the allocated memory, vCPUs, OSs, CPU infrastructure, and storage resources used. AWS Lambda pricing is calculated per millisecond based on the number of requests, the memory and runtime used by functions, and the network traffic. Fargate: Lambda:
  • 8. AWS Fargate vs. Lambda: Operational compatibility It comes with additional complexity as you still have to register your containers with ECS. But it offers significantly more flexibility in that you have full access to the configuration of each container. It entirely abstracts the whole infrastructure layer, allowing you to focus on your critical application functionalities. But its operational flexibility is restricted as it limits temporary disk space to 512MB and includes a 50MB deployment package. Fargate: Lambda:
  • 9. AWS Fargate vs. Lambda: Scalability and maintenance In the case of Fargate, you need to set up autoscaling. Also, you need to shut down Fargate tasks on a manual or scheduled basis as it cannot scale to 0, adding to maintenance. Moreover, in Fargate, the developers must keep the base container images updated. So it again adds to the maintenance but allows for more control. Lambda functions are scalable by design, so they automatically launch instances to meet the increases in demand. Apart from rapid auto-scaling, it can also scale to 0. So, you don’t have to pay for idle applications, which is useful for low traffic workloads. This ability of Lambda to scale from 0-1000 rapidly is essential for spiky and unpredictable traffic. Fargate: Lambda:
  • 10. AWS Fargate vs. Lambda: Security With Fargate, permissions are associated with containers or pods the tasks are run in. All Fargate tasks run in their individual, isolated compute environments without sharing any underlying resources (kernel, CPU/memory, Elastic Network Interface) with other tasks. With Lambda, you can set up IAM roles that each function or service will assume. AWS Identity and Access Management (IAM) modules ensure that only the right users can access the function or the application. Moreover, functions have dedicated execution environments that are never shared with other functions. Fargate: Lambda:
  • 11. Key characteristics and use cases of AWS Fargate Deploys and scales applications easily, from single-use utility applications to entirely containerized microservices architectures. Eliminates the operational overhead of choosing server types, patching, sizing, cluster scheduling, optimizing cluster packing, and more. Allows you to pay only for what you use as Fargate’s fully managed container environment automatically allocates the required compute power-on-demand. Integrates with a range of sibling AWS services for networking, CI/CD, security, monitoring, etc. Allows developers to have workload isolation. Improves security with isolated compute environments.
  • 12. When to use AWS Fargate Long-running compute jobs that are longer than 15 minutes Applications that require more compute than Lambda offers, i.e., more than 3GB of memory Applications with predictable scaling and where longer start times are acceptable Latency-sensitive and storage-intensive applications Applications that need inter-container communication Containerized machine learning applications
  • 13. Key characteristics and use cases of AWS Lambda Reduces costs because you only pay for the resources you use. Scales automatically to handle a few requests per day or even thousands of requests per second. Reduces operational overhead such as administration, maintenance, security patching, resizing, and adding servers for any type of application or backend services. Allows developers to spend more time on innovation with quicker iterations. Supports multiple programming languages. Allows packaging and deploying of functions as container images, expanding its use cases. Easily integrates with other innovative AWS services.
  • 14. When to use AWS Lambda Web applications and websites that require dynamic scaling to handle excessive traffic loads at peak hours and save money when there is no traffic. For applications that can be easily expressed as single functions with predictable usage of resources on each invocation. Event-driven workloads and apps. Custom mobile and IoT backends. Asynchronous, small jobs to be managed in tandem. File processing and automated file synchronization. Real-time log analysis and data processing. IT automation.
  • 15. Contact Us Email Address contactus@simform.com Website www.simform.com Social Presence twitter.com/simform facebook.com/simform linkedin.com/company/simform/