--
You received this message because you are subscribed to the Google Groups "scala-user" group.
To unsubscribe from this group and stop receiving emails from it, send an email to scala-user+...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
None of the original code blocks because you get the callback asynchronously, which depending on what you are looking at may or may not be what you want.
You can go about blocking for the future returned if that is more the plan in which case the final line would be replaced with this:
val theResultingNumbers = Await.result(futNumbers, 10 seconds)
TheResultingNumbers would be a List[Int] which is the result of the future executions.
The duration could potentially be Duration.inf if you don't know how long it blocks for but that has dangers as well if they might not complete.
PK