users@javaee-spec.java.net

[javaee-spec users] Re: CompletableFuture Usage in the Platfom vs CDI

From: Reza Rahman <reza_rahman_at_lycos.com>
Date: Tue, 8 Mar 2016 07:57:54 -0500

Many thanks for chiming in. I hope a few more involved folks do as well. Trying to avoid these mistakes is one of the most important reasons folks like us are here in the end.

> On Mar 8, 2016, at 7:41 AM, Josh Juneau <juneau001_at_gmail.com> wrote:
>
> Reza-
>
> I am in agreement with you. I agree that CompleteableFuture seems to make more sense for asynchronous events than CompletionStage. Given that it is widely acceptable throughout the platform, and the naming aligns more closely with asynchronous activity...I think CompleteableFuture would be a more consistent and standardized choice.
>
> Thanks
>
> Josh Juneau
> juneau001_at_gmail.com
> http://jj-blogger.blogspot.com
> https://www.apress.com/index.php/author/author/view/id/1866
>
>
>> On Mon, Mar 7, 2016 at 6:40 PM, Reza Rahman <reza_rahman_at_lycos.com> wrote:
>> The CDI EG is incorporating the concept of CompletableFuture into asynchronous events. Unfortunately for reasons I really don't see as good they are using it's superinterface CompletionStage instead of CompletableFuture.
>>
>> I think this is a big ease-of-use mistake as CompletableFuture is designed to be the end user high level gateway API while CompletionStage is mostly as SPI intended for framework writers.
>>
>> Given that the CompletableFuture concept is pretty widely applicable throughout the platform I think there is a need for consistency, oversight and guidance from the platform expert group. Otherwise I fear less than ideal ad-hoc decisions might be made in this case for CDI and possibly others down the line.
>>
>> What do you think?
>