-
Notifications
You must be signed in to change notification settings - Fork 810
Add FeignClientBuilder.Builder#customize(FeignBuilderCustomizer) (#499) #515
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 FeignClientBuilder.Builder#customize(FeignBuilderCustomizer) (#499) #515
Conversation
context.close(); | ||
} | ||
|
||
@Test |
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.
copied from above, diff 83, 84, 88, 90
ReflectionUtils.makeAccessible(factoryBeanField); | ||
final FeignClientFactoryBean factoryBean = (FeignClientFactoryBean) ReflectionUtils.getField(factoryBeanField, | ||
builder); | ||
builder); |
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.
using IDEA style from spring-cloud-build-tools
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.
@Sam-Kruglov Thanks for submitting the PR. In general, it looks good. There are a few minor issues to address - please take a look at the comments. Also, please add your full name with @author
tags to the javadocs of the classes you've changed. Apart from this, since this is not backwards incompatible, I'm thinking it would make sense to add it to the 2.2.x
branch instead of master
, so that it's available in the Hoxton
release train as well (the easiest way of doing that would probably be to cherry-pick the commits against 2.2.x
and create a new branch and PR).
|
||
private boolean followRedirects = new Request.Options().isFollowRedirects(); | ||
|
||
private List<FeignBuilderCustomizer> additionalCustomizers = new LinkedList<>(); |
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.
Why have you chosen LinkedList
?
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.
Because we don't really need the indices here, but ok, I'll put array instead to keep things consistent.
} | ||
|
||
/** | ||
* @param customizer applied in the same order as supplied here |
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.
Please add a description line on top of the javadoc and the @return
tag.
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 think this is self-explanatory but sure
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 meant sth more like the {@link Builder} with the customizer added
rather than just this
.
3c71c48
to
85b724c
Compare
rerouted to 2.2.x |
85b724c
to
7ada18f
Compare
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.
@Sam-Kruglov Thanks for adding the changes - just one small change to be made and it will be good to merge.
} | ||
|
||
/** | ||
* @param customizer applied in the same order as supplied here |
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 meant sth more like the {@link Builder} with the customizer added
rather than just this
.
7ada18f
to
ebc3f58
Compare
Fixes gh-499 |
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.
LGTM.
fixes #499