Browse Source

websocket support v3 fix

master
gsd 1 year ago
parent
commit
b08133b2fb
  1. 2
      src/main/java/app/websocket/configuration/WebSocketConfig.java

2
src/main/java/app/websocket/configuration/WebSocketConfig.java

@ -24,7 +24,7 @@ public class WebSocketConfig implements WebSocketConfigurer {
public void registerWebSocketHandlers(WebSocketHandlerRegistry registry) {
handlers.forEach(hndl -> {
logger.info("Found websocket bean: {}", hndl.getPath());
registry.addHandler((WebSocketHandler) hndl, "/ws/" + hndl.getPath());
registry.addHandler((WebSocketHandler) hndl, "/ws/" + hndl.getPath()).setAllowedOrigins("*");
});
}
}

Loading…
Cancel
Save