You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@mina.apache.org by "Bernd Fondermann (JIRA)" <ji...@apache.org> on 2013/02/27 14:21:14 UTC

[jira] [Commented] (VYSPER-340) Problems Performing WebSocket Handshake

    [ https://issues.apache.org/jira/browse/VYSPER-340?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13588317#comment-13588317 ] 

Bernd Fondermann commented on VYSPER-340:
-----------------------------------------

General note: Please ask questions on the user or dev list, not on svn. JIRA makes discussing stuff even more awkward than in email.

If I'm not mistaken, our Websocket support is only experimental and probably outdated. 
The errror code 1006 also suggests this:
 1006

      1006 is a reserved value and MUST NOT be set as a status code in a
      Close control frame by an endpoint.  It is designated for use in
      applications expecting a status code to indicate that the
      connection was closed abnormally, e.g., without sending or
      receiving a Close control frame.

Currently, nobody is working on Websocket support in Vysper.
                
> Problems Performing WebSocket Handshake
> ---------------------------------------
>
>                 Key: VYSPER-340
>                 URL: https://issues.apache.org/jira/browse/VYSPER-340
>             Project: VYSPER
>          Issue Type: Question
>          Components: extension
>    Affects Versions: 0.7
>         Environment: Windows Server 2008 R2
>            Reporter: Robert McNamara
>              Labels: javascript, websocket
>
> I’m having an issue performing a successful handshake. Weather running Vysper from the batch file or embedded in a simple Java Server (my own or one of the prepackaged examples), I get the same error condition upon attempting to connect from a JavaScript client (my own or one of the prepackaged examples). The error the returns is a HTTP 405 Response, reported in Chrome's console as “Unexpected response code: 405”.
> CONFIGURATION OF STANDALONE SERVER:
> ‘spring-config.xml’ has the following additions:
>     <bean id="websocketEndpoint" class="org.apache.vysper.xmpp.extension.websockets.WebSocketEndpoint">
>         <property name="port" value="8080" />
>         <property name="contextPath" value="/ws" />
>     </bean>
> And in the server constructor: 
>    <ref bean="websocketEndpoint"/>
> POSSIBLE START ERROR CONDITION:
> The Server appears to start properly, only with the following possible problem reported (on both standalone and embedded servers):
>   org.eclipse.jetty.server.Server@2af081 STOPPED
>    +-SelectChannelConnector@0.0.0.0:8080
>    +-qtp29384701{8<=6<=8/254,0}
>    +-ServletContextHandler@32efa7@32efa7/ws,null started
>       +-{}
>       +-{}
>      +-SessionHandler@1fbfd6 started
>         +-ServletHandler@6b9c84 started
>            +-[/ws]=>org.apache.vysper.xmpp.extension.websockets.XmppWebSocketServlet-23860799{}
> ATTEMPTING CONNECTION ERRORS:
> When attempting to connect from the client the following is logged in both types of server instance:
>   17:04:02,137 | DEBUG | org.eclipse.jetty.util.log | REQUEST /ws/ws on org.eclipse.jetty.server.nio.SelectChannelConnector$3@c3615b
>   17:04:02,137 | DEBUG | org.eclipse.jetty.util.log | sessionManager=org.eclipse.jetty.server.session.HashSessionManager@1767f84
>   17:04:02,137 | DEBUG | org.eclipse.jetty.util.log | session=null
>   17:04:02,137 | DEBUG | org.eclipse.jetty.util.log | servlet=org.apache.vysper.xmpp.extension.websockets.XmppWebSocketServlet-29347786
>   17:04:02,137 | DEBUG | org.eclipse.jetty.util.log | servlet holder=
>   17:04:02,137 | DEBUG | org.eclipse.jetty.util.log | chain=
>   17:04:02,137 | DEBUG | org.eclipse.jetty.util.log | RESPONSE /ws/ws  405
>   17:04:02,137 | DEBUG | org.eclipse.jetty.util.log | EOF
> And to the Chrome console on the client side:
>   Unexpected response code: 405
>   Event {clipboardData: undefined, cancelBubble: false, returnValue: true, srcElement: WebSocket, defaultPrevented: false…}
>   CloseEvent {reason: "", code: 1006, wasClean: false, clipboardData: undefined, cancelBubble: false…}
> Any suggestions on how to proceed?
> Thanks, Rob

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira