feign
feign copied to clipboard
ApacheHttpClient - enable/disable follow redirect via Request.Options
Hi there.
With spring-cloud-openfeign, it is possible to specify feign configuration by client with :
feign:
client:
config:
feignName:
connectTimeout: 1000
follow-redirects: false
But when using the ApacheHttpClient, the property follow-redirects is ignored (whereas connectTimeout is ok)
I think it could be achieve by adding :
.setRedirectsEnabled(options.isFollowRedirects())
line 95 of ApacheHttpClient
line 95 of ApacheHttpClient
feel free to open a pull request. Please include tests.
https://github.com/OpenFeign/feign/pull/1861