[collector]feature:enable auto redirect when 301 302 http code (#69)

This commit is contained in:
tomsun28
2022-04-06 08:16:56 +08:00
committed by GitHub
parent ce528808c7
commit 709d51d4d5

View File

@@ -108,8 +108,8 @@ public class CommonHttpClient {
.setConnectTimeout(CONNECT_TIMEOUT) .setConnectTimeout(CONNECT_TIMEOUT)
// 数据传输最大响应间隔时间 // 数据传输最大响应间隔时间
.setSocketTimeout(SOCKET_TIMEOUT) .setSocketTimeout(SOCKET_TIMEOUT)
// 遇到301 302自动重定向跳转 // 遇到301 302自动重定向跳转
.setRedirectsEnabled(false) .setRedirectsEnabled(true)
.build(); .build();
// 连接池 // 连接池
connectionManager = new PoolingHttpClientConnectionManager(registry); connectionManager = new PoolingHttpClientConnectionManager(registry);