Atomic Leap
← Back to Home

Cloud FinOps & Infrastructure

Research timeline: Original engineering work conducted between 2019-2025; this document was reconstructed and published in 2026.

50% AWS Cost Reduction
21-40% Compute Cost Reduction

1. Context of the Problem (2019-2025)

As cloud architectures scaled between 2019 and 2025, cloud resource bills became one of the largest operating expenses for high-growth SaaS platforms. Statically provisioned, on-demand compute environments resulted in massive fiscal waste due to over-provisioning. While spot instances (preemptible VMs) offered up to 90% cost discounts, cloud providers can terminate them with a mere 2-minute notice. This volatile preemption made spot instances highly risky for stateful, high-throughput container workloads, threatening sudden user-facing downtime and dropped connections.

2. Evaluation of Available Options

Three primary auto-scaling and cost-mitigation strategies were evaluated:

FinOps Strategy Pros Cons Suitable Use Case
Option A: Cluster Autoscaler (Auto Scaling Groups) Standard, standard Kubernetes SIG project; well-supported. Provisioning is very slow (5-10 minutes); rigid scaling groups bound to static instance types. Predictable, slow-growing workloads with flat load profiles.
Option B: Static Over-Provisioning (On-Demand) 100% reliable; zero node termination risk; simple administration. Extremely expensive; massive resource wastage; severely inflates cloud COGS. Highly critical, non-scaling systems with zero budget constraints.
Option C: Karpenter Node-less Provisioning + Proactive Spot Termination Handlers Node scale-up in under 60 seconds; dynamic right-sizing; seamless spotVM preemption draining. Requires complex node-draining logic and Spot warning configuration. Dynamic, high-throughput SaaS containers. Chosen Option.

3. Architectural Selection Rationale

Option C was selected. Option A (traditional Cluster Autoscaler) was rejected because its slow node scale-up times (often taking up to 10 minutes to register and provision an ASG VM) caused massive scheduling delays and API SLA violations when spot instances were preempted under heavy traffic. Option B was rejected because maintaining over-provisioned on-demand compute is cost-prohibitive and directly violates basic FinOps principles.

By implementing Option C, AWS Karpenter (open-sourced by AWS in late 2021) is used for node-less infrastructure provisioning. Karpenter bypasses traditional Auto Scaling Groups (ASGs) entirely, interacting directly with the EC2 fleet APIs to provision right-sized compute nodes in under 60 seconds. This is paired with custom Spot termination metadata handlers on EKS. The handler service continuously polls the local instance metadata endpoint for termination notices, instantly cordoning the node and initiating a graceful pod eviction drain. This allows the Kubernetes scheduler to safely relocate workloads to alternative capacity-or signals Karpenter to provision replacement nodes Just-In-Time (JIT)- before the 2-minute preemption deadline is reached. To survive mass preemption cascades, workloads were strictly bifurcated: stateful/mission-critical components were pinned to persistent On-Demand nodes, while stateless microservices were offloaded to the volatile Spot fleet. Long-running asynchronous tasks implemented aggressive checkpointing and were buffered by a persistent message queue, ensuring any work interrupted by node termination was instantly requeued and resumed.

# Karpenter AWS NodePool Manifest showing spot instance and node-less scaling rules apiVersion: karpenter.sh/v1beta1 kind: NodePool metadata: name: spot-optimized-pool spec: template: spec: requirements: - key: "karpenter.sh/capacity-type" operator: In values: ["spot"] - key: "kubernetes.io/arch" operator: In values: ["amd64", "arm64"] disruption: consolidationPolicy: WhenUnderutilized expireAfter: 720h

4. Stress-Testing, Chaos Injection & Telemetry

Following a strict Chaos Engineering methodology, the FinOps cluster was validated by triggering artificial AWS spot preemption events (Chaos Monkeys) across 100% of active compute node groups under peak simulated traffic loads to expose and patch eviction failures. Resource scanners analyzed CPU and memory utilization trends to identify and eliminate waste. Telemetry results verified:

5. Limitations

While the proposed spot-optimized architecture achieves substantial cost savings, several operational limitations must be accounted for:

6. Architectural Conclusions

This architecture case study demonstrates that cloud waste is a solvable architectural problem, not an inevitable cost of doing business. By coupling dynamic Spot VM orchestration with proactive termination handlers, organizations can leverage highly discounted preemptible compute with the exact same reliability as expensive, on-demand infrastructure. Treating cloud economics as an automated SRE feedback loop unlocks massive, recurring infrastructure savings without sacrificing system performance or uptime reliability.