mirror of
https://gitee.com/dromara/MaxKey.git
synced 2025-12-06 17:08:29 +08:00
修正redis连接不释放
程序运行时间长会出现redis连接超过最大值错误:Caused by: redis.clients.jedis.exceptions.JedisDataException: ERR max number of clients reached Signed-off-by: when <w_zhi_yuan@163.com>
This commit is contained in:
parent
4f3e80ac83
commit
87fe21fcfb
@ -58,6 +58,7 @@ public class RedisAuthorizationCodeServices extends RandomValueAuthorizationCode
|
||||
RedisConnection conn=connectionFactory.getConnection();
|
||||
OAuth2Authentication auth = conn.getObject(PREFIX+code);
|
||||
conn.delete(PREFIX+code);
|
||||
conn.close();
|
||||
return auth;
|
||||
}
|
||||
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user