Scaling Architecture Flashcards
Describe the features of Horizontal Scaling
- Add more instances as demand increases
- No downtime required to scale in/out
- Automatic using ASG’s
- Theoretically unlimited
Describe the features of Vertical Scaling
- Add more CPU/Mem to existing instances
- Requires restart to scale
- Requires scripting to automate
- Limited by instance size
Describe EC2 Auto-Scaling
Focused on EC2 instances, uses scaling groups and health checks to manage
Describe App Auto-Scaling
For scaling resources other than EC2 (dynamodb, ECS, EMR, etc).
Describe AWS Auto-scaling
Centralised way to manage EC2 and App Autoscaling features
Describe the 3 Scaling Policies
Target Tracking - Scale based on set metrics (eg: scale if EC2’s are above 70% CPU usage
Simple Scaling - Wait til health check and cooldown periods expire before evaluating need for scaling (eg: increase spot fleet by 20% per 10K connections to the ELB)
Step Scaling - Scale with advanced logic
Describe Scaling cooldown
Giving resources x time to get ready and absorb load before health checks apply. Auto applies to dynamic scaling, optional for Manual scaling. Defaults to 300sec
Describe Kinesis Data Streams
Stream information between client devices and app servers/services (think EC2, Lambda, Data Analytics tools, etc)
Describe Kinesis Firehose
A data transfer service for sending data to storage services like S3, Elasticache, RDS, etc
Describe Kinesis Shards and Records
A Shard is a individual package of data Records that Kinesis streams. Records each contain a Partition Key, Sequence Number, and Data Blob. Each Shard can ingest 1K records/sec.
How does DynamoDB Scaling work
DynamoDB scales using partitions. Each scaling level adds a new Partition. Partitions can handle either 1000 Read Capacity Units RCU’s, or Write capacity Units WCU’s, each has 10GB of storage. Scaling occures when certain RCU or WCU limits are reached. Autoscaling is cheaper but harder to implement. On-demand scaling is more expensive.
Does Cloudfront support Static or Dynamic content
It supports both
Describe Standard vs FIFO Queues/Topics
Used in SQS and SNS. Standard is suitable if the order of messages doesn’t matter, and the app receiving the message can handle duplicates. FIFO ensures that messages are delivered in the order they’re received, and only sent once, which prevents duplicate message recipes.
What’s the difference between SNS and SQS
SNS sends out messages, clients subscribe to a topic. SQS holds messages, clients request messages from a queue.
What languages does LAMBDA support
Java, Go, PowerShell, Node. js, C#, Python, and Ruby