From f6b6f33708a0be642c2ce42ae0f11e6f9bac7b6c Mon Sep 17 00:00:00 2001 From: link2xt Date: Sat, 26 Oct 2024 20:23:20 +0000 Subject: [PATCH] fix: increase `request_queue_size` for UNIX sockets to 1000 Default value is 5. This setting was lost during refactoring in commit bf0f6e230352b9a05fa5b2e4ce59e511731f412e --- CHANGELOG.md | 3 +++ chatmaild/src/chatmaild/dictproxy.py | 6 +++++- 2 files changed, 8 insertions(+), 1 deletion(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index f514f513..adc929a8 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -2,6 +2,9 @@ ## untagged +- increase `request_queue_size` for UNIX sockets to 1000. + ([#437](https://github.com/deltachat/chatmail/pull/437)) + - query autoritative nameserver to bypass DNS cache ([#424](https://github.com/deltachat/chatmail/pull/424)) diff --git a/chatmaild/src/chatmaild/dictproxy.py b/chatmaild/src/chatmaild/dictproxy.py index 56f91c23..a0a7b654 100644 --- a/chatmaild/src/chatmaild/dictproxy.py +++ b/chatmaild/src/chatmaild/dictproxy.py @@ -87,8 +87,12 @@ def handle(self): except FileNotFoundError: pass - with ThreadingUnixStreamServer(socket, Handler) as server: + with CustomThreadingUnixStreamServer(socket, Handler) as server: try: server.serve_forever() except KeyboardInterrupt: pass + + +class CustomThreadingUnixStreamServer(ThreadingUnixStreamServer): + request_queue_size = 1000