Cloud Scaling
HS Tools in AWS
Application Load Balancer (smarter) routes to multiple EC2 instances looks inside request and assigns based on rules/roles path and host based routing Network LB (simplest, least expensive) routes based on low-level network distributes based on availability, not looking into request scales millions in seconds
ALB components
Load Balancer: entry point for request/action Listener: use rules to map requests to services in target groups Target Group: contains multiple EC2 instances
EC2 Bursting good idea when?
The MCOB SQL.business.nd.edu: Is burstable Sits idle most of the time, but then during class and before assignments it is much higher demand The credits of "use" and "compute" are collected overnight and then are used during peak hours, so that we buy a much smaller server than we would need for peak time
vertical scaling
add more resources to a machine to accomplish add'l work
horizontal scaling details
add resources at the same layer of a system, need a load balancer may need application reconfiguration may need software changes generally less expensive
scalability
adding/removing resources to a system to accommodate changes in demand
scaling lab
create a new instance in a different AZ create an application load balancer to distribute requests across the two servers create auto scaling group with minimum of 1 servers reasons not to use auto scaling: different regions not possible, really quick but not lasting for more than a few minutes, intricate launch config diff. b/w auto scaling and LB
horizontal scaling
distribute add'l work across additional machines
vertical scaling in AWS
identify bottleneck, identify new instance type, shut down server, select new type, start server
vertical constraints
memory, CPU, storage, network --> determine root cause to address in the scaling
reasons to scale vertically
monolithic applications legacy software no code change needed easy
downsides
need to turn off to scale designed for peak, so there are times you have too high, but need an outage to scale down
Autoscaling
scale programmatically identify scaling thresholds based on resource utilization monitor usage based on defined thresholds trigger scaling up/down when appropriate can have min # for config, so if failure, knows to start another back up right away
Bursting
vertical scaling on small scale w/o downtime bursts CPU only, not memory Limited to T3, T3a, and T2 types