The CompleteableFuture<T> class received the following enhancements as part of the Java 9 platform:
- Added time-based enhancements:
- This enables completions based on lapsed time
- Delayed executions are now also supported
- Significant enhancement to subclasses:
- Extending CompletableFuture is easier
- Subclasses support alternative default executors
Specifically, the following methods were added in Java 9:
- newIncompleteFuture()
- defaultExecutor()
- copy()
- minimalCompletionStage()
- completeAsync()
- orTimeout()
- completeOnTimeout()
- delayedExecutor()
- completedStage()
- failedFuture()
- failedStage()