[concurrency-interest] More Javadoc problems

cowwoc cowwoc at bbs.darktech.org
Fri Dec 19 09:00:36 EST 2014


Hi guys,

The Javadoc for CompletableFuture.whenComplete() reads:

"If the supplied action itself encounters an exception, then the returned
stage exceptionally completes with this exception unless this stage also
completed exceptionally."

Huh?!

So if the original stage completed with exception1 but the handler threw
exception2, which exception does the returned CompleteableFuture complete
with? The specification says what *won't* happen if the stage also completed
exceptionally, but it doesn't say what *will* happen. Please clarify :)

Thanks,
Gili



--
View this message in context: http://jsr166-concurrency.10961.n7.nabble.com/More-Javadoc-problems-tp11669.html
Sent from the JSR166 Concurrency mailing list archive at Nabble.com.


More information about the Concurrency-interest mailing list