-
Notifications
You must be signed in to change notification settings - Fork 2.4k
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
SocketWriteBuffer repeats errors many times #13662
Comments
CamilleLetavernier
added a commit
to eclipsesource/theia
that referenced
this issue
Apr 29, 2024
CamilleLetavernier
added a commit
to eclipsesource/theia
that referenced
this issue
Apr 29, 2024
1 task
CamilleLetavernier
added a commit
to eclipsesource/theia
that referenced
this issue
Apr 29, 2024
- avoid logging the same error multiple times in SocketWriteBuffer. throw once, then silently ignore following issues. - export ReconnectableSocketChannel to make buffer customization easier for applications refs eclipse-theia#13662 Signed-off-by: Camille Letavernier <[email protected]>
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Bug Description:
When using reloadOnReconnect, and the client disconnects, we keep a cache for each active socket channel, with a 100kB buffer. Once this buffer is full, an error is thrown:
Max disconnected buffer size exceeded by adding 50186 bytes
Then, the same error is repeated whenever a message is posted to this same channel, which results in a potentially heavy log spam. Moreover, the classes involved use
protected
methods, but are not actually exported, making it difficult to fix in specific applications (or to increase buffer size, etc).I think we need two steps to improve this:
Steps to Reproduce:
Note: the bug can be difficult to reproduce in Theia, because you need to hit the 100kB buffer limit with a single service, before the disconnected client session expires and the buffer is closed. This means that, with the default settings, you have 30 seconds to fill 100kB with a single service, which probably won't happen under normal conditions. This could however easily happen e.g. during a large build, which will generate many file system events.
1800000
for 30 minutes). This gives more time to reproduce the issueSocketWriteBuffer
and fill it with messages; the refreshed session will work as expected./services/remote-filesystem
change notifications.Max disconnected buffer size exceeded by adding ... bytes
will be logged many times, and logged again for every update after thatAdditional Information
The text was updated successfully, but these errors were encountered: