springBlade后端使用WebSocket,报错

Java 未结 7 6068
大神请教
大神请教 2020-02-21 22:38
org.springframework.bootspring-boot-starter-websocket


WebSocketConfig {

   ServerEndpointExporter () {
      ServerEndpointExporter()}
}

Caused by: org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'serverEndpointExporter' defined in class path resource [org/springblade/modules/lives/gongju/WebSocketConfig.class]: Invocation of init method failed; nested exception is java.lang.IllegalStateException: javax.websocket.server.ServerContainer not available


7条回答
  •  yxs
    yxs (楼主)
    2020-08-12 13:48

    猜测原因:作者用的是undertow容器 你排除掉使用tomcat试试,我是这样解决的。


提交回复