Could not autowire. No beans of 'RestTemplate' type found. 解决方案 @Resourceprivate RestTemplate restTemplate;