whyclxw
2024-09-21 d6d29e98e4250c53903a316ca855f0c04ae1ea86
测试修改
1个文件已修改
2 ■■■■■ 已修改文件
src/main/java/com/whyc/config/HttpConifg.java 2 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/main/java/com/whyc/config/HttpConifg.java
@@ -2,6 +2,7 @@
import org.springframework.context.annotation.Bean;
import org.springframework.context.annotation.Configuration;
import org.springframework.context.annotation.Scope;
import org.springframework.http.client.SimpleClientHttpRequestFactory;
import org.springframework.web.client.RestTemplate;
@@ -9,6 +10,7 @@
public class HttpConifg {
    @Bean
    @Scope("prototype")
    public RestTemplate getRestTemplate(){
        SimpleClientHttpRequestFactory requestFactory = new SimpleClientHttpRequestFactory();
        // 设置连接超时时间(单位:毫秒)