What happens if container exceeds cpu requested but under limit on kubernetes?

10/2/2021

In kubernetes we can set limits and requests for cpu. If the container exceeds the limit, from my understanding it will be throttled. However if the container exceeds the requested but is still under the limit what would happen?

Would I see performance issues on my application?

-- user2962698
cpu-usage
google-kubernetes-engine
kubernetes
sre

2 Answers

10/2/2021

There won't be any issue if the CPU going above the requested and staying under the limit.

however I have seen, if your application requires 250m of CPU and your requested CPU is 50m you might see the performance issues.

-- Harsh Manvar
Source: StackOverflow

10/2/2021

However if the container exceeds the requested but is still under the limit what would happen?

Nothing happens. The resource request is used for scheduling your pod to a node with capacity.

If the resources are scarce on your node, it may be evicted.

-- Jonas
Source: StackOverflow