diff --git a/tosan-httpclient-spring-boot-core/src/main/java/com/tosan/client/http/core/factory/ConfigurableApacheHttpClientFactory.java b/tosan-httpclient-spring-boot-core/src/main/java/com/tosan/client/http/core/factory/ConfigurableApacheHttpClientFactory.java index 7f698ea..35adc6e 100644 --- a/tosan-httpclient-spring-boot-core/src/main/java/com/tosan/client/http/core/factory/ConfigurableApacheHttpClientFactory.java +++ b/tosan-httpclient-spring-boot-core/src/main/java/com/tosan/client/http/core/factory/ConfigurableApacheHttpClientFactory.java @@ -1,7 +1,7 @@ package com.tosan.client.http.core.factory; -import com.tosan.client.http.core.certificate.CertificateLoader; import com.tosan.client.http.core.HttpClientProperties; +import com.tosan.client.http.core.certificate.CertificateLoader; import org.apache.commons.lang3.StringUtils; import org.apache.http.HttpHost; import org.apache.http.auth.AuthScope; @@ -68,6 +68,7 @@ private void configureTimeouts(HttpClientBuilder builder) { builder.setDefaultRequestConfig(RequestConfig.custom() .setConnectTimeout(httpClientProperties.getConnection().getConnectionTimeout()) .setSocketTimeout(httpClientProperties.getConnection().getSocketTimeout()) + .setRedirectsEnabled(httpClientProperties.getConnection().isFollowRedirects()) .build()); }