News for hackers. Stuff that matters.
Re:Java 21 VirtualThreads vs. Clojure Lazy Seqs (from Clojur... by bcrosby95 on Friday October 06, 2023 @01:57PM (#37793888)
I can't think of a project I've worked on in the past 10 or so years that couldn't benefit from virtual threads. Right-sizing your thread pools in an environment with a lot of IO is/was a pain in the ass.

Many of the core concurrency constructs in Clojure has separate functions for when you are doing something that is blocking vs not blocking. If it were all virtual threads this distinction generally wouldn't matter.

Re:Java 21 VirtualThreads vs. Clojure Lazy Seqs (from Clojur... by Alupis on Friday October 06, 2023 @02:06PM (#37794040)
Not just that - the kicker is everything that already exists (libraries, JDBC drivers, etc) are now just automagically non-blocking too if you seed the thread pool with a virtual thread factory.

I can't remember the last time such a transparent, drop-in-able change was so impactful for just about everything.

While it doesn't remove the need for the event/reactive/async paradigm in all cases, it does removes the need for async code just for the sake of being non-blocking.

Code can now be written much more clearly, and still be non-blocking. That's huge.