[External] : Re: Future.resultNow / exceptionNow

Ron Pressler ron.pressler at oracle.com
Mon Nov 22 11:06:06 UTC 2021

> On 21 Nov 2021, at 21:27, Alex Otenko <oleksandr.otenko at gmail.com> wrote:
> I view it the other way around. Since it is guarding resultNow, should preclude all failures, which means FAILED or CANCELLED (we already know it is not RUNNING).

The only thing that can guard resultNow is `if (f.state() == State.SUCCESS)`, but you’ve taken this discussion to the issue of polling futures. Let’s get back to StructuredExecutor, which should not require polling the future or guarding resultNow except in the special cases I mentioned.

— Ron

More information about the loom-dev mailing list