windows: fix inefficient gathering of task processes (#20619)

* windows: fix inefficient gathering of task processes

* return set of just executor pid in case of ps error
This commit is contained in:
Seth Hoenig
2024-05-17 09:46:23 -05:00
committed by GitHub
parent a6f6384b71
commit 7d00a494d9
8 changed files with 185 additions and 6 deletions

View File

@@ -102,7 +102,7 @@ func (e *UniversalExecutor) setSubCmdCgroup(cmd *exec.Cmd, cgroup string) (func(
}
}
func (e *UniversalExecutor) ListProcesses() *set.Set[procstats.ProcessID] {
func (e *UniversalExecutor) ListProcesses() set.Collection[procstats.ProcessID] {
return procstats.List(e.command)
}