-
Notifications
You must be signed in to change notification settings - Fork 528
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
session序列化 #149
Comments
rabbitmq中使用session参数是什么意思,是将session通过rabbitmq发出去吗? |
我是打算把用户的session传递到消费者中。消费者使用session发送消息 ,请问可以吗? |
这个框架如何实现向某个用户组发送消息,不用遍历session转发 |
websocket的session是对应一条真实的连接,有状态的,和http的session的原理不一样。 |
向用户组发送消息,本质上也是遍历,因为cpu执行指令本质上是串行的 |
那这个向用户组广播只能把session存在map里头,需要的时候遍历一次吗? |
是的 |
我要是需要向几万个用户转发,怎么解决效率问题哦 |
正常用就好了,不会有效率问题 |
非常感谢 |
可以考虑hash一致性 实现免遍历, |
不是太懂,有文章可以参考下吗? |
不存在不遍历的,CPU的时钟是有序的,所以执行是一条条的。 |
https://lawrenceli.me/blog/websocket-cluster 还有,你的意思是消费的内容是 Session 本身吗?你不一定要去存放整个 Session 对象,只要维护一个静态 Map,用 SessionId 来作为 Session 的查询 key 就行。 |
我最近再想办法实现,好了call你 |
你好,我想在rabbitmq中使用session参数,rabbitmq序列化session对象失败,请问该怎么解决。谢谢了
The text was updated successfully, but these errors were encountered: