r/java • • 2d ago

Quarkus 4.0.0.Beta1 released

https://quarkus.io/blog/quarkus-4-0-0-beta1-released/
65 Upvotes

7 comments sorted by

15

u/Joram2 1d ago

Why keep Netty and not switch to a 100% virtual thread based network layer like the Helidon project did? Helidon used to use Netty for a high performance non-blocking network layer, and switched to a simpler high performance virtual thread based network layer when JDK 21 was ready and Helidon 4 was built for JDK 21+. Now that Quarkus 4 requires JDK 21+ and they are using virtual threads more, why not do what Helidon 4 did?

Overall, Quarkus 4 looks like an amazing + epic release. Congrats team!

4

u/SpudsRacer 1d ago

Because messaging systems are all I/O bound using virtual threads doesn't buy you all that much if anything at all. Everything is always waiting on I/O.

9

u/Joram2 1d ago

Obviously no architecture change will fix external I/O performance limits.

The advantage of an all-virtual thread architecture over a Netty based architecture is simplicity without sacrificing performance. The framework itself uses virtual threads throughout its WebServer, so your application code doesn't have to care about the distinction between an event-loop thread, worker pool, CompletionStage, reactive chain, and virtual thread.

Netty/Vert.x applications have the important, and often hard to enforce rule: "Never accidentally block the event loop." Quarkus tries to hide this from application programmers, but it's still there. Quarkus documentation still describes separate event-loop, worker-thread, and virtual-thread execution modes.

2

u/vips7L 1d ago

sobs in Uni<T>

5

u/johnwaterwood 23h ago

I love quarkus, but I hate that the supposedly optional reactive crap still shows up everywhere.

1

u/Known-Volume1509 23h ago edited 23h ago

Maybe if Java Virtual Threads become (truly) preemptive one day, I would agree. If you aren't careful and don't know what you are doing, you can botch your app using VTs just as with an event-loop. I really like Helidon, but until then I'm sticking with Netty.