会员
周边
新闻
博问
闪存
赞助商
YouClaw
所有博客
当前博客
我的博客
我的园子
账号设置
会员中心
简洁模式
...
退出登录
注册
登录
傻逼二货
博客园
首页
新随笔
联系
管理
订阅
06 2019 档案
WebSocket 使用,同时获取HttpSession,并注入springBean
摘要:1. 添加jar包 2. 配置类 3 . 从websocket中获取用户session 4 . 设置监听 5. 获取spring容器工具类 6. webSocket服务类
阅读全文
posted @
2019-06-20 13:38
窦婴
阅读(1830)
评论(0)
推荐(0)
在非controller中获取HttpServletRequest (如在service中获取)
摘要:HttpServletRequest request = ((ServletRequestAttributes) RequestContextHolder.currentRequestAttributes()).getRequest();
阅读全文
posted @
2019-06-20 13:25
窦婴
阅读(1619)
评论(0)
推荐(1)
公告