Safety-Gated Autoscaling: A Multi-Layered Defense Architecture for Kubernetes Vertical Resource Optimization
Abstract
Kubernetes is the standard platform for orchestrating containerized applications, yet resource management remains difficult. To stay safe, engineers over-provision CPU and memory, leaving reserved but unused capacity that is the main source of wasted cost. The built-in Horizontal and Vertical Pod Autoscalers are reactive: they act only after a threshold is crossed, which causes lag, over-provisioning, and can mask software defects by granting a leaking workload more memory. Predictive autoscalers focus on improving forecasting accuracy or run inside proprietary infrastructure, and anomaly detection is used only to alert, never to block a harmful action. The Intelligent Cluster Optimizer is an open-source Kubernetes operator that right-sizes container workloads with safety as a first-class concern. Its central contribution is a five-layer safety pipeline where a memory-leak detector, based on linear regression with R2 scoring, acts as a blocking gate: if a leak is detected the recommendation is rejected, so the optimizer never hides a bug by enlarging a broken container. The pipeline combines SLA monitoring, a circuit breaker, HPA/PDB conflict detection, and a policy engine, with rollback and dry-run mode for human approval. Recommendations are produced by percentile analysis and Holt-Winters forecasting, balanced through multi-objective Pareto optimization at the per-container level. We validated the system with 1118 automated tests at 80.3% coverage and a live deployment on Google Kubernetes Engine, where right-sizing produced estimated cost savings of 20--40% in what-if projections and the leak gate reached 83% detection accuracy.
Create a lesson
Metadata
- Comments
- 10 pages
Related papers
Provenance-Isolated Epistemic Quorums: Execution-Bound Evidence Certification and Plausible-World Safety Gating in Agentic Control Planes
Shared title terminologycs.DCJun He, Deying Yu
ScaleBench: An Extensible and Reproducible Experimental Platform for Kubernetes Autoscaling Research
Shared title terminologycs.DCZe Wang, Sajid Alam, Amjad Ullah
A Resource-centric Analysis and Optimization of NoSQL Workloads using Distressed Resource Volume Metric
Shared title terminologycs.DCGunika Verma, Aashutosh A, Pooja Srinivas et al.
OpRAG: A Resource-Deterministic Runtime for GPU-Backed Multi-Stage RAG Workflows
Shared title terminologycs.DCArup Kumar Sarker, Mills Staylor, Aymen Alsaadi et al.
Multi-tenant Kubernetes Use Cases for AI, Secure Computing and Data Services, and More
Shared title terminologycs.DCJake Watson, Sadaf R Alam, Christopher Woods et al.
QCOEM: Quantum Cloud Orchestration with Evolutionary Multi-Objective Optimization
Shared title terminologycs.DCTam N. Pham, Hoa T. Nguyen, Quan Le-Trung