2
votes

I have high video encoding tasks running inside pods. These tasks run on getting requests from users and are very high CPU intensive. I want to make sure that the pod with the least CPU usage should receive in the incoming requests. Is there a way in Kubernetes to balance my load based on the percentage of CPU usage?

1

1 Answers

0
votes

AFAIK there is not such a thing available currently in Kubernetes. The only idea that comes to my mind is a custom solution with application designed in way that once it detects that it reaches the maximum cpu threshold it will fail the readiness probe. This will inform Kubernetes to to remove temporary the pod from the endpoints and allow you to direct request to the another pod. With the readiness probe failed Kubernetes will still keep already existing connections.