Skip to content

Will web server libraries use virtual threads with 9.3.8.0? #7362

Answered by headius
mattwelke asked this question in Q&A
Discussion options

You must be logged in to vote

For frameworks that use Fibers (and Enumerators with next, which requires a Fiber) users will not have to do anything but enable virtual threads in the JVM to get those advantages. That means frameworks like async, and the defunct celluloid should "just work" and be able to scale out far more fibers than before.

As for what tools like web servers should do going foward... that depends how they want to achieve concurrency and parallelism.

Native threads (Thread.new threads in Ruby) will always get a "platform" thread and run in parallel so long as there's enough cores. Virtual threads (Fiber.new in Ruby) may run in parallel with native threads (Ruby ties each Fiber to one parent platform t…

Replies: 1 comment 2 replies

Comment options

You must be logged in to vote
2 replies
@mattwelke
Comment options

@headius
Comment options

Answer selected by headius
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants