viirya commented on code in PR #38943: URL: https://github.com/apache/spark/pull/38943#discussion_r1041330497
########## resource-managers/kubernetes/core/src/main/scala/org/apache/spark/scheduler/cluster/k8s/ExecutorPodsAllocator.scala: ########## @@ -398,6 +410,10 @@ class ExecutorPodsAllocator( // Check reusable PVCs for this executor allocation batch val reusablePVCs = getReusablePVCs(applicationId, pvcsInUse) for ( _ <- 0 until numExecutorsToAllocate) { + if (reusablePVCs.isEmpty && reusePVC && maxPVCs <= PVC_COUNTER.get()) { Review Comment: Is `reusablePVCs` always less than or equal to `maxPVCs`? -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: reviews-unsubscr...@spark.apache.org For queries about this service, please contact Infrastructure at: us...@infra.apache.org --------------------------------------------------------------------- To unsubscribe, e-mail: reviews-unsubscr...@spark.apache.org For additional commands, e-mail: reviews-h...@spark.apache.org