SlideShare a Scribd company logo
FaaS or not to FaaS
Visible and invisible benefits of the
Serverless paradigm
Vadym Kazulkin, ip.labs, AWS User Group Qatar, 16 February 2022
Contact
Vadym Kazulkin
ip.labs Bonn, Germany
Co-Organizer: Java User Group Bonn and
Serverless Bonn Meetup
v.kazulkin@gmail.com
@VKazulkin
https://www.linkedin.com/in/vadymkazulkin/
https://www.iplabs.de/
ip.labs
https://www.iplabs.de/
The Value Proposition of
Serverless
Let’s talk about of Total Cost of
Ownership of the Serverless paradigm
TCO Full Picture
No Infrastructure
Operation and
Maintenance
Forrest Brazeal „The Business Case For Serverless” https://www.trek10.com/blog/business-case-for-serverless
No Infrastructure Maintenance
Is infrastructure maintenance and
operation your core competency ?
TCO Full Picture
No Infrastructure
Operation and
Maintenance
Auto Scaling and
Fault Tolerance
Built in
Forrest Brazeal „The Business Case For Serverless” https://www.trek10.com/blog/business-case-for-serverless
Auto Scaling And Fault Tolerance
Built In
• Can you get capacity planning
and auto scaling right?
• Do you want to solve the hard problem
of fault tolerance by yourself?
TCO Full Picture
No Infrastructure
Operation and
Maintenance
Auto Scaling and
Fault Tolerance
Built in
Own less, build more
Forrest Brazeal „The Business Case For Serverless” https://www.trek10.com/blog/business-case-for-serverless
“AWS Lambda is winning, but first it had to die” https://acloudguru.com/blog/engineering/aws-lambda-is-winning-but-first-it-had-to-die
Do more with less
By heavily relying on the managed
Serverless services you
• Need fewer engineers to start
implementing your new product idea
• Can do more with the same amount of
people
TCO Full Picture
No Infrastructure
Operation and
Maintenance
Auto Scaling and
Fault Tolerance
Built in
Own less, build more
Lower technical debt
Forrest Brazeal „The Business Case For Serverless” https://www.trek10.com/blog/business-case-for-serverless
Lower technical debt
• Whatever code you write today is always tomorrow’s technical debt
© Paul Johnston
• Less code means lower maintenance effort and lower technical
debt
• Time and effort required for maintaining the solution over its whole
lifecycle is by far much more than for developing it
Jeff Atwood „The Best Code is No Code At All” https://blog.codinghorror.com/the-best-code-is-no-code-at-all/
Paul Johnston “Cloud 2.0: Code is no longer King — Serverless has dethroned it”
https://medium.com/@PaulDJohnston/cloud-2-0-code-is-no-longer-king-serverless-has-dethroned-it-c6dc955db9d5
TCO Full Picture
No Infrastructure
Operation and
Maintenance
Auto Scaling and
Fault Tolerance
Built in
Own less, build more
Lower technical debt
Focus on Business
Value and Innovation
Forrest Brazeal „The Business Case For Serverless” https://www.trek10.com/blog/business-case-for-serverless
Focus On Business Value and
Innovation
Every organization wants exactly this!
Total Cost of Ownership of the Serverless paradigm
No Infrastructure
Operation and
Maintenance
Auto Scaling and
Fault Tolerance
Built in
Own less, build more
Lower technical debt
Faster Time to
Market
Forrest Brazeal „The Business Case For Serverless” https://www.trek10.com/blog/business-case-for-serverless
Focus on Business
Value and Innovation
Faster Time To Market
• Time To Market is the key differentiator in
today’s business!
• Ask yourself: what is core for your business and
what you can get as Commodity +(Utility) as a
Service?
Serverless...
…or not to Serverless ?
Image: https://stock.adobe.com
1. Application lifecycle
2. Workloads
3. Platform limitations
4. Cost at scale
5. Organizational environment
6. Platform and tooling maturity
Decision Checklist : understand your…
Vadym Kazulkin @VKazulkin , ip.labs GmbH
Understand
Application
lifecycle
Christian Posta „Be as serverless as you can, but not more than that” https://blog.christianposta.com/serverless/its-not-about-microservices-vs-serverless/
Explore phase
• Quickly validate
hypotheses
• Rapidly experiment
• Run experiments as
cheaply as possible
Serverless is a perfect fit
Image: burst.shopify.com/photos/a-look-across-the-landscape-with-view-of-the-sea Vadym Kazulkin @VKazulkin , ip.labs GmbH
Exploit phase
• Built something that does
provide customer value
• Build it on scale
• Build a profitable product
around it
partly serverless and partly not
serverless architecture
Image: Robert Scoble via Flickr Vadym Kazulkin @VKazulkin , ip.labs GmbH
Application lifecycle
• How much of my stack should I own
to be able to deliver business value?
• What should I outsource to my
service provider : SLA, regulatory
compliance, price, and roadmap?
Vadym Kazulkin @VKazulkin , ip.labs GmbH
Existing
applications
• You can’t magically move
them to the cloud providers
(especially make your
application Serverless)
• You can try to modernize
parts of them
Vadym Kazulkin @VKazulkin , ip.labs GmbH
Strangler Pattern
• Add a proxy (API
Gateway or Application
Loadbalancer), which
sits between the legacy
application and the user
• Add new services and
link it to the proxy
Marin Fowler „StrangerFigApplication” https://martinfowler.com/bliki/StranglerFigApplication.html Vadym Kazulkin @VKazulkin , ip.labs GmbH
FinDev Concept
Activity-based costing on a
digital operation-by-operation
basis
• Figure out features which deliver
business value comparing to their
cost
Aleksander Simovic & Mark Schwarz „FinDev and Serverless Microeconomics: Part 1”
https://aws.amazon.com/de/blogs/enterprise-strategy/findev-and-serverless-microeconomics-part-1/
Vadym Kazulkin @VKazulkin , ip.labs GmbH
1. Application lifecycle
2. Workloads
3. Platform limitations
4. Cost at scale
5. Organizational environment
6. Platform and tooling maturity
Vadym Kazulkin @VKazulkin , ip.labs GmbH
Understand your
workloads
• Event-driven
• API-driven
• Batch Job
• Internal Tool
• ML/AI
• Big Data
Image: flickr.com/photos/everywhereatonce/294789504 Vadym Kazulkin @VKazulkin , ip.labs GmbH
Lambda Layers
& Lambda
Runtime API
Door opener for use
cases like:
• Big Data
• ML/AI
Vadym Kazulkin @VKazulkin , ip.labs GmbH
A Shared File System
for Your Lambda
Functions
Door opener for use case
like:
• ML/AI
Understand your workloads
• Do we need to access specialized
hardware ?
• GPU access required?
• Another RAM/CPU ratio?
• Do we need constantly high
performance?
• Response time below 100 ms
(bidding or gaming platforms)
“A Berkeley View on Serverless Computing” https://www2.eecs.berkeley.edu/Pubs/TechRpts/2019/EECS-2019-3.html
Understand your workloads
• Do we need high throughput ?
• Lambda‘s network bandwidth is limited
(an order of magnitude lower than a
single modern SSD) shared between all
functions packed on the same VM
• Do functions need to communicate with
each other?
• functions are not directly network
accessible, they must communicate via
an intermediary service
“A Berkeley View on Serverless Computing” https://www2.eecs.berkeley.edu/Pubs/TechRpts/2019/EECS-2019-3.html
1. Application lifecycle
2. Workloads
3. Platform limitations
4. Cost at scale
5. Organizational environment
6. Platform and tooling maturity
Vadym Kazulkin @VKazulkin , ip.labs GmbH
Understand platform
limitations
• Cold start
Vadym Kazulkin @VKazulkin , ip.labs GmbH
:
Source: Ajay Nair „Become a Serverless Black Belt” https://www.youtube.com/watch?v=oQFORsso2go
Cold Start
AWS Lambda cold start duration
per programming language
Source: Mikhail Shilkov: „AWS Lambda: Cold Start Duration per Language. 2020 edition” https://mikhail.io/serverless/coldstarts/aws/languages/
Cold start duration
• Below 1 second is best-case cold start duration for very simple Lambda
like HelloWorld with no dependencies
• It goes up significantly with more complex scenarios
• Dependencies to multiple OS projects
• Clients instantiation outside of the handler method to communicate with other
(AWS) services (e.g. DynamoDB, SNS, SQS, 3rd party)
• To minimize the cold start time apply best practices specific to your
programming language
• Worst-case cold starts can be higher than 10 and even 20 seconds
Provisioned
Concurrency for
Lambda Functions
Vadym Kazulkin @VKazulkin , ip.labs GmbH
Yan Cui: https://lumigo.io/blog/provisioned-concurrency-the-end-of-cold-starts/
Don‘t be scared
of cold starts
To avoid cold starts them
completely, you have to :
• Overpay
• Overprovision
Cold starts don’t really
matter if the you make
the call asynchronously
Vadym Kazulkin @VKazulkin , ip.labs GmbH
Max connection limit
of RDS
• Max number of connections depends
on the RAM of the selected RDS
• for db.t3.medium 450 max
connections
• Solutions for not reaching the max
connection limit for calling RDS from
Lambda
• Use NoSQL Database (DynamoDB)
• Use RDS-Proxy
• Use Data API for Aurora Serverless
Vadym Kazulkin @VKazulkin , ip.labs GmbH
Understand Service
Quotas 1/2
• Max parallel executions of all
Lambdas in each AWS Account per
Region
• Soft limit of 500-3000 parallel
• API Gateway throttle limit
• 1000 requests per second
• Invocation duration & timeouts
• Lambda 15min
• API Gateway integration 29sec
Vadym Kazulkin @VKazulkin , ip.labs GmbH
James Beswick: Operating Lambda: Application design and Service Quotas
https://aws.amazon.com/blogs/compute/operating-lambda-application-design-and-service-quotas-part-1/
Understand Service
Quotas 2/2
• Payload limit
• API Gateway 10 Mb
• Lambda 6 Mb
• SQS 256 Kb
• Max Memory assigned to Lambda
• 10GB
Vadym Kazulkin @VKazulkin , ip.labs GmbH
1. Application lifecycle
2. Workloads
3. Platform limitations
4. Cost at scale
5. Organizational environment
6. Platform and tooling maturity
Vadym Kazulkin @VKazulkin , ip.labs GmbH
The reality is…
Lambda is often just a
small percentage
of your total cost
Vadym Kazulkin, @VKazulkin
$ 3.50
Per million API calls
API Gateway
Vadym Kazulkin, @VKazulkin
HTTP APIs in Beta
70% cheaper as API Gateway
• Fewer configuration options
• Well-suited for most use-cases
DynamoDB On-Demand
Image: https://aws.amazon.com/blogs/aws/amazon-dynamodb-on-demand-no-capacity-planning-and-pay-per-request-pricing/ Vadym Kazulkin, @VKazulkin
Provisioned vs
On-Demand
• Use On-Demand for
spiky workloads
• Use Provisioned for
constantly high
workload
Vadym Kazulkin, @VKazulkin
Understand your cost at scale
• Lambda
• API Gateway
• Dynamo DB capacity choices
• Event Sources (SQS, SNS, EventBridge,
Kinesis)
• Step Functions
Vadym Kazulkin @VKazulkin , ip.labs GmbH
Understand your cost at scale
• Logging costs (AWS CloudWatch Logs)
• Monitoring costs (AWS CloudWatch)
• Tracing (AWS X-Ray)
• Remote API calls / 3rd party services price
models
Vadym Kazulkin @VKazulkin , ip.labs GmbH
1. Application lifecycle
2. Workloads
3. Platform limitations
4. Cost at scale
5. Organizational environment
6. Platform and tooling maturity
Vadym Kazulkin @VKazulkin , ip.labs GmbH
Understand organizational
environment (structure,
reponsibilities, knowledge,
culture)
• Do you already embrace
DevOps best practices?
Vadym Kazulkin @VKazulkin , ip.labs GmbH
Tom McLaughlin Talk:
What do we do when
the server goes away?
• Observability (Logging, Monitoring,
Tracing, & Alerting
• Chaos Engineering & Game Days
• Help understand constraints
of AWS services & choose the right
one
Tom McLaughlin „What do we do when the server goes away”
https://speakerdeck.com/tmclaugh/serverless-devops-what-do-we-do-when-the-server-goes-away
Charity Majors „The Future of Ops Careers” https://thenewstack.io/the-future-of-ops-careers Vadym Kazulkin @VKazulkin , ip.labs GmbH
Help understand constraints of AWS services &
choose the right one. Example Event Sources:
Vadym Kazulkin @VKazulkin , ip.labs GmbH
Event Sources
• SQS and SNS are
charged for requests
• Kinesis charges for
shard hours & PUT
requests
Image: https://blog.binaris.com/lambda-pricing-pitfalls/ Vadym Kazulkin @VKazulkin , ip.labs GmbH
Event Sources
• Cost for Kinesis grows
with slower rate
• Attractive at to
operate at scale
Image: https://blog.binaris.com/lambda-pricing-pitfalls/ Vadym Kazulkin @VKazulkin , ip.labs GmbH
Simon Wardley https://www.slideshare.net/swardley/why-the-fuss-about-serverless-88107645
Wardley Map
Co-evolution of practices with
Serverless 1/2
• True DevOps
• Complete infrastructure automation
• Chaos Engineering
• FinDev responsibilities in the teams
Sheen Brisals “Why the ‘WHY’ matters more than the ‘WHAT’ in Serverless!”
https://medium.com/lego-engineering/why-the-why-matters-more-than-the-what-in-serverless-2ef56c397962
DevOps Topologies: https://web.devopstopologies.com/
Co-evolution of practices with
Serverless 2/2
• Each team or even developer can have its own
(AWS test) account per feature or service
• Only minimal local testing (quick functional
tests)
• Adopt “testing in production”
Michael Bryzek “What do you know about testing in production?” https://www.youtube.com/watch?v=z-ATZTUgaAo
1. Application lifecycle
2. Workloads
3. Platform limitations
4. Cost at scale
5. Organizational environment
6. Platform and tooling maturity
Vadym Kazulkin @VKazulkin , ip.labs GmbH
Serverless platform and tooling maturity
• Infrastructure-as-a-Code
solutions maturity
• with AWS Cloud Formation, AWS CDK
• Development environment &
framework maturity
• with AWS SAM, AWS Amplify and
Serverless Framework
Image: http://tea.solgenomics.net/anatomy_viewer/microscopy/slm82_fruit Vadym Kazulkin @VKazulkin , ip.labs GmbH
Serverless platform and tooling maturity
• CI/CD
• with AWS CodeCommit, CodeBuild,
CodePipeline and CodeDeploy
• Observability (Logging,
Monitoring, Tracing, Alerting)
• with AWS CloudWatch and X-Ray
• Integration with 3rd party SaaS
• with AWS Lambda Extensions (Epsagon,
HashiCorp, Lumigo, Thundra, Datadog)
• with AWS EvenBridge (PagerDuty,
Zendesk, Shopify, Datadog)
Image: http://tea.solgenomics.net/anatomy_viewer/microscopy/slm82_fruit
AWS Lambda Extensions https://aws.amazon.com/de/about-aws/whats-new/2020/10/aws-lambda-extensions-integrate-operational-tools/
Vadym Kazulkin @VKazulkin , ip.labs GmbH
www.iplabs.de
Thank You!
FaaS or not to FaaS. Visible and invisible benefits of the Serverless paradigm at AWS User Group Qatar

More Related Content

PDF
Revolutionize DevOps with ML capabilities. Introduction to Amazon CodeGuru an...
PDF
Revolutionize DevOps with ML capabilities. Introduction to Amazon CodeGuru an...
PDF
Writing less code with Serverless on AWS at OOP 2022
PDF
Lessons Learned from building a serverless API
PDF
Whizlabs webinar - Deploying Portfolio Site with AWS Serverless
PDF
Adopting Java for the Serverless world at Serverless Meetup New York and Boston
PDF
Adopting Java for the Serverless world at Serverless Meetup Singapore
PDF
Serverless in production, an experience report (JeffConf)
Revolutionize DevOps with ML capabilities. Introduction to Amazon CodeGuru an...
Revolutionize DevOps with ML capabilities. Introduction to Amazon CodeGuru an...
Writing less code with Serverless on AWS at OOP 2022
Lessons Learned from building a serverless API
Whizlabs webinar - Deploying Portfolio Site with AWS Serverless
Adopting Java for the Serverless world at Serverless Meetup New York and Boston
Adopting Java for the Serverless world at Serverless Meetup Singapore
Serverless in production, an experience report (JeffConf)

Similar to FaaS or not to FaaS. Visible and invisible benefits of the Serverless paradigm at AWS User Group Qatar (20)

PDF
FaaS or not to FaaS. Visible and invsible benefits of the Serverless paradigm...
PDF
FaaS or not to FaaS. Visible and invisible benefits of the Serverless paradig...
PDF
"It’s not only Lambda! Economics behind Serverless" at JAX Conference in Mai ...
PDF
FaaS or not to FaaS. Visible and invisible benefits of the Serverless paradig...
PDF
FaaS or not to FaaS. Visible and invisible benefits of the Serverless paradig...
PDF
FaaS or not to FaaS. Visible and invisible benefits of the Serverless paradig...
PDF
FaaS or not to FaaS ServerlessDays Tel Aviv 2019
PDF
"It’s not only Lambda! Economics behind Serverless" at Serverless Architectur...
PDF
FaaS or not to FaaS. Visible and invisible benefits of the Serverless paradig...
PDF
FaaS or not to FaaS AWS Community Day Hamburg 2019 Bannes Kazulkin
PDF
FaaS or not to FaaS. It's not a silver bullet. AWS User Group Cologne October...
PDF
FaaS or not to FaaS. Visible and invisible benefits of the Serverless paradig...
PDF
Montréal AWS Users United: Let's go Serverless!
PDF
SpringOne Tour St. Louis - Serverless Spring
PDF
Serverless computing
PDF
Why Serverless?
PDF
Introduction to Serverless through Architectural Patterns
PPTX
Serverless architecture: focus on code, performance and costs
PDF
Convince your boss to go Serverless at AWS User Group Tirupathi and Serverles...
PDF
Serhat Can- 4 keytakeaways from running serverless on production for 4 years
FaaS or not to FaaS. Visible and invsible benefits of the Serverless paradigm...
FaaS or not to FaaS. Visible and invisible benefits of the Serverless paradig...
"It’s not only Lambda! Economics behind Serverless" at JAX Conference in Mai ...
FaaS or not to FaaS. Visible and invisible benefits of the Serverless paradig...
FaaS or not to FaaS. Visible and invisible benefits of the Serverless paradig...
FaaS or not to FaaS. Visible and invisible benefits of the Serverless paradig...
FaaS or not to FaaS ServerlessDays Tel Aviv 2019
"It’s not only Lambda! Economics behind Serverless" at Serverless Architectur...
FaaS or not to FaaS. Visible and invisible benefits of the Serverless paradig...
FaaS or not to FaaS AWS Community Day Hamburg 2019 Bannes Kazulkin
FaaS or not to FaaS. It's not a silver bullet. AWS User Group Cologne October...
FaaS or not to FaaS. Visible and invisible benefits of the Serverless paradig...
Montréal AWS Users United: Let's go Serverless!
SpringOne Tour St. Louis - Serverless Spring
Serverless computing
Why Serverless?
Introduction to Serverless through Architectural Patterns
Serverless architecture: focus on code, performance and costs
Convince your boss to go Serverless at AWS User Group Tirupathi and Serverles...
Serhat Can- 4 keytakeaways from running serverless on production for 4 years
Ad

More from Vadym Kazulkin (20)

PDF
How to develop, run and optimize Spring Boot 3 application on AWS Lambda - Wa...
PDF
Event-driven architecture patterns in highly scalable image storage solution-...
PDF
High performance Serverless Java on AWS- Serverless Architecture Javaland 2025
PDF
How to develop, run and optimize Spring Boot 3 application on AWS Lambda-OBI ...
PPTX
Making sense of AWS Serverless operations- AWS User Group Nuremberg
PDF
How to develop, run and optimize Spring Boot 3 application on AWS Lambda at V...
PPTX
Making sense of AWS Serverless operations at Believe in Serverless community ...
PDF
How to develop, run and optimize Spring Boot 3 application on AWS Lambda at I...
PDF
Making sense of AWS Serverless operations - Amarathon Geek China 2024
PDF
Event-driven architecture patterns in highly scalable image storage solution-...
PDF
High performance Serverless Java on AWS- Serverless Meetup Toronto
PDF
High performance Serverless Java on AWS- Serverless Architecture Conference B...
PDF
Making sense of AWS Serverless operations- Serverless Architecture Conference...
PDF
Detect operational anomalies in Serverless Applications with Amazon DevOps Gu...
PDF
Detect operational anomalies in Serverless Applications with Amazon DevOps Gu...
PDF
High performance Serverless Java on AWS- AWS Community Day Budapest 2024
PDF
Making sense of AWS Serverless operations AWS Community Day NL 2024-
PDF
Event-driven architecture patterns in highly scalable image storage solution ...
PDF
Detect operational anomalies in Serverless Applications with Amazon DevOps Gu...
PDF
High performance Serverless Java on AWS at We Are Developers 2024
How to develop, run and optimize Spring Boot 3 application on AWS Lambda - Wa...
Event-driven architecture patterns in highly scalable image storage solution-...
High performance Serverless Java on AWS- Serverless Architecture Javaland 2025
How to develop, run and optimize Spring Boot 3 application on AWS Lambda-OBI ...
Making sense of AWS Serverless operations- AWS User Group Nuremberg
How to develop, run and optimize Spring Boot 3 application on AWS Lambda at V...
Making sense of AWS Serverless operations at Believe in Serverless community ...
How to develop, run and optimize Spring Boot 3 application on AWS Lambda at I...
Making sense of AWS Serverless operations - Amarathon Geek China 2024
Event-driven architecture patterns in highly scalable image storage solution-...
High performance Serverless Java on AWS- Serverless Meetup Toronto
High performance Serverless Java on AWS- Serverless Architecture Conference B...
Making sense of AWS Serverless operations- Serverless Architecture Conference...
Detect operational anomalies in Serverless Applications with Amazon DevOps Gu...
Detect operational anomalies in Serverless Applications with Amazon DevOps Gu...
High performance Serverless Java on AWS- AWS Community Day Budapest 2024
Making sense of AWS Serverless operations AWS Community Day NL 2024-
Event-driven architecture patterns in highly scalable image storage solution ...
Detect operational anomalies in Serverless Applications with Amazon DevOps Gu...
High performance Serverless Java on AWS at We Are Developers 2024
Ad

Recently uploaded (20)

PDF
Per capita expenditure prediction using model stacking based on satellite ima...
PDF
Empathic Computing: Creating Shared Understanding
PPTX
20250228 LYD VKU AI Blended-Learning.pptx
PDF
Agricultural_Statistics_at_a_Glance_2022_0.pdf
PPTX
Detection-First SIEM: Rule Types, Dashboards, and Threat-Informed Strategy
PDF
Chapter 3 Spatial Domain Image Processing.pdf
PPTX
Effective Security Operations Center (SOC) A Modern, Strategic, and Threat-In...
PDF
NewMind AI Weekly Chronicles - August'25 Week I
PDF
Unlocking AI with Model Context Protocol (MCP)
PDF
Encapsulation_ Review paper, used for researhc scholars
PDF
Reach Out and Touch Someone: Haptics and Empathic Computing
PDF
Approach and Philosophy of On baking technology
PPTX
ACSFv1EN-58255 AWS Academy Cloud Security Foundations.pptx
PDF
Blue Purple Modern Animated Computer Science Presentation.pdf.pdf
PDF
Profit Center Accounting in SAP S/4HANA, S4F28 Col11
PDF
Peak of Data & AI Encore- AI for Metadata and Smarter Workflows
PPTX
Cloud computing and distributed systems.
PPTX
MYSQL Presentation for SQL database connectivity
PDF
Review of recent advances in non-invasive hemoglobin estimation
PPTX
Digital-Transformation-Roadmap-for-Companies.pptx
Per capita expenditure prediction using model stacking based on satellite ima...
Empathic Computing: Creating Shared Understanding
20250228 LYD VKU AI Blended-Learning.pptx
Agricultural_Statistics_at_a_Glance_2022_0.pdf
Detection-First SIEM: Rule Types, Dashboards, and Threat-Informed Strategy
Chapter 3 Spatial Domain Image Processing.pdf
Effective Security Operations Center (SOC) A Modern, Strategic, and Threat-In...
NewMind AI Weekly Chronicles - August'25 Week I
Unlocking AI with Model Context Protocol (MCP)
Encapsulation_ Review paper, used for researhc scholars
Reach Out and Touch Someone: Haptics and Empathic Computing
Approach and Philosophy of On baking technology
ACSFv1EN-58255 AWS Academy Cloud Security Foundations.pptx
Blue Purple Modern Animated Computer Science Presentation.pdf.pdf
Profit Center Accounting in SAP S/4HANA, S4F28 Col11
Peak of Data & AI Encore- AI for Metadata and Smarter Workflows
Cloud computing and distributed systems.
MYSQL Presentation for SQL database connectivity
Review of recent advances in non-invasive hemoglobin estimation
Digital-Transformation-Roadmap-for-Companies.pptx

FaaS or not to FaaS. Visible and invisible benefits of the Serverless paradigm at AWS User Group Qatar

  • 1. FaaS or not to FaaS Visible and invisible benefits of the Serverless paradigm Vadym Kazulkin, ip.labs, AWS User Group Qatar, 16 February 2022
  • 2. Contact Vadym Kazulkin ip.labs Bonn, Germany Co-Organizer: Java User Group Bonn and Serverless Bonn Meetup v.kazulkin@gmail.com @VKazulkin https://www.linkedin.com/in/vadymkazulkin/ https://www.iplabs.de/
  • 4. The Value Proposition of Serverless Let’s talk about of Total Cost of Ownership of the Serverless paradigm
  • 5. TCO Full Picture No Infrastructure Operation and Maintenance Forrest Brazeal „The Business Case For Serverless” https://www.trek10.com/blog/business-case-for-serverless
  • 6. No Infrastructure Maintenance Is infrastructure maintenance and operation your core competency ?
  • 7. TCO Full Picture No Infrastructure Operation and Maintenance Auto Scaling and Fault Tolerance Built in Forrest Brazeal „The Business Case For Serverless” https://www.trek10.com/blog/business-case-for-serverless
  • 8. Auto Scaling And Fault Tolerance Built In • Can you get capacity planning and auto scaling right? • Do you want to solve the hard problem of fault tolerance by yourself?
  • 9. TCO Full Picture No Infrastructure Operation and Maintenance Auto Scaling and Fault Tolerance Built in Own less, build more Forrest Brazeal „The Business Case For Serverless” https://www.trek10.com/blog/business-case-for-serverless “AWS Lambda is winning, but first it had to die” https://acloudguru.com/blog/engineering/aws-lambda-is-winning-but-first-it-had-to-die
  • 10. Do more with less By heavily relying on the managed Serverless services you • Need fewer engineers to start implementing your new product idea • Can do more with the same amount of people
  • 11. TCO Full Picture No Infrastructure Operation and Maintenance Auto Scaling and Fault Tolerance Built in Own less, build more Lower technical debt Forrest Brazeal „The Business Case For Serverless” https://www.trek10.com/blog/business-case-for-serverless
  • 12. Lower technical debt • Whatever code you write today is always tomorrow’s technical debt © Paul Johnston • Less code means lower maintenance effort and lower technical debt • Time and effort required for maintaining the solution over its whole lifecycle is by far much more than for developing it Jeff Atwood „The Best Code is No Code At All” https://blog.codinghorror.com/the-best-code-is-no-code-at-all/ Paul Johnston “Cloud 2.0: Code is no longer King — Serverless has dethroned it” https://medium.com/@PaulDJohnston/cloud-2-0-code-is-no-longer-king-serverless-has-dethroned-it-c6dc955db9d5
  • 13. TCO Full Picture No Infrastructure Operation and Maintenance Auto Scaling and Fault Tolerance Built in Own less, build more Lower technical debt Focus on Business Value and Innovation Forrest Brazeal „The Business Case For Serverless” https://www.trek10.com/blog/business-case-for-serverless
  • 14. Focus On Business Value and Innovation Every organization wants exactly this!
  • 15. Total Cost of Ownership of the Serverless paradigm No Infrastructure Operation and Maintenance Auto Scaling and Fault Tolerance Built in Own less, build more Lower technical debt Faster Time to Market Forrest Brazeal „The Business Case For Serverless” https://www.trek10.com/blog/business-case-for-serverless Focus on Business Value and Innovation
  • 16. Faster Time To Market • Time To Market is the key differentiator in today’s business! • Ask yourself: what is core for your business and what you can get as Commodity +(Utility) as a Service?
  • 19. 1. Application lifecycle 2. Workloads 3. Platform limitations 4. Cost at scale 5. Organizational environment 6. Platform and tooling maturity Decision Checklist : understand your… Vadym Kazulkin @VKazulkin , ip.labs GmbH
  • 20. Understand Application lifecycle Christian Posta „Be as serverless as you can, but not more than that” https://blog.christianposta.com/serverless/its-not-about-microservices-vs-serverless/
  • 21. Explore phase • Quickly validate hypotheses • Rapidly experiment • Run experiments as cheaply as possible Serverless is a perfect fit Image: burst.shopify.com/photos/a-look-across-the-landscape-with-view-of-the-sea Vadym Kazulkin @VKazulkin , ip.labs GmbH
  • 22. Exploit phase • Built something that does provide customer value • Build it on scale • Build a profitable product around it partly serverless and partly not serverless architecture Image: Robert Scoble via Flickr Vadym Kazulkin @VKazulkin , ip.labs GmbH
  • 23. Application lifecycle • How much of my stack should I own to be able to deliver business value? • What should I outsource to my service provider : SLA, regulatory compliance, price, and roadmap? Vadym Kazulkin @VKazulkin , ip.labs GmbH
  • 24. Existing applications • You can’t magically move them to the cloud providers (especially make your application Serverless) • You can try to modernize parts of them Vadym Kazulkin @VKazulkin , ip.labs GmbH
  • 25. Strangler Pattern • Add a proxy (API Gateway or Application Loadbalancer), which sits between the legacy application and the user • Add new services and link it to the proxy Marin Fowler „StrangerFigApplication” https://martinfowler.com/bliki/StranglerFigApplication.html Vadym Kazulkin @VKazulkin , ip.labs GmbH
  • 26. FinDev Concept Activity-based costing on a digital operation-by-operation basis • Figure out features which deliver business value comparing to their cost Aleksander Simovic & Mark Schwarz „FinDev and Serverless Microeconomics: Part 1” https://aws.amazon.com/de/blogs/enterprise-strategy/findev-and-serverless-microeconomics-part-1/ Vadym Kazulkin @VKazulkin , ip.labs GmbH
  • 27. 1. Application lifecycle 2. Workloads 3. Platform limitations 4. Cost at scale 5. Organizational environment 6. Platform and tooling maturity Vadym Kazulkin @VKazulkin , ip.labs GmbH
  • 28. Understand your workloads • Event-driven • API-driven • Batch Job • Internal Tool • ML/AI • Big Data Image: flickr.com/photos/everywhereatonce/294789504 Vadym Kazulkin @VKazulkin , ip.labs GmbH
  • 29. Lambda Layers & Lambda Runtime API Door opener for use cases like: • Big Data • ML/AI Vadym Kazulkin @VKazulkin , ip.labs GmbH A Shared File System for Your Lambda Functions Door opener for use case like: • ML/AI
  • 30. Understand your workloads • Do we need to access specialized hardware ? • GPU access required? • Another RAM/CPU ratio? • Do we need constantly high performance? • Response time below 100 ms (bidding or gaming platforms) “A Berkeley View on Serverless Computing” https://www2.eecs.berkeley.edu/Pubs/TechRpts/2019/EECS-2019-3.html
  • 31. Understand your workloads • Do we need high throughput ? • Lambda‘s network bandwidth is limited (an order of magnitude lower than a single modern SSD) shared between all functions packed on the same VM • Do functions need to communicate with each other? • functions are not directly network accessible, they must communicate via an intermediary service “A Berkeley View on Serverless Computing” https://www2.eecs.berkeley.edu/Pubs/TechRpts/2019/EECS-2019-3.html
  • 32. 1. Application lifecycle 2. Workloads 3. Platform limitations 4. Cost at scale 5. Organizational environment 6. Platform and tooling maturity Vadym Kazulkin @VKazulkin , ip.labs GmbH
  • 33. Understand platform limitations • Cold start Vadym Kazulkin @VKazulkin , ip.labs GmbH
  • 34. : Source: Ajay Nair „Become a Serverless Black Belt” https://www.youtube.com/watch?v=oQFORsso2go Cold Start
  • 35. AWS Lambda cold start duration per programming language Source: Mikhail Shilkov: „AWS Lambda: Cold Start Duration per Language. 2020 edition” https://mikhail.io/serverless/coldstarts/aws/languages/
  • 36. Cold start duration • Below 1 second is best-case cold start duration for very simple Lambda like HelloWorld with no dependencies • It goes up significantly with more complex scenarios • Dependencies to multiple OS projects • Clients instantiation outside of the handler method to communicate with other (AWS) services (e.g. DynamoDB, SNS, SQS, 3rd party) • To minimize the cold start time apply best practices specific to your programming language • Worst-case cold starts can be higher than 10 and even 20 seconds
  • 37. Provisioned Concurrency for Lambda Functions Vadym Kazulkin @VKazulkin , ip.labs GmbH Yan Cui: https://lumigo.io/blog/provisioned-concurrency-the-end-of-cold-starts/
  • 38. Don‘t be scared of cold starts To avoid cold starts them completely, you have to : • Overpay • Overprovision Cold starts don’t really matter if the you make the call asynchronously Vadym Kazulkin @VKazulkin , ip.labs GmbH
  • 39. Max connection limit of RDS • Max number of connections depends on the RAM of the selected RDS • for db.t3.medium 450 max connections • Solutions for not reaching the max connection limit for calling RDS from Lambda • Use NoSQL Database (DynamoDB) • Use RDS-Proxy • Use Data API for Aurora Serverless Vadym Kazulkin @VKazulkin , ip.labs GmbH
  • 40. Understand Service Quotas 1/2 • Max parallel executions of all Lambdas in each AWS Account per Region • Soft limit of 500-3000 parallel • API Gateway throttle limit • 1000 requests per second • Invocation duration & timeouts • Lambda 15min • API Gateway integration 29sec Vadym Kazulkin @VKazulkin , ip.labs GmbH James Beswick: Operating Lambda: Application design and Service Quotas https://aws.amazon.com/blogs/compute/operating-lambda-application-design-and-service-quotas-part-1/
  • 41. Understand Service Quotas 2/2 • Payload limit • API Gateway 10 Mb • Lambda 6 Mb • SQS 256 Kb • Max Memory assigned to Lambda • 10GB Vadym Kazulkin @VKazulkin , ip.labs GmbH
  • 42. 1. Application lifecycle 2. Workloads 3. Platform limitations 4. Cost at scale 5. Organizational environment 6. Platform and tooling maturity Vadym Kazulkin @VKazulkin , ip.labs GmbH
  • 43. The reality is… Lambda is often just a small percentage of your total cost Vadym Kazulkin, @VKazulkin
  • 44. $ 3.50 Per million API calls API Gateway Vadym Kazulkin, @VKazulkin
  • 45. HTTP APIs in Beta 70% cheaper as API Gateway • Fewer configuration options • Well-suited for most use-cases
  • 47. Provisioned vs On-Demand • Use On-Demand for spiky workloads • Use Provisioned for constantly high workload Vadym Kazulkin, @VKazulkin
  • 48. Understand your cost at scale • Lambda • API Gateway • Dynamo DB capacity choices • Event Sources (SQS, SNS, EventBridge, Kinesis) • Step Functions Vadym Kazulkin @VKazulkin , ip.labs GmbH
  • 49. Understand your cost at scale • Logging costs (AWS CloudWatch Logs) • Monitoring costs (AWS CloudWatch) • Tracing (AWS X-Ray) • Remote API calls / 3rd party services price models Vadym Kazulkin @VKazulkin , ip.labs GmbH
  • 50. 1. Application lifecycle 2. Workloads 3. Platform limitations 4. Cost at scale 5. Organizational environment 6. Platform and tooling maturity Vadym Kazulkin @VKazulkin , ip.labs GmbH
  • 51. Understand organizational environment (structure, reponsibilities, knowledge, culture) • Do you already embrace DevOps best practices? Vadym Kazulkin @VKazulkin , ip.labs GmbH
  • 52. Tom McLaughlin Talk: What do we do when the server goes away? • Observability (Logging, Monitoring, Tracing, & Alerting • Chaos Engineering & Game Days • Help understand constraints of AWS services & choose the right one Tom McLaughlin „What do we do when the server goes away” https://speakerdeck.com/tmclaugh/serverless-devops-what-do-we-do-when-the-server-goes-away Charity Majors „The Future of Ops Careers” https://thenewstack.io/the-future-of-ops-careers Vadym Kazulkin @VKazulkin , ip.labs GmbH
  • 53. Help understand constraints of AWS services & choose the right one. Example Event Sources: Vadym Kazulkin @VKazulkin , ip.labs GmbH
  • 54. Event Sources • SQS and SNS are charged for requests • Kinesis charges for shard hours & PUT requests Image: https://blog.binaris.com/lambda-pricing-pitfalls/ Vadym Kazulkin @VKazulkin , ip.labs GmbH
  • 55. Event Sources • Cost for Kinesis grows with slower rate • Attractive at to operate at scale Image: https://blog.binaris.com/lambda-pricing-pitfalls/ Vadym Kazulkin @VKazulkin , ip.labs GmbH
  • 57. Co-evolution of practices with Serverless 1/2 • True DevOps • Complete infrastructure automation • Chaos Engineering • FinDev responsibilities in the teams Sheen Brisals “Why the ‘WHY’ matters more than the ‘WHAT’ in Serverless!” https://medium.com/lego-engineering/why-the-why-matters-more-than-the-what-in-serverless-2ef56c397962 DevOps Topologies: https://web.devopstopologies.com/
  • 58. Co-evolution of practices with Serverless 2/2 • Each team or even developer can have its own (AWS test) account per feature or service • Only minimal local testing (quick functional tests) • Adopt “testing in production” Michael Bryzek “What do you know about testing in production?” https://www.youtube.com/watch?v=z-ATZTUgaAo
  • 59. 1. Application lifecycle 2. Workloads 3. Platform limitations 4. Cost at scale 5. Organizational environment 6. Platform and tooling maturity Vadym Kazulkin @VKazulkin , ip.labs GmbH
  • 60. Serverless platform and tooling maturity • Infrastructure-as-a-Code solutions maturity • with AWS Cloud Formation, AWS CDK • Development environment & framework maturity • with AWS SAM, AWS Amplify and Serverless Framework Image: http://tea.solgenomics.net/anatomy_viewer/microscopy/slm82_fruit Vadym Kazulkin @VKazulkin , ip.labs GmbH
  • 61. Serverless platform and tooling maturity • CI/CD • with AWS CodeCommit, CodeBuild, CodePipeline and CodeDeploy • Observability (Logging, Monitoring, Tracing, Alerting) • with AWS CloudWatch and X-Ray • Integration with 3rd party SaaS • with AWS Lambda Extensions (Epsagon, HashiCorp, Lumigo, Thundra, Datadog) • with AWS EvenBridge (PagerDuty, Zendesk, Shopify, Datadog) Image: http://tea.solgenomics.net/anatomy_viewer/microscopy/slm82_fruit AWS Lambda Extensions https://aws.amazon.com/de/about-aws/whats-new/2020/10/aws-lambda-extensions-integrate-operational-tools/ Vadym Kazulkin @VKazulkin , ip.labs GmbH