Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

> I doubt anyone would switch to Java Virtual Threads anytime soon, unless via Kotlin.

Switching to virtual threads will, at least in the microservices I work with, involve changing a few lines (Executors.newUncachedThreadPool() -> Executors.newVirtualThreadPool()).

Switching to Kotlin coroutines will involve re-writing a large part of our codebase, which is why it hasn't been done.

It would surprise me if people didn't switch to Java Virtual Threads by the thousands when it comes out.



No you can use a few lines of kotlin coroutines in an otherwise java codebase.


The Java code being called, or calling, the Kotlin coroutine code also needs to be async in order to reap all the benefits. A Java codebase doing a lot of blocking calls can't just call some random Kotlin coroutine code and expect benefits, it has to be async all the way.




Consider applying for YC's Winter 2026 batch! Applications are open till Nov 10

Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: