Когда я попытался перейти из моего первого приложения Springboot в другое через RestTemplate, получая ошибку ниже от почтальона
URI запроса: http://localhost:8083/template/getprodgsspringboot
"timestamp": "2019-03-15T10:02:39.168+0000",
"status": 500,
"error": "Internal Server Error",
"message": "I/O error on GET request for \"http://localhost:8080/products\": Connection refused: connect; nested exception is java.net.ConnectException: Connection refused: connect",
"path": "/template/getprodgsspringboot"
Первое весеннее загрузочное приложение: Контроллер отдыха
@RequestMapping("/template/getprodgsspringboot")
public String getProductList() {
HttpHeaders headers=new HttpHeaders();
headers.setAccept(Arrays.asList(MediaType.APPLICATION_JSON));
HttpEntity<String> http=new HttpEntity<>(headers);
return resttemplate.exchange("http://localhost:8080/products",HttpMethod.GET,http,String.class).getBody();
}
Второе загрузочное приложение Spring: Контроллер отдыха
//GET Method of rest webservice
@RequestMapping("/products")
public ResponseEntity<Object> getMethod(){
System.out.println("My GET http method");
retu