abhishekagarwal87 commented on code in PR #14030:
URL: https://github.com/apache/druid/pull/14030#discussion_r1158002223


##########
extensions-contrib/kubernetes-overlord-extensions/src/main/java/org/apache/druid/k8s/overlord/KubernetesTaskRunner.java:
##########
@@ -425,7 +425,9 @@ public void registerListener(TaskRunnerListener listener, 
Executor executor)
   public Collection<TaskRunnerWorkItem> getRunningTasks()
   {
     List<TaskRunnerWorkItem> result = new ArrayList<>();
-    for (Pod existingTask : 
client.listPeonPods(Sets.newHashSet(PeonPhase.RUNNING))) {
+    for (Job existingTask : client.listAllPeonJobs().stream()
+        .filter(job -> job.getStatus() != null && job.getStatus().getActive() 
!= null && job.getStatus().getActive() > 0).collect(Collectors.toSet())

Review Comment:
   Good idea. 



-- 
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: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to