Wait until all Future.onComplete callbacks are executed
问题 I am using the Future API from Scala 2.10.X. Here is my use case: object Class1 { def apply(f: (Int) => Future[String])(i: Int): Future[String] = { val start = DateTime.now val result = f(i) result.onComplete{ case _ => println("Started at " + start + ", ended at " + DateTime.now) } result } } Pretty simple I think: I'm adding an onComplete callback to my future. Now, I'm wondering if there is a way to add a callback for when the onComplete is done executing - in this example know when the