Making the Right Decision for Your Workload
Ashok Kumar
ashok.kumar2@comviva.com
Demystifying Serverless
26-MAY-2023 ​ | 8th World DevOps Summit Bangalore ​
 Serverless 101
 State of Serverless in CNCF
 Serverless use cases
 Demo
 Serverless v/s container
 Function into apps
26-MAY-2023 ​ | 8th World DevOps Summit Bangalore ​
What is Serverless?
26-MAY-2023 ​ | 8th World DevOps Summit Bangalore ​
Compute Without Server
 Run code without managing infra
 Pay only for resources used
 Event driven invocation
 Stateless
26-MAY-2023 ​ | 8th World DevOps Summit Bangalore ​
What is Serverless?
Serverless is lightweight event-based microservices.
-Google Functions
Serverless is the native architecture of the cloud that enables you to shift
more of your operational responsibilities to AWS, increasing your agility
and innovation. Serverless allows you to build and run applications and
services without thinking about servers.
- AWS
26-MAY-2023 ​ | 8th World DevOps Summit Bangalore ​
What is Serverless
 No Servers to provision or manage
 Automatically scales with usage
 Never pay for idle
 HA
26-MAY-2023 ​ | 8th World DevOps Summit Bangalore ​
History of Serverless
 2012 -used to describe BaaS and Continuous Integration services run by third parties
 2014 -AWS launched Lambda
 2015 -AWS launched API Gateway
 2016 - Serverless Conference & GCP, Azure , IBM etc .. FaaS offerings GA
 2017 - Serverless Framework released
• 2020- 202X - Edge Functions , Cloudflare Workers and Other cloud providers continue
to enhance
26-MAY-2023 ​ | 8th World DevOps Summit Bangalore ​
Serverless SRM
Source: unraveldata.com
26-MAY-2023 ​ | 8th World DevOps Summit Bangalore ​
Market Serverless Offerings
26-MAY-2023 ​ | 8th World DevOps Summit Bangalore ​
Offerings
Comparison
Source: simform.com
26-MAY-2023 ​ | 8th World DevOps Summit Bangalore ​
State of Serverless in CNCF is Serverless
26-MAY-2023 ​ | 8th World DevOps Summit Bangalore ​
State of Serverless in CNCF is Serverless
Source: https://landscape.cncf.io/serverless?zoom=150
26-MAY-2023 ​ | 8th World DevOps Summit Bangalore ​
State of Serverless in CNCF is Serverless
Source: https://landscape.cncf.io/format=serverless
26-MAY-2023 ​ | 8th World DevOps Summit Bangalore ​
Serverless Application Use Cases
26-MAY-2023 ​ | 8th World DevOps Summit Bangalore ​
Web Applications and Backends
Reference Architecture: Sample code
Example: Weather application
https://github.com/aws-samples/lambda-refarch-webapp
26-MAY-2023 ​ | 8th World DevOps Summit Bangalore ​
Batch Application
Source: AWS
26-MAY-2023 ​ | 8th World DevOps Summit Bangalore ​
Data processing
Reference Architecture: Sample code
Example: Image Thumbnail Creation
https://github.com/awslabs/lambda-refarch-fileprocessing
26-MAY-2023 ​ | 8th World DevOps Summit Bangalore ​
Event Driven Application
 Event Triggers
 Faster Start-up time
 Event Based Triggers
 Stateless
 Cloud Vendor Based
 Pricing
Source: AWS
26-MAY-2023 ​ | 8th World DevOps Summit Bangalore ​
Demo
26-MAY-2023 ​ | 8th World DevOps Summit Bangalore ​
26-MAY-2023 ​ | 8th World DevOps Summit Bangalore ​
source: https://dev.to/jignesh_simform
What is Container
 Standard unit of software that packages up code and all its dependencies
 Application runs quickly and reliably from one computing environment to another
26-MAY-2023 ​ | 8th World DevOps Summit Bangalore ​
FaaS vs PaaS
26-MAY-2023 ​ | 8th World DevOps Summit Bangalore ​
Container Orchestration Engine
 Container orchestration engine automates deploying, scaling,
managing containerized application on a group of the servers.
 It is known as COE.
• Clustering
• Scheduling
• Scalability
• LB
• Fault tolerance
• Deployment
COE Enables
26-MAY-2023 ​ | 8th World DevOps Summit Bangalore ​
When to use Serverless?
When to use k8s?
26-MAY-2023 ​ | 8th World DevOps Summit Bangalore ​
Source: medium
26-MAY-2023 ​ | 8th World DevOps Summit Bangalore ​
Serverless vs Container
Serverless
• Container technology enables you to
scale
• Containers are vendor-agnostic
• Full flexibility and control
• provide tools for scaling and monitoring
instances based on defined metrics
Container
Superpower - Easier to
onboard focus on solving
business problem from
get go
Superpower - Complete control of
environment rich echo system
• Minimum overhead
• Requires minimal infrastructure
provisioning
• As you pay per function execution
• no worry about scalability
• Vendor Lock-In
26-MAY-2023 ​ | 8th World DevOps Summit Bangalore ​
Serverless vs Container
Serverless
• Data inside a container disappears
forever
• Applications that don’t require a
graphical interface
• Portability
• Complexity in Some Scenarios
Container
• “black box” technology
• Application grows, the complexity of
troubleshooting explodes
• Cold Start Latency
• Sometimes can be Very tricky to get right
and typically requires significant upfront
human resource costs
26-MAY-2023 ​ | 8th World DevOps Summit Bangalore ​
CBA
3 million/month ,512 Memory, 300 ms execution
time , Unpredictable traffic
$7.67/month
90 million/month ,512 Memory, 250 ms execution
time , predictable traffic
= $230/month
Serverless
3 million/month ,512 Memory, 300 ms
execution time , Unpredictable traffic
$148.67/month (CP) + $15 (t3.small worker
node) = $163.67/month
(cost will increase during higher spike coz of
scaling)
90 million/month ,512 Memory, 250 ms
execution time , predictable traffic
$148.67/month (CP) + $29 (t3.medium worker
node) = $177.67/month
Container
26-MAY-2023 ​ | 8th World DevOps Summit Bangalore ​
Functions into apps
 I want to sequence functions
 I want to select functions based on data
 I want to retry functions
 I want try/catch/finally
 I have code that runs for hours
26-MAY-2023 ​ | 8th World DevOps Summit Bangalore ​
Q&A
26-MAY-2023 ​ | 8th World DevOps Summit Bangalore ​
THANK YOU
ashok.qlo.in | ashok.kumar2@comviva.com
26-MAY-2023 ​ | 8th World DevOps Summit Bangalore ​

Demystifying Serverless: Making the Right Decision for Your Workload

  • 1.
    Making the RightDecision for Your Workload Ashok Kumar ashok.kumar2@comviva.com Demystifying Serverless 26-MAY-2023 ​ | 8th World DevOps Summit Bangalore ​
  • 2.
     Serverless 101 State of Serverless in CNCF  Serverless use cases  Demo  Serverless v/s container  Function into apps 26-MAY-2023 ​ | 8th World DevOps Summit Bangalore ​
  • 3.
    What is Serverless? 26-MAY-2023​ | 8th World DevOps Summit Bangalore ​
  • 4.
    Compute Without Server Run code without managing infra  Pay only for resources used  Event driven invocation  Stateless 26-MAY-2023 ​ | 8th World DevOps Summit Bangalore ​
  • 5.
    What is Serverless? Serverlessis lightweight event-based microservices. -Google Functions Serverless is the native architecture of the cloud that enables you to shift more of your operational responsibilities to AWS, increasing your agility and innovation. Serverless allows you to build and run applications and services without thinking about servers. - AWS 26-MAY-2023 ​ | 8th World DevOps Summit Bangalore ​
  • 6.
    What is Serverless No Servers to provision or manage  Automatically scales with usage  Never pay for idle  HA 26-MAY-2023 ​ | 8th World DevOps Summit Bangalore ​
  • 7.
    History of Serverless 2012 -used to describe BaaS and Continuous Integration services run by third parties  2014 -AWS launched Lambda  2015 -AWS launched API Gateway  2016 - Serverless Conference & GCP, Azure , IBM etc .. FaaS offerings GA  2017 - Serverless Framework released • 2020- 202X - Edge Functions , Cloudflare Workers and Other cloud providers continue to enhance 26-MAY-2023 ​ | 8th World DevOps Summit Bangalore ​
  • 8.
    Serverless SRM Source: unraveldata.com 26-MAY-2023​ | 8th World DevOps Summit Bangalore ​
  • 9.
    Market Serverless Offerings 26-MAY-2023​ | 8th World DevOps Summit Bangalore ​
  • 10.
    Offerings Comparison Source: simform.com 26-MAY-2023 ​| 8th World DevOps Summit Bangalore ​
  • 11.
    State of Serverlessin CNCF is Serverless 26-MAY-2023 ​ | 8th World DevOps Summit Bangalore ​
  • 12.
    State of Serverlessin CNCF is Serverless Source: https://landscape.cncf.io/serverless?zoom=150 26-MAY-2023 ​ | 8th World DevOps Summit Bangalore ​
  • 13.
    State of Serverlessin CNCF is Serverless Source: https://landscape.cncf.io/format=serverless 26-MAY-2023 ​ | 8th World DevOps Summit Bangalore ​
  • 14.
    Serverless Application UseCases 26-MAY-2023 ​ | 8th World DevOps Summit Bangalore ​
  • 15.
    Web Applications andBackends Reference Architecture: Sample code Example: Weather application https://github.com/aws-samples/lambda-refarch-webapp 26-MAY-2023 ​ | 8th World DevOps Summit Bangalore ​
  • 16.
    Batch Application Source: AWS 26-MAY-2023​ | 8th World DevOps Summit Bangalore ​
  • 17.
    Data processing Reference Architecture:Sample code Example: Image Thumbnail Creation https://github.com/awslabs/lambda-refarch-fileprocessing 26-MAY-2023 ​ | 8th World DevOps Summit Bangalore ​
  • 18.
    Event Driven Application Event Triggers  Faster Start-up time  Event Based Triggers  Stateless  Cloud Vendor Based  Pricing Source: AWS 26-MAY-2023 ​ | 8th World DevOps Summit Bangalore ​
  • 19.
    Demo 26-MAY-2023 ​ |8th World DevOps Summit Bangalore ​
  • 20.
    26-MAY-2023 ​ |8th World DevOps Summit Bangalore ​ source: https://dev.to/jignesh_simform
  • 21.
    What is Container Standard unit of software that packages up code and all its dependencies  Application runs quickly and reliably from one computing environment to another 26-MAY-2023 ​ | 8th World DevOps Summit Bangalore ​
  • 22.
    FaaS vs PaaS 26-MAY-2023​ | 8th World DevOps Summit Bangalore ​
  • 23.
    Container Orchestration Engine Container orchestration engine automates deploying, scaling, managing containerized application on a group of the servers.  It is known as COE. • Clustering • Scheduling • Scalability • LB • Fault tolerance • Deployment COE Enables 26-MAY-2023 ​ | 8th World DevOps Summit Bangalore ​
  • 24.
    When to useServerless? When to use k8s? 26-MAY-2023 ​ | 8th World DevOps Summit Bangalore ​
  • 25.
    Source: medium 26-MAY-2023 ​| 8th World DevOps Summit Bangalore ​
  • 26.
    Serverless vs Container Serverless •Container technology enables you to scale • Containers are vendor-agnostic • Full flexibility and control • provide tools for scaling and monitoring instances based on defined metrics Container Superpower - Easier to onboard focus on solving business problem from get go Superpower - Complete control of environment rich echo system • Minimum overhead • Requires minimal infrastructure provisioning • As you pay per function execution • no worry about scalability • Vendor Lock-In 26-MAY-2023 ​ | 8th World DevOps Summit Bangalore ​
  • 27.
    Serverless vs Container Serverless •Data inside a container disappears forever • Applications that don’t require a graphical interface • Portability • Complexity in Some Scenarios Container • “black box” technology • Application grows, the complexity of troubleshooting explodes • Cold Start Latency • Sometimes can be Very tricky to get right and typically requires significant upfront human resource costs 26-MAY-2023 ​ | 8th World DevOps Summit Bangalore ​
  • 28.
    CBA 3 million/month ,512Memory, 300 ms execution time , Unpredictable traffic $7.67/month 90 million/month ,512 Memory, 250 ms execution time , predictable traffic = $230/month Serverless 3 million/month ,512 Memory, 300 ms execution time , Unpredictable traffic $148.67/month (CP) + $15 (t3.small worker node) = $163.67/month (cost will increase during higher spike coz of scaling) 90 million/month ,512 Memory, 250 ms execution time , predictable traffic $148.67/month (CP) + $29 (t3.medium worker node) = $177.67/month Container 26-MAY-2023 ​ | 8th World DevOps Summit Bangalore ​
  • 29.
    Functions into apps I want to sequence functions  I want to select functions based on data  I want to retry functions  I want try/catch/finally  I have code that runs for hours 26-MAY-2023 ​ | 8th World DevOps Summit Bangalore ​
  • 30.
    Q&A 26-MAY-2023 ​ |8th World DevOps Summit Bangalore ​
  • 31.
    THANK YOU ashok.qlo.in |ashok.kumar2@comviva.com 26-MAY-2023 ​ | 8th World DevOps Summit Bangalore ​