We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
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
将sessionid存到httpsession的时候不适用固定key,使用httpsessionid作为key不就好了嘛,反正httpsessionid在销毁前是有效的,所以在这个会话内给客户端发消息就很方便了
public void init() { super.init(); if (httpSession != null) httpSession.setAttribute(httpSession.getId() , session.getId()); }
websocketEndpoint.sendJson(httpsession.getAttribute(httpsession.getId()), msg);
The text was updated successfully, but these errors were encountered:
考虑一下一个httpsession对应多个websocket的情况?
原来我一直没提交成功...
Sorry, something went wrong.
No branches or pull requests
将sessionid存到httpsession的时候不适用固定key,使用httpsessionid作为key不就好了嘛,反正httpsessionid在销毁前是有效的,所以在这个会话内给客户端发消息就很方便了
The text was updated successfully, but these errors were encountered: