I have three questions!
At first.
I am using a spring structure to send data through a break protocol.
restTemplate.exchange(requestUrl,HttpMethod.POST, request, listVo.getClass()); org.springframework.web.client.RestTemplate.exchange(String url, HttpMethod method, HttpEntity<?> requestEntity, Class<? extends Object> responseType, Object... uriVariables) throws RestClientException
I used it without any problems, but I want to know the purpose of the responseType parameter. The client does not use response data, but simply uses the response status code / msg. So, I sent pointless string data instead. But the mistake threw that they accept "zero". So I sent the string "null". not zero. Then the error got rid. But there was another problem. Immediately after the client received data from the server and suspended for a long time. Then the next line of codes is executed. What a problem?
Second
I cannot find links that use the execute spring RestTemplate method.
Third
Like the name, What is the difference between the exchange method and the execute method in the spring rest pattern?
Thank you for your time and effort. Greetings.
source share