Spring RestTemplate treats Non-200 status as Exception
Recently I run into the following code snippets:
ResponseEntity<ApmTopoResponse> response2 = null;
try {
response2 = restTemplate.exchange(topoUrl, HttpMethod.GET, request, ApmTopoResponse.class, 1);
} catch (Exception e) {
throw new CustomExcept...
kenhu.hashnode.dev4 min read