Home > other >  Turn a issue of websocket
Turn a issue of websocket

Time:10-20

I use in the project to develop a real-time refresh for springmvc + mybatis project, in the local test front-end and back-end can be normal use, Linux server in the company post test can normal visit, but on the client/server deployment operation access error, due to the server is the client, only through the network access,

The front-end error:
 
Firefox cannot be established to ws://web address/project name/websocket server connection,
The Close mySocket finish...


Backstage, error log is as follows:

 
2016-05-23 18:22:14 [HTTP - nio - 10030 - exec - 3930] - [the DEBUG] DispatcherServlet with the name 'spring' processing a GET request for [/project name/websocket]
2016-05-23 18:22:14 [HTTP - nio - 10030 - exec - 3930] - [the DEBUG] & up handler method for path/websocket
2016-05-23 18:22:14 [HTTP - nio - 10030 - exec - 3945] - [the DEBUG] Did not find a handler method for [/websocket]
2016-05-23 18:22:14 [HTTP - nio - 10030 - exec - 3945] - [the DEBUG] Mapping [/websocket] to HandlerExecutionChain with handler [org. Springframework. Web. Socket. Server support. WebSocketHttpRequestHandler @ 69 dc323b] and 1 interceptor
2016-05-23 18:22:14 [HTTP - nio - 10030 - exec - 3946] - [the DEBUG] last-modified value for/HGS - DTUTest/websocket is: 1
2016-05-23 18:22:14 [HTTP - nio - 10030 - exec - 3947] - [the DEBUG] Skip CORS processing, the request is a same origin - one
2016-05-23 18:22:14 [HTTP - nio - 10030 - exec - 3947] - [the DEBUG] GET/project name/websocket
2016-05-23 18:22:14 [HTTP - nio - 10030 - exec - 3950] - [the DEBUG] Resolving exception from handler [org. Springframework. Web. Socket. Server support. WebSocketHttpRequestHandler @ 69 dc323b] : org. Springframework. Web. Socket. Server HandshakeFailureException: Uncaught failure for request outside http://web address/project name/websocket; Nested exception is Java. Lang. NoSuchMethodError: org.. Apache tomcat. Websocket. Server WsServerContainer. DoUpgrade (Ljavax/servlet/HTTP/it; Ljavax/servlet/HTTP/HttpServletResponse; Ljavax/websocket/server/ServerEndpointConfig; Ljava/util/Map) V
2016-05-23 18:22:14 [HTTP - nio - 10030 - exec - 3950] - [the DEBUG] Resolving exception from handler [org. Springframework. Web. Socket. Server support. WebSocketHttpRequestHandler @ 69 dc323b] : org. Springframework. Web. Socket. Server HandshakeFailureException: Uncaught failure for request outside http://web address/project name/websocket; Nested exception is Java. Lang. NoSuchMethodError: org.. Apache tomcat. Websocket. Server WsServerContainer. DoUpgrade (Ljavax/servlet/HTTP/it; Ljavax/servlet/HTTP/HttpServletResponse; Ljavax/websocket/server/ServerEndpointConfig; Ljava/util/Map) V
2016-05-23 18:22:14 [HTTP - nio - 10030 - exec - 3950] - [the DEBUG] Could not complete request
Org. Springframework. Web. Socket. Server HandshakeFailureException: Uncaught failure for request outside http://web address/project name/websocket; Nested exception is Java. Lang. NoSuchMethodError: org.. Apache tomcat. Websocket. Server WsServerContainer. DoUpgrade (Ljavax/servlet/HTTP/it; Ljavax/servlet/HTTP/HttpServletResponse; Ljavax/websocket/server/ServerEndpointConfig; Ljava/util/Map) V
At org. Springframework. Web. Socket. Server support. WebSocketHttpRequestHandler. HandleRequest (WebSocketHttpRequestHandler. Java: 174)
The at org. Springframework. Web. Servlet. MVC. HttpRequestHandlerAdapter. Handle (HttpRequestHandlerAdapter. Java: 51)
The at org. Springframework. Web. Servlet. DispatcherServlet. DoDispatch (DispatcherServlet. Java: 959)
The at org. Springframework. Web. Servlet. DispatcherServlet. DoService (DispatcherServlet. Java: 893)
The at org. Springframework. Web. Servlet. FrameworkServlet. The processRequest (FrameworkServlet. Java: 970)
The at org. Springframework. Web. Servlet. FrameworkServlet. DoGet (FrameworkServlet. Java: 861)
The at javax.mail. Servlet. HTTP. HttpServlet. Service (HttpServlet. Java: 622)
At org. Springframework. Web. Servlet. FrameworkServlet. Service (846) FrameworkServlet. Java:
The at javax.mail. Servlet. HTTP. HttpServlet. Service (HttpServlet. Java: 729)
The at org. Apache. Catalina. Core. ApplicationFilterChain. InternalDoFilter (ApplicationFilterChain. Java: 230)
The at org. Apache. Catalina. Core. ApplicationFilterChain. DoFilter (ApplicationFilterChain. Java: 165)
At org, apache tomcat, websocket server WsFilter. DoFilter (WsFilter. Java: 52)
The at org. Apache. Catalina. Core. ApplicationFilterChain. InternalDoFilter (ApplicationFilterChain. Java: 192)
The at org. Apache. Catalina. Core. ApplicationFilterChain. DoFilter (ApplicationFilterChain. Java: 165)
The at org. Springframework. Web. Filter. CharacterEncodingFilter. DoFilterInternal (CharacterEncodingFilter. Java: 85)
The at org. Springframework. Web. Filter. OncePerRequestFilter. DoFilter (OncePerRequestFilter. Java: 107)
The at org. Apache. Catalina. Core. ApplicationFilterChain. InternalDoFilter (ApplicationFilterChain. Java: 192)
The at org. Apache. Catalina. Core. ApplicationFilterChain. DoFilter (ApplicationFilterChain. Java: 165)
The at org. Apache. Catalina. Core. StandardWrapperValve. Invoke (StandardWrapperValve. Java: 198)
The at org. Apache. Catalina. Core. StandardContextValve. Invoke (StandardContextValve. Java: 108)
The at org. Apache. Catalina. The authenticator. AuthenticatorBase. Invoke (AuthenticatorBase. Java: 522)
The at org. Apache. Catalina. Core. StandardHostValve. Invoke (StandardHostValve. Java: 140)
nullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnull
  • Related