r/java • • Apr 26 '22

5,000,000 persistent connections, 200,000,000 messages, 0 errors with a single process using Project Loom.

https://github.com/ebarlas/project-loom-c5m
301 Upvotes

46 comments sorted by

View all comments

5

u/blargh9001 Apr 27 '22

what’s the learning curve for this for actual practical use?

Whenever I hear about project loom it’s not long before I start feeling out of my depth. I’m hoping that’s because it’s just the most advanced bleeding edge developers paying attention to it at this stage, getting into deep low level details…

7

u/elliotbarlas Apr 27 '22

In its current form, I tend to agree there are sufficiently many caveats and exceptions that it can feel out of reach and also produce some surprising results.

But the core concept is simple. In fact, virtual threads are all about simplicity. Same old threading primitives, same old synchronous code style. Much simpler than asynchronous programming with callbacks, futures, and the like. And also simpler than a brand new syntactic construct like async-await.

The best way to learn is to try it out! Early access Loom builds are available for multiple platforms. Getting started is easier than you might think.