Suppose I need to perform several parallel tasks in Scala. Each task makes a blocking call (for example, Process.waitFor ). Now I would like to wait until one of the tasks is completed.
As I understand it, I have to use Scala Future to transfer the task. Is there any API in Scala to wait for any of the given Futures ?
source share