关于重定向那些事(Java 使用http client 调用带有Redirect 的坑)_dsjtlmy的博客-优快云博客项目中使用 Feign 调用 HTTP API 时,出现一个错误:HttpRetryException: cannot retry due to redirection, in streaming modefeign.RetryableException: cannot retry due to redirection, in streaming mode executing POST &l...https://blog.youkuaiyun.com/dsjtlmy/article/details/83382001Okhttp重定向处理 - 简书
HttpClient 禁止自动重定向
httpclient = HttpClients.custom().setDefaultRequestConfig(RequestConfig.custom().setRedirectsEnabled(false).build()).build();