Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

用户量大了之后禁用用户无法踢出用户 #6636

Open
lq-java opened this issue Jun 23, 2024 · 1 comment
Open

用户量大了之后禁用用户无法踢出用户 #6636

lq-java opened this issue Jun 23, 2024 · 1 comment

Comments

@lq-java
Copy link

lq-java commented Jun 23, 2024

版本号:

3.5.0

问题描述:

看了下在线用户管理的功能,列表是用的redisTemplate.keys()模糊匹配所有的token,但是如果数据量大了的话,keys严重影响性能,而且会阻塞整个Redis服务器。单独的踢出用户又是通过token来踢出的。在禁用某个用户或者删除某个用户时,无法删除对应token,除非是获取出所有token对应的key,再找到这个用户的token去删掉

错误截图:

image
在在线用户管理中,踢出某用户的接口里,这行代码也是有问题的,这里是表示退出当前登录的账号,并不是退出要踢出的用户,这里执行踢出为什么要退出当前用户。

友情提示:

  • 未按格式要求发帖、描述过于简抽象的,会被直接删掉;
  • 请确保问题描述清楚,方便我们理解并一次性调查解决问题;
  • 如果使用的不是master,请说明你使用的那个分支
@zhangdaiscott
Copy link
Member

有错误吗

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants