문서의 선택한 두 판 사이의 차이를 보여줍니다.
| 양쪽 이전 판 이전 판 다음 판 | 이전 판 | ||
|
springframework:resttemplate [2020/07/20 16:33] kwon37xi [SpringBoot] |
springframework:resttemplate [2022/01/14 15:43] (현재) kwon37xi |
||
|---|---|---|---|
| 줄 5: | 줄 5: | ||
| * [[https:// | * [[https:// | ||
| * [[https:// | * [[https:// | ||
| + | * see [[springframework: | ||
| ===== HttpEntity ===== | ===== HttpEntity ===== | ||
| 줄 77: | 줄 78: | ||
| <code java> | <code java> | ||
| - | | + | @Bean |
| - | public RestTemplate restTemplate(RestTemplateBuilder restTemplateBuilder) { | + | public RestTemplate restTemplate(RestTemplateBuilder restTemplateBuilder) { |
| - | return restTemplateBuilder | + | return restTemplateBuilder |
| - | .requestFactory(() -> new BufferingClientHttpRequestFactory(new SimpleClientHttpRequestFactory())) | + | .requestFactory(() -> new BufferingClientHttpRequestFactory(new SimpleClientHttpRequestFactory())) |
| - | .setConnectTimeout(Duration.ofMillis(5000)) // connection-timeout | + | .setConnectTimeout(Duration.ofMillis(5000)) // connection-timeout |
| - | .setReadTimeout(Duration.ofMillis(5000)) // read-timeout | + | .setReadTimeout(Duration.ofMillis(5000)) // read-timeout |
| - | .additionalMessageConverters(new StringHttpMessageConverter(Charset.forName(" | + | .additionalMessageConverters(new StringHttpMessageConverter(Charset.forName(" |
| - | .build(); | + | .build(); |
| - | } | + | } |
| </ | </ | ||
| + | |||
| ===== 참조 ===== | ===== 참조 ===== | ||
| * [[https:// | * [[https:// | ||
| + | * [[https:// | ||
| + | * [[https:// | ||
| + | * [[https:// | ||