enf*_*any 5 resttemplate spring-boot
我们在客户端和 REST 服务(两者都在 Windows 上本地运行)之间使用 Spring Boot + RestTemplate。我测量了服务调用的时间,很好,但是结果准备好从服务器返回和客户端得到响应之间的时间很慢。
ResponseEntity<PageResult<MyPOJO>> response = restTemplate.exchange(url, HttpMethod.POST, request, typeRef);
return response;
Run Code Online (Sandbox Code Playgroud)
数据并不大(大约50条记录),花9秒将结果返回给客户端是没有意义的。如何排查哪个部分花费的时间最长?RestTemplate 的任何性能调整或配置技巧?
| 归档时间: |
|
| 查看次数: |
1601 次 |
| 最近记录: |