use of org.eclipse.vorto.repository.utils.LoggingInterceptor in project vorto by eclipse.
the class RepositoryConfiguration method restTemplate.
@Bean
public RestTemplate restTemplate() {
RestTemplate restTemplate = new RestTemplate(new BufferingClientHttpRequestFactory(new SimpleClientHttpRequestFactory()));
List<ClientHttpRequestInterceptor> interceptors = new ArrayList<>();
interceptors.add(new LoggingInterceptor());
restTemplate.setInterceptors(interceptors);
restTemplate.getMessageConverters().add(new ByteArrayHttpMessageConverter());
return restTemplate;
}
Aggregations