Skip to content
0:00 / 0:00

#kotlincoroutines#projectloom#virtualthreads

Coroutines and Loom behind the scenes by Roman Elizarov

Kotlin by JetBrains

100K subscribers • 61 videos on Hallway

YouTube
  • Recommended by 1 person: 1 on Hacker News.
  • Presented by Roman Elizarov, Kotlin Project Lead
  • Made by the vendor. The company whose product it covers made or sponsored it.

Intermediate. Assumes working knowledge.

40K views3 years ago1 recommendation

Programming languagesSystems programmingConcurrency and parallelismKotlinJava and the JVM

Roman Elizarov compares the design goals, implementation details, and performance tradeoffs of Kotlin Coroutines and OpenJDK's Project Loom.

Recording brought to you by American Express. americanexpress.io/kotlin-jobs OpenJDK Project Loom is in preview and will become stable any time soon. It offers seemingly similar benefits to Kotlin Coroutines, raising a lot of questions on Kotlin Coroutines and Project Loom coexistence and future. In this session, we'll examine and compare the goals that were put forth during the design of Kotlin Coroutines and Project Loom, we'll look behind the scenes into how these different goals translated into different implementations with different tradeoffs both in the programming model and in the performance. You'll learn which kind of applications should benefit most from the Kotlin Coroutines and from the Project Loom, respectively, how they'll coexist in the future, and where you can benefit from both of them. Talk by: Roman Elizarov #kotlinconf23 #Kotlin #Loom #KotlinConf

Why it's here

1 person recommends this

What people say. Recommended for its deep architectural comparison of stackless coroutines in Kotlin versus stackful virtual threads in Java's Project Loom.

Moments people linked to

dangetson Hacker News • Recommends

On “Java 21: First Release Candidate”

Here's a take from Roman Elizarov (Kotlin bias) - link to this video I imagine a lot of the missing structured concurrency will get built up over time on the Java side, but it is an interesting talk regardless.

Dewey Reedon Stack Overflow • Mentions

On “How to make "inappropriate blocking method call" appropriate?”

…t simply hides the warning. Update: From my personal experience, it appears suppressing the warning or runBlocking is more straightforward. Update2: After upgrading to Android Studio Flamingo(AGP 8), some warnings disappear; for those who don't, wrapping code in a withContext(Dispatchers.IO) sometimes remove the warning. A related explanation: link to this video…
12View the answer

gavinrayon Hacker News • Mentions

On “The compact overview of JDK 21’s “frozen” feature list”

Yeah, Kotlin does have the colored-function problem, in the same way that Node/JS has. Loom and Virtual Threads are one area I'm not as familiar with. What I do know is that you can configure virtual threads as the coroutine dispatcher for Kotlin coroutines, and in a recent video Roman Elizarov talked about how the default "Dispatchers.IO" could theoretically leverage VT's in some future JDK. link to this video

soulbadguyon Hacker News • Mentions

On “The compact overview of JDK 21’s “frozen” feature list”

> 5. Java with virtual threads now has far better support for async programming than Kotlin or Scala. It is now competitive with Golang in async ease-of-use green thread/stackfull coroutine such as in go/java and stackfless coroutine as in kotlin are well know solutions for introducing async programming in a way that feel natural to dev. They both have strength and limitation, i don't think one offer "far better support for async programming", and even more importantly they are not mutually exclusive and can be used together depending on one needs (see link to this video )

jillesvangurpon Hacker News • Mentions

On “Features of Project Loom incorporated in JDK 21”

…em a little faster with loom in place, which isn't a bad thing of course. But it doesn't really fix a problem I have. Being able to use threaded and blocking IO things in a non blocking way with no threads is going to be nice. Great if you are stuck with a lot of legacy stuff. Roman Elizarov addressed a few things regarding Loom at the last KConf: link to this video…

simon_voidon Hacker News • Mentions

On “Kotlin Coroutines vs. Threads Performance Benchmark”

here is the talk by Roman Elizarov, the Kotlin project lead, at KotlinConf 2023 about Coroutines vs VThreads: link to this video short version: both were optimized for different things, so there is a place for both of them.

u/daioin r/Kotlin • Mentions

On “When to start using coroutines (and threads)?”

There's no threshold or a number. Choosing between manual thread handling or coroutines depends on what the code does. They can both coexist in the same app. Checkout this talk by Roman Elizarov on project Loom(which is a lightweight thread initiative in Java, similar to coroutines, but with different purposes, lightweight threads still being threads): [video He talks about how these concepts can coexist and where they should be used.

u/Dodging12in r/Kotlin • Mentions

On “Kotlin in Action Second Edition available for pre-order on Amazon”

I actually just realized I meant Martin Moskala when I was talking about the book . Roman has a couple of good talks on coroutines that I enjoyed though. link to this video link to this video There's also a playlist of all of his stuff: link to this video

u/therealmczin r/Kotlin • Mentions

On “What was your most awful experience while using Kotlin?”

this is a very interesting speach regarding that topic: [video