Does the Reactor also transmit responses in addition to buffering requests? #3090
-
If I understand the docs/architecture.md document correctly, Puma protects from slow clients by employing an async nio reactor that reads requests fully before handing them off to available worker threads for processing. Slow clients won't affect the worker thread pool and the number of concurrent slow clients is probably only limited by the available memory. But once the request is processed and the response needs to be transmitted, is this done by the worker thread or is there a nio reactor that handles transmitting responses to clients at their pace? Also an additional question, is the entire request, potential large body included, read by the reactor before the handoff with no exceptions? |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment 11 replies
-
Responses are not buffered in Puma, so the ThreadPool worker thread will send them to the client directly. The entire request is read by the reactor unless |
Beta Was this translation helpful? Give feedback.
Responses are not buffered in Puma, so the ThreadPool worker thread will send them to the client directly.
The entire request is read by the reactor unless
queue_requests
isfalse
.