diff options
author | 2018-03-21 09:15:58 +0300 | |
---|---|---|
committer | 2018-03-21 09:15:58 +0300 | |
commit | 5d139bd9d7b3f65453eef29ef9806c9738891f90 (patch) | |
tree | 5773fb6d1ab826747419cf4d0c9829b4b197c7a5 /juick-server/src/main/java/com/juick/server/configuration/ApiAppConfiguration.java | |
parent | 5e6d2e46d5770041676a25353ace4c49f15f6cc6 (diff) |
ws: lowest precedence
Diffstat (limited to 'juick-server/src/main/java/com/juick/server/configuration/ApiAppConfiguration.java')
-rw-r--r-- | juick-server/src/main/java/com/juick/server/configuration/ApiAppConfiguration.java | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/juick-server/src/main/java/com/juick/server/configuration/ApiAppConfiguration.java b/juick-server/src/main/java/com/juick/server/configuration/ApiAppConfiguration.java index 6c4cac8b..77ceb9db 100644 --- a/juick-server/src/main/java/com/juick/server/configuration/ApiAppConfiguration.java +++ b/juick-server/src/main/java/com/juick/server/configuration/ApiAppConfiguration.java @@ -27,6 +27,7 @@ import com.juick.server.component.JuickServerReconnectManager; import com.juick.service.UserService; import org.springframework.beans.factory.annotation.Value; import org.springframework.context.annotation.*; +import org.springframework.core.Ordered; import org.springframework.scheduling.annotation.EnableAsync; import org.springframework.scheduling.annotation.EnableScheduling; import org.springframework.web.servlet.config.annotation.DefaultServletHandlerConfigurer; @@ -38,6 +39,7 @@ import org.springframework.web.servlet.view.feed.AbstractRssFeedView; import org.springframework.web.socket.client.WebSocketConnectionManager; import org.springframework.web.socket.client.standard.StandardWebSocketClient; import org.springframework.web.socket.config.annotation.EnableWebSocket; +import org.springframework.web.socket.config.annotation.ServletWebSocketHandlerRegistry; import org.springframework.web.socket.config.annotation.WebSocketConfigurer; import org.springframework.web.socket.config.annotation.WebSocketHandlerRegistry; import org.springframework.web.socket.server.standard.ServletServerContainerFactoryBean; @@ -106,7 +108,7 @@ public class ApiAppConfiguration implements WebMvcConfigurer, WebSocketConfigure @Override public void registerWebSocketHandlers(@Nonnull WebSocketHandlerRegistry registry) { - //((ServletWebSocketHandlerRegistry) registry).setOrder(Ordered.LOWEST_PRECEDENCE); + ((ServletWebSocketHandlerRegistry) registry).setOrder(Ordered.LOWEST_PRECEDENCE); registry.addHandler(wsHandler(), "/ws/**").setAllowedOrigins("*"); } |