diff --git a/src/main/java/com/ntlab/irisserver/WebSocketConfig.java b/src/main/java/com/ntlab/irisserver/WebSocketConfig.java index 28472de..1796387 100644 --- a/src/main/java/com/ntlab/irisserver/WebSocketConfig.java +++ b/src/main/java/com/ntlab/irisserver/WebSocketConfig.java @@ -4,12 +4,14 @@ import com.ntlab.irisserver.websockets.HelloWebSocket; import org.springframework.context.annotation.Bean; import org.springframework.context.annotation.Configuration; +import org.springframework.stereotype.Controller; import org.springframework.web.socket.WebSocketHandler; import org.springframework.web.socket.config.annotation.*; import org.springframework.web.socket.server.standard.ServerEndpointExporter; @Configuration @EnableWebSocket +@Controller public class WebSocketConfig implements WebSocketConfigurer { @Override @@ -17,10 +19,10 @@ //registry.addHandler(helloWorldWebSocket2(), "/hello-websocket2"); } -// @Bean -// public HelloWebSocket helloWebSocket() { -// return new HelloWebSocket(); -// } + @Bean + public HelloWebSocket helloWebSocket() { + return new HelloWebSocket(); + } @Bean public ServerEndpointExporter serverEndpointExporter() {