Serverless Flashcards
Lambda
global
compute service; allows you to upload your code and create a lambda function
takes care of provisioning and managing the servers that you use to run the code
traditional vs serverless architecture
API gateway is frontend for serverless requests
usually a loadbalancer is the frontend for traditional
lambda language support
node.js java ptyhon c# go powershell
Serverless services
Aurora
DynamoDB
API Gateway
AWS X-ray
X-ray allows you to debug what happens with Lambda
Lambda triggers
Alexa skill Cognito IoT rule SNS Kinesis SQS S3 DynamoDB EventBridge CloudWatch API Gateway
SAM - acronym
serverless application model
SAM - definition
CloudFormation extension
framework that allows you to build serverless apps easily
can run serverless applications locally
can package and deploy with CodeDeploy
SAM types
functions
APIs
tables
ECS - acronym
elastic container service
ECS - definition
managed container orchestration service to allow you to run/scale containerized apps
ECS manages EC2 or Fargate instances
Creates clusters to manage fleets of container deployments
defines rules for CPU and memroy reqs
monitors resource utilization
FREE
Integration with: VPC, sec groups, EBS, ELB, Cloudwatch, CloudTrail
containerized application
package that contains an app, libraries, runtime, and tools required to run it
bundle that contains an app and all it’s dependencies
provides isolation benefits of virtualization w/ less overhead and faster starts than VMs
portable
runs on container engine (like Docker)
ECS components
Cluster - logical collection of ECS resources
Task definition - defines application. Can contain multiple containers
Container definition - inside task def. Defines individual containers a task uses; controls CPU/RAM allocation
Task - single running copy of any container defined by task def
Service - allows task defs to be scaled by adding tasks; defines min and max values
Registry - repository for container images. Used to download images to create containers
Fargate
serverless container engine
eliminates need to create/manage resource
Works with ECS and EKS(elastic kubernetes service)
Each workload runs in its own kernel
EC2 vs Fargate
Choose EC2 if:
- Compliance reqs
- Require broader customization
- Require GPU