springboot中websocket注入bean为null
今天想在websocket控制类@ServerEndpoint中修改用户的登陆状态,所以在websocket控制类中通过@Autowired注入了用户操作类UserMgrDao,本以为只是常规操作,没想到立刻被打了脸。呜呜呜…
@Component
@ServerEndpoint(value = "/websocket", configurator = WebSocketConfig.class)...
原创
2019-12-10 21:36:34 ·
636 阅读 ·
0 评论