Resource Requests and Limits

Two pods land on the same node: a Prometheus exporter doing a 30-second scrape cycle and a gRPC API with 10ms latency targets. No resource constraints. For the first 25 seconds of each minute, everything looks fine. Then the scraper wakes up, saturates the shared CPU, and your API's p99 crosses 200ms. The scheduler had no signal that these workloads should not compete.
Resource requests tell the scheduler what a pod needs to land. Resource limits tell the kubelet what a container is allowed to consume once it's running. Most engineers set them together, copy them from documentation, and move on. That works until it doesn't. CoreDNS ships with a memory limit and no CPU limit. Prometheus ships with a memory request and nothing else. These aren't oversights; they're deliberate choices based on how CPU throttling and memory OOM killing actually work.
Sign in to access this lesson
Create a free account or sign in to enroll in the CKAD — Certified Kubernetes Application Developer course and access all 44 lessons.
CKAD — Certified Kubernetes Application Developer
44 lessons