-
Notifications
You must be signed in to change notification settings - Fork 1.9k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add support for CompletableFuture
for method return types
#638
Conversation
There are few things that will help make this PR ready for review. Please see CONTRIBUTING for more information. Also, this does appear to push Java version up. In the past we have tried not to do this, for various reasons. Take a look at HACKING for more tips. If this feature gets enough support, it may be better of in a new |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I've spent a little more time researching this. Hystrix does not support CompleteableFuture
internally. Your implementation uses a common workaround, by turning the future into an Observable
. It is my opinion that until Hystrix supports this directly, we consider this a JDK8 only update and move it to the jdk8
module, separating it from Hystrix entirely.
.editorconfig
Outdated
@@ -0,0 +1,14 @@ | |||
# top-most EditorConfig file |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'm not sure we should be including editor configuration files this way.
|
||
import java.util.concurrent.CompletableFuture; | ||
|
||
@IgnoreJRERequirement |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Personally, I don't like this kind of thing. If this code requires JDK8, then it should be in the jdk8
module.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Is there any strong reason for our current java 6 constraint?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It is my understanding, from reading previous comments and documentation from @adriancole, it is the opinion of this project that core feign
should remain JDK 6+ and that all JDK 8 features are in the feign-java8
module. This PR will require core feign
to move to JDK 8, which has been called out in other PR and issues before as something we should try to avoid.
Personally, I do not have a strong opinion on this. My questions and thoughts are an attempt to stay consistent. I am open to having a discussion with the other contributors to see if we should revisit this decision.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I change to jdk 8 baseline should require a major revision (ie 10.x)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
change to jdk 8 baseline should require a major revision (ie 10.x)
LGTM =)
@wjam Master is now Java 8, if you still want this PR to move forward, can you take a look and see if you can apply it to the new baseline? |
Implements support for `CompletableFuture` on method return types by converting through RxJava `Observable`
@wjam This PR limits support to |
Implements support for `CompletableFuture` on method return types by converting through RxJava `Observable`
Implements support for `CompletableFuture` on method return types by converting through RxJava `Observable`
Implements support for
CompletableFuture
on method return types by converting through RxJavaObservable