HttpHeaders reqheaders= new HttpHeaders();
reqheaders.set(HttpHeaders.Accept,MediaType.Application_xml)
reqheaders.set(HttpHeaders.Content_type,MediaType.Application Json)
HttpEntity XML= new HttpEntity (json,reqheaders)
ResponseEntity<Map> xmlfile= restTemplate.exchange(url,HttpMethod.POST,XML, Map.class)
I am getting no suitable HttpMessageConverter found for response type[interface java.util.Map] and content type [application/xml;charset=UTF-8]
it looks like no suitable
HttpMessageConverteris registered with the RestTemplate can convertxmlcontent to a Map object.There some
HttpMessageConverterswhich are pre-enabled and can be checked here. You need to make sure that the suitableHttpMessageConverteris on your classpath.