Skip to content
This repository has been archived by the owner on May 22, 2019. It is now read-only.

Toggleable "/" behavior #18

Closed
aengelberg opened this issue Feb 20, 2015 · 3 comments
Closed

Toggleable "/" behavior #18

aengelberg opened this issue Feb 20, 2015 · 3 comments

Comments

@aengelberg
Copy link

I have a (non-jawampa) WAMP client that's trying to connect to my jawampa server at the root path ( "/" ) and is expecting a websocket handshake. I tried to configure my SimpleWampWebsocketListener to listen on the root path (by putting "/" as the uri) but it is still serving a 200 OK response "This server provides a wamp router on path" instead of the websocket handshake. Thus, the client returns the error message "Error during WebSocket handshake: Unexpected response code: 200"

Is there a way to toggle the behavior that sets up that handler, so that I can set up my WAMP router to listen on the root path, without this placeholder getting in the way?

@Matthias247
Copy link
Owner

Hi, I just tried to reproduce this. I set up the SimpleListener with

URI serverUri = URI.create("ws://0.0.0.0:8080/");
SimpleWampWebsocketListener server = new SimpleWampWebsocketListener(router, serverUri, null);

and can connect just fine with a jawampa client and a javascript (autobahn) client using the URL "ws://127.0.0.1:8080/".
From the server side code I also can't see anything that could cause the behavior that you see. Because the WAMP upgrade path is checked first. And only if the request is no upgrade request the request will be forwarded and treated as a normal HTTP request. Maybe your client library does not support the root path?

@santhosh-tekuri
Copy link
Contributor

this is recently fixed in following commit:

66549a2

@aengelberg
Copy link
Author

woohoo, thanks! :)

--Alex

On Sun, Apr 5, 2015 at 5:59 AM, Santhosh Kumar Tekuri <
notifications@github.com> wrote:

this is recently fixed in following commit:

66549a2
66549a2


Reply to this email directly or view it on GitHub
#18 (comment).

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants