|
|
|
|
|
by runT1ME
4412 days ago
|
|
Seriously, just use scala Futures. Here's one of many super easy ways to do parallel computations in scala:
val list = getItemsToProcess() //List[SomeObj]
list.map(so => Future { processorHeavyMethod(obj) }) //happening in parallel now
val finished = Future.sequence(list) //Future[List]
finished.await |
|