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

Error polling incoming connection: frame size too big #75

Open
akosyakov opened this issue May 2, 2018 · 2 comments
Open

Error polling incoming connection: frame size too big #75

akosyakov opened this issue May 2, 2018 · 2 comments
Labels

Comments

@akosyakov
Copy link

I am getting when trying out Xray in the browser:

Error sending message to client on TCP socket: Protocol wrong type for socket (os error 41)
Error polling incoming connection: frame size too big
Error polling incoming connection: frame size too big
Error sending message to client on TCP socket: Broken pipe (os error 32)
Error polling incoming connection: frame size too big

Also some keys don't seem to work, e.g. i cannot enter a new line.

@as-cii as-cii added the bug label May 2, 2018
@as-cii
Copy link
Contributor

as-cii commented May 2, 2018

Hello @akosyakov, and thanks for the report. We are aware of this issue and it is being caused by sending too much data on the TCP socket. Last time we saw this, it was related to sending the whole directory structure of a massive repository to the connecting client.

There are a couple of things that we could do to mitigate this:

  1. Increase the frame size via codec::length_delimited::Builder::max_frame_length. TCP may have some issues with handling frames that are larger than 64kb though.
  2. Split outgoing data into frames that are smaller than the maximum size and then re-assemble them when receiving them on the client. I think this would require writing our own codec, but should be pretty straightforward.
  3. Switch to a streamed representation for in-memory trees. In particular, one might argue that the current frame size cap is good also from a UX perspective: ideally, we would like users to start using xray without waiting to download the entire tree structure of the remote workspace. Thus, one thought could be to send tree nodes to remote clients in a depth-first (or breadth-first maybe?) fashion, as opposed to as a single huge payload.

As mentioned in last week's update, this week we are going to present a demo to some colleagues here at GitHub. As such, I don't think we are going to work on this bug before the end of the week. This is on our radar though and it will definitely be addressed at some point.

/cc: @nathansobo

@maxbrunsfeld
Copy link
Contributor

Also some keys don't seem to work, e.g. i cannot enter a new line.

I think this particular key binding has been added on master.

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

No branches or pull requests

3 participants