Compute is usually the biggest line on the AWS bill. It’s also the part nobody designs on purpose. Someone picks an x86 On-Demand instance during the first sprint, sizes it “with some headroom,” and that choice quietly sticks around for 2 years.
You can’t fix that from the billing dashboard. Cost is decided much earlier:
instance family you pick.
how you buy capacity.
how your load balancer behaves when a node disappears.
where your current containers keep their data.
The above four things decide compute spend and system resilience. This post walks through each one and ends with a working AWS CDK stack that puts it all together.
Pick the hardware for the bottleneck you actually have.
AWS names instances like m5.2xlarge, where m is the class, 5 is the generation, and 2xlarge is the size . Class is the part that matters most, because it sets the ratio of vCPU to memory.
General purpose (M, T) : about 1 vCPU to 4GiB. Web servers, internal tools, mixed workloads.
Compute optimized (C) : about 1:2.…