L10 - FaaS Flashcards
severless meaing
application owners do not have to worry about the underlying execution infrastructure, mostl importantly physical or virtual servers.
What is often used as a synonym for FaaS?
Serverless computing
A serverless computing platform may provide one or both of the following
- Function-as-a-Service (FaaS)
- Backend-as-a-Service (Baas)
What is FaaS?
Function-as-a-Service
Typically provides event-driven computing. Developers run and manage application code with functions that are triggered by events or HTTP requests. Developers deploy small units of code the FaaS, which are executed as needed as discrete actions, scaling without the need to manage servers or any other underlying infrastructure.
What is BaaS?
Backend-as-a-Service are third-party API-based services that replace core subsets of functionality in an application. Because those APIs are provided as a service that auto-scales and operates transparently, this appears to the developer to be serverless.
CNCF
Cloud native computing forum
Pros of FaaS
- no provisioning of servers
- automatic scaling
- reduction of costs. Do not pay for idle VMs and do not run replicas for resilience
- underlying servers shared among different function invocations.
Cons of FaaS
- focused on stateless functions (if function should store something then an external storage is needed)
- performance variation due to restart latencies
- not suited for heavy computation workload, own VMs might be cheaper
- limited security: shared VMs, no control over the network
Amazon Lambda
- first serverless offering by a public cloud provider
- designed for:
- image or object uploads to Amazon S3
- updates to DynomoDB tables
- responding to website clicks
- reacting to sensor readings from an IoT connected device
Lambda functions
Anonymous functions in functional programming:
- not bound to an identifier (no function name)
- often used as arguments being passed to higher-order functions
- used in node.js applications
In which programming languages for example can you use Lambda functions?
Node.js
Python
Java
C#
4 advantages of using Amazon Lambda
- Bring your own code
- Simple resource model (select power rating up to 3Gb and CPU and network are allocated automatically)
- Flexible use (integrated with other AWS services)
- Flexible authorization
3 Lambda execution models
- Synchronous (push)
- Asynchronous (event)
- Stream-based
What is Amazon Cognito?
For user management
- secure user sign-up, sign-in, and access control
- supports integration with social and enterprise identity services
- you have a user pool and application id
What is OpenWhisk?
What is Apache OpenWhisk?
Apache OpenWhisk is an open source, distributed Serverless platform that executes functions (fx) in response to events at any scale. OpenWhisk manages the infrastructure, servers and scaling using Docker containers so you can focus on building amazing and efficient applications.