Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Multiple Incoming messages #26

Open
priyankn opened this issue Jan 23, 2019 · 3 comments
Open

Multiple Incoming messages #26

priyankn opened this issue Jan 23, 2019 · 3 comments

Comments

@priyankn
Copy link

Good work on this project!
I have one question though, does the client keeps the websocket channel open for new incoming messages?

I have a particular scenario where the for one 'outgoing' request, I have two 'incoming' responses from the server. I can see the first response, but not the second ( I see it via the browser). I suspect the channel is closed, but some clarification would be appreciated.

@priyankn priyankn changed the title Multiple messages Multiple Incoming messages Jan 23, 2019
@vi
Copy link
Owner

vi commented Jan 23, 2019

Multiple incoming messages should be OK. By default each text message should turn into one line on stdout. Close is sent when stdin is closed (unless -n option is specified to websocat).

I can see the first response, but not the second

What do you see instead? Does it exits or just wait?

@priyankn
Copy link
Author

priyankn commented Jan 23, 2019

Nothing, it just waits. The connection drops anyway after ~5 secs, so if I try to send the request again I see:

^@websocat: WebSocketError: I/O failure

Edit: I am using binary mode.

@vi
Copy link
Owner

vi commented Jan 23, 2019

Please show the command line.

Assuming it's Linux, please also prepare two logs like this:

RUST_LOG=debug websocat -b ws://your_server 2> log1.txt
strace -fe trace=network -o log2.txt websocat -b ws://your_server

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

No branches or pull requests

2 participants