从早上开始,我一直在努力了解如何在我的webApp(Spring-MVC)和Spring-Social之间实现SignIn功能.
我正在使用XML配置,并且看起来工作良好.我遇到麻烦登录使用示例Twitter.我告诉你我的堆栈跟踪打印出来:
InvocableHandlerMethod - Invoking [signIn] method with arguments [twitter,ServletWebRequest: uri=/SitiPreventivi/signin/twitter;client=127.0.0.1;session=6EE8AE04F40C32C823646844BF36378B]
2013-01-12 18:21:16,168 DEBUG [http-bio-8080-exec-7] HttpAccessor - Created POST request for "https://api.twitter.com/oauth/request_token"
2013-01-12 18:21:16,169 DEBUG [http-bio-8080-exec-7] RestTemplate$AcceptHeaderRequestCallback - Setting request Accept header to [application/x-www-form-urlencoded,multipart/form-data]
2013-01-12 18:21:17,317 WARN [http-bio-8080-exec-7] RestTemplate - POST request for "https://api.twitter.com/oauth/request_token" resulted in 406 (Not Acceptable); invoking error handler
2013-01-12 18:21:17,326 DEBUG [http-bio-8080-exec-7] InvocableHandlerMethod - Method [signIn] returned [org.springframework.web.servlet.view.RedirectView: unnamed; URL [/signin?error=provider]]
2013-01-12 18:21:17,326 DEBUG [http-bio-8080-exec-7] DispatcherServlet - Rendering view [org.springframework.web.servlet.view.RedirectView: unnamed; URL [/signin?error=provider]] in DispatcherServlet with name 'SitiPreventivi Servlet'
2013-01-12 18:21:17,326 DEBUG [http-bio-8080-exec-7] AbstractView - Rendering view with name 'null' with model {} and static attributes {}
我只向您展示有关我的问题的相关部分.
如您所见,发出了对正确网址的发布请求,但出现了406错误,无法解释.
有办法解决问题吗?
提前致谢.
克劳迪奥
最佳答案
原文链接:https://www.f2er.com/spring/531878.html