3. Agenda
● High Level Software Design
Architectures
● Transition To
Containerization
● Serverless Computing
● Baas And FaaS
● Serverless Computing
Drawbacks
● Example AWS Lambda
4. Expectation
● High Level Introduction to
Serverless Architecture
● Basic Understanding of
Containerization
● Not an AWS training
● Direction to Explore More :)
13. Serverless : Literally No Dedicated Servers
● Every logic will be in the form on functions
● Code will be on cloud
● No dedicated infrastructure in the beginning
● Providers like AWS, Azure, Google Cloud have different naming
conventions.
AWS - Lambda
Google Cloud - Google Functions
Azure - Azure Functions
14. Serverless : How it works ?
● Infrastructure will be set up and made available on very first request,
event etc.
● Once processing is completed, entire infrastructure will be destroyed.
● No idle time for servers and resources.
● More Precisely : When request comes a container is initialized to execute
the code along with infrastructure and destroyed after request
completion. So a separate container per request.
15. Serverless : Combination of BaaS and FaaS
BaaS : Backend As a Service
Many third-party services that implement required functionality, provide server-side logic and manage their internal states,
which led to applications that do not have application-specific, server-side logic and use third-party services for everything.
Such applications are serverless and using entire Backend as a Service.
Examples of third-party services include identity and authentication as a service (Auth0, AWS Cognito), logging as a service
(Loggly, Logsense, Amazon Elasticsearch Service) and analytics as a service (Amazon Kinesis, Keen IO).
FaaS : Function As a Service
When an application requires specific server-side logic, FaaS can be used, FaaS are short-living stateless functions that
can be triggered by events and can communicate with each other and even provide APIs to external world.
A FaaS provider does the rest—provisioning as many instances of such functions as necessary to handle all of the
requests, Terminate instances that are no longer required, Monitor all of them and provide identity and logging services.
Eg. Auth0 Webtask, AWS Lambda, Google Cloud Functions and Azure Functions
17. Serverless : Benefits and Challenges
Benefits :
● Low operational cost
● Scaling is efficient - Auto scaling
● Less packaging and deployment
complexity
● Less developer required
● Self managed infrastructure
● Develop and Market prototype in less or
no time.
Challenges :
● Vendor Lock-in and Vendor Control
● Security concerns
● Code logic repetition on multiple client
platforms in case of full BaaS
● No control on server optimization
● No state for serverless FaaS
● DoS Problem
● Lambda Execution duration > 5 min
->Abort
● Startup Latency - > AWS claims it is less
than 30ms
● Testing and Debugging -> Only unit
testing can be done efficiently. For
others WIP
18. Serverless : Example Using AWS Lambda
But where is the example ??
Let’s go realtime.