Signals that the current thread of execution will potentially engage an action that will take a non-trivial amount of time, perhaps by using blocking.
Signals that the current thread of execution will potentially engage an action that will take a non-trivial amount of time, perhaps by using blocking.IO or using a lot of CPU time, giving the system a chance to spawn new threads, reuse old threads or otherwise, to prevent starvation and/or unfairness.
Assures that any Future tasks initiated in the current thread will be executed asynchronously, including any tasks currently queued to be executed in the current thread. This is needed if the current task may block, causing delays in executing the remaining tasks which in some cases may cause a deadlock.
Usage: Call this method in a callback (map, flatMap etc also count) to a Future, if you will be doing blocking in the callback.
Note: Calling 'Await.result(future)' or 'Await.ready(future)' will automatically trigger this method.
Java API, creates an already completed Promise with the specified exception
Java API.
Java API. Returns a Future that will hold the optional result of the first Future with a result that matches the predicate
Java API.
Java API. Returns a Future to the result of the first future in the list that is completed
Java API A non-blocking fold over the specified futures, with the start value of the given zero.
Java API A non-blocking fold over the specified futures, with the start value of the given zero. The fold is performed on the thread where the last future is completed, the result will be the first failure of any of the futures, or any failure in the actual fold, or the result of the fold.
Java API, equivalent to Future.
Java API, equivalent to Future.apply
Java API, equivalent to Promise.
Java API, equivalent to Promise.apply
Java API.
Java API. Reduces the results of the supplied futures and binary function.
Java API.
Java API. Simple version of Future.traverse. Transforms a JIterable[Future[A]] into a Future[JIterable[A]]. Useful for reducing many Futures into a single Future.
Java API, Creates an already completed Promise with the specified result
Java API.
Java API. Transforms a JIterable[A] into a Future[JIterable[B]] using the provided Function A ⇒ Future[B]. This is useful for performing a parallel map. For example, to apply a function to all items of a list in parallel.
Futures is the Java API for Futures and Promises