summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--zellij-server/src/os_input_output.rs10
-rw-r--r--zellij-utils/src/ipc.rs3
2 files changed, 11 insertions, 2 deletions
diff --git a/zellij-server/src/os_input_output.rs b/zellij-server/src/os_input_output.rs
index 9c214b705..8e863af49 100644
--- a/zellij-server/src/os_input_output.rs
+++ b/zellij-server/src/os_input_output.rs
@@ -344,6 +344,16 @@ struct ClientSender {
impl ClientSender {
pub fn new(client_id: ClientId, mut sender: IpcSenderWithContext<ServerToClientMsg>) -> Self {
+ // FIXME(hartan): This queue is responsible for buffering messages between server and
+ // client. If it fills up, the client is disconnected with a "Buffer full" sort of error
+ // message. It was previously found to be too small (with depth 50), so it was increased to
+ // 5000 instead. This decision was made because it was found that a queue of depth 5000
+ // doesn't cause noticable increase in RAM usage, but there's no reason beyond that. If in
+ // the future this is found to fill up too quickly again, it may be worthwhile to increase
+ // the size even further (or better yet, implement a redraw-on-backpressure mechanism).
+ // We, the zellij maintainers, have decided against an unbounded
+ // queue for the time being because we want to prevent e.g. the whole session being killed
+ // (by OOM-killers or some other mechanism) just because a single client doesn't respond.
let (client_buffer_sender, client_buffer_receiver) = channels::bounded(5000);
std::thread::spawn(move || {
let err_context = || format!("failed to send message to client {client_id}");
diff --git a/zellij-utils/src/ipc.rs b/zellij-utils/src/ipc.rs
index 81d9e6c89..e76a21bd8 100644
--- a/zellij-utils/src/ipc.rs
+++ b/zellij-utils/src/ipc.rs
@@ -154,8 +154,7 @@ isn't performant enough.
There are a few things you can try now:
- Reattach to your previous session and see if it works out better this
time: {session_tip}
- - Try using a faster terminal. GPU-accelerated terminals such as Kitty
- or Alacritty are cross-platform and known to work well with zellij.
+ - Try using a faster (maybe GPU-accelerated) terminal emulator
"
)
},