当从oauth2服务中获取到了token后,携带该token去请求其他服务时,报出
{
"error": "invalid_token",
"error_description": "Invalid access token: e5224346-ea39-49ff-bd0e-1b9aef3db1da"
}
需要在当前服务的配置文件配置
#内置有user对象的地址,才能获取到同一个token
security.oauth2.resource.user-info-uri=http://localhost:8003/api/user
security.oauth2.resource.prefer-token-info=false