Re:Using unwrap() in Rust is okay
by lmm on Monday August 08, 2022 @10:36PM
(#32393681)
That's actually kind of a myth nowadays. For example the honest answer to the classic C10K question (how do you write a webserver that can serve 10000 requests concurrently) is that you spawn 10k threads and let the OS scheduler handle it and it'll be fine.
[ Parent
| on HN ]
Re:Using unwrap() in Rust is okay
by preseinger on Tuesday August 09, 2022 @03:17PM
(#32402701)
Even a modern Linux kernel on modern hardware will struggle with 10k processes if those processes are doing nontrivial (i.e. syscall-effecting) work. But that benchmark is what, 10 or 15 years old now? Contemporary benchmarks target 100k connections per server (with some constraints).
The question, rather, is whether it'll struggle with 10k threads.
Re:Using unwrap() in Rust is okay
by preseinger on Friday August 12, 2022 @10:06PM
(#32446279)
Aye, the cost of context switching between OS threads is generally too high for thread-per-request workloads.