This may be a silly question but I'm curious to know the answer:
If I am running a Kubernetes cluster on AWS (EKS) which autoscaling policy will take precedence? The auto scaling policy on the load balancer or the policy within the pods themselves?
This may be a silly question but I'm curious to know the answer:
If I am running a Kubernetes cluster on AWS (EKS) which autoscaling policy will take precedence? The auto scaling policy on the load balancer or the policy within the pods themselves?
The k8s cluster autoscaler does not scale worker nodes based on memory / cpu. It scales up when pods are not scheduled due to insufficient memory / cpu. Pod autoscaling can be configured to scale up when memory / cpu usage crosses a certain threshold.
So in a workflow involving a pod autoscaler like horizontal pod autoscaler and a node autoscaler like k8s cluster autoscaler, the below happens
Load on services increases -> Pod memory / cpu threshold crossed -> Pod autoscales -> Pod scheduling paused due to insufficient memory / cpu on worker nodes -> Node autoscales -> Pod scheduled on new node.
If your question is about any other node autoscaling strategy which involves memory / cpu based autoscaling, then the answer on what autoscales first will be different. Please provide the specific use case if any.