用户登录{providerId}只能通过POST请求启动(到/ signin / {providerId})是否有特定原因?为什么不使用GET请求?
回答我自己的问题:也许是因为
/**
* Process the authentication callback when neither the oauth_token or code parameter is given, likely indicating that the user denied authorization with the provider.
* Redirects to application's sign in URL, as set in the signInUrl property.
* @return A RedirectView to the sign in URL
*/
@RequestMapping(value="/{providerId}", method=RequestMethod.GET)
public RedirectView canceledAuthorizationCallback() {
return redirect(signInUrl);
}
无论如何,如果也可以使用GET请求进行登录(使用不同的URL或缩小映射的参数)将会很好。