You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository has been archived by the owner on Jul 18, 2024. It is now read-only.
From CompletionStage javadoc, toCompletableFuture is optional.
* A CompletionStage
* implementation that does not choose to interoperate with others
* may throw {@code UnsupportedOperationException}.
*
* @return the CompletableFuture
* @throws UnsupportedOperationException if this implementation
* does not interoperate with CompletableFuture
Just a rant, toCompletableFuture is so stupid.
Because it exists, CompletionStage isn't actually read only since CompletableFuture.toCompletableFuture returns this (and worse than a user completing a stage, the user can also use obtrude*). But because it's optional you can't depend on it for what little use it actually did have (interop).
The text was updated successfully, but these errors were encountered:
Hm, apparently, in the Java9 javadoc they made toCompletableFuture mandatory
/**
* Returns a {@link CompletableFuture} maintaining the same
* completion properties as this stage. If this stage is already a
* CompletableFuture, this method may return this stage itself.
* Otherwise, invocation of this method may be equivalent in
* effect to {@code thenApply(x -> x)}, but returning an instance
* of type {@code CompletableFuture}.
*
* @return the CompletableFuture
*/
is that grounds to close this issue, even though this is a Java 8 library?
wow i never thought about the repercussions of obtrude. that sucks too...
I think that in principle we need to consider java 8 as our foundation, and largely ignore java 9 (except for substantial and heavily related changes like the Flow API). That means we can't rely on toCompletableFuture, and for Combinators i think that means increasing MAX_DEPENDANT_DEPTH and then going with one of our previous convoluted combine implementations when exceeding that depth
Porting issue 36 from the enterprise repo
rkhadiwa commented on Nov 29, 2017
From CompletionStage javadoc, toCompletableFuture is optional.
Just a rant,
toCompletableFuture
is so stupid.Because it exists,
CompletionStage
isn't actually read only sinceCompletableFuture.toCompletableFuture
returnsthis
(and worse than a user completing a stage, the user can also useobtrude*
). But because it's optional you can't depend on it for what little use it actually did have (interop).The text was updated successfully, but these errors were encountered: