News for hackers. Stuff that matters.
Re:Mummy – web server written in Nim that returns to the anc... by darthrupert on Saturday December 31, 2022 @09:23AM (#34196666)
This is great! Async still has its place for extremely low latency requirements, but threads should be good enough for almost every problem.
Re:Mummy – web server written in Nim that returns to the anc... by iroddis on Saturday December 31, 2022 @01:04PM (#34198939)
What kind of latency are you talking about? Async latency for completing a task isn’t deterministic, and there’s no guarantee data will be processed as soon as it becomes available. Async runtimes rely heavily on hints from their tasks as to when to poll next.

Generally, low latency means producing a result as soon as possible. Threads are ideal for that case, expending spinning cpu time for asap processing.

The best description I’ve heard of async is concurrent waiting, vs concurrent processing for threads (from the excellent zero2prod book).

Re:Mummy – web server written in Nim that returns to the anc... by zamalek on Saturday December 31, 2022 @01:32PM (#34199228)
What? The known/accepted tradeoff of async is gaining scalability (max concurrent connections) at the cost of latency.
Re:Mummy – web server written in Nim that returns to the anc... by darthrupert on Sunday January 01, 2023 @02:45AM (#34204467)
Indeed. Dunno what I was thinking there. Thanks for the correction!