문제

I'm trying to use spring rest template to do a post request. And i need to return the status code. This is my approach.

RestTemplate restTemplate = new RestTemplate();
MultiValueMap mvm = new LinkedMultiValueMap();
mvm.add("login", "100"); // and some more paramters
String result = restTemplate.postForObject("http://localhost:8080/security_check", mvm, String.class);

But this approach doesn't work for me. It generates an error saying no suitable message converter found. And i need to know can i use the resttemplate to manage my sessions. I need to manage the session from the android client side.

If any one come across android resttemplate post method and session management please help me. Any help would be greatly appreciated.
Thanks in advance.

도움이 되었습니까?

해결책

See http://forum.springsource.org/showthread.php?t=99064 Pls mark this question as answered or delete it since u asked it on the link I just posted.

And by the way I can take a look at my question regarding a similiar issue... http://forum.springsource.org/showthread.php?t=99690 ;)

라이센스 : CC-BY-SA ~와 함께 속성
제휴하지 않습니다 StackOverflow
scroll top