Future.resultNow / exceptionNow

Alex Otenko oleksandr.otenko at gmail.com
Sat Nov 20 16:43:47 UTC 2021


Is there a strong opinion about Future.resultNow and exceptionNow throwing
IllegalStateException? It seems there will likely be boilerplate
try-catching, as there is no safe way to inquire in what way the Future is
isDone.

Returning Optional seems a nicer alternative.

Alex


More information about the loom-dev mailing list