practo/k8s-worker-pod-autoscaler

Scale up logic doesn't work well for long-running tasks

justjkk opened this issue · 0 comments

Consider a scenario where TargetJobsPerPod is set to 1. When the first job comes, it scales up from 0 to 1 pod. When the first job is still being processed and a second job comes into the queue, it doesn't scale up to 2 pods. This is because only the jobs visible are used to calculate the usage ratio. I think we should use both jobs visible and jobs currently being processed to calculate the desired workers.