Status Update
Comments
ri...@google.com <ri...@google.com> #2
ot...@google.com <ot...@google.com> #3
Hi Ali, thanks for the request.
Do you have any concrete use cases in mind for virtual threads on Android?
We are trying to align Android with the OpenJDK LTS releases: Android T is supporting a subset of OpenJDK 11 APIs, Android U will support a subset of OpenJDK 17 APIs.
ot...@google.com <ot...@google.com>
al...@gmail.com <al...@gmail.com> #4
Do you have any concrete use cases in mind for virtual threads on Android?
Well may not be a concrete use cases. I am developing a 3D game (for Desktop and Android) using jMonkeyEngine (Java 3D game engine). I was considering to use virtual threads for asset loading and client server comunications. The point is to have a sigle code base that works on both Desktop Java and Android.
Well there are some other cool features comming to Java in the future also, like project Valhalla,... I hope to see those feature supported on Android as well when they are released. It will be a great help for us to maintains a single code base.
Kind Regards
ot...@google.com <ot...@google.com> #5
Thanks Ali, this is a good data point.
As you expect we follow the JEPs and some of the discussions / announcements around future Java projects.
We are limited by the need to maintain app compatibility across releases and features like virtual threads and Valhalla are large changes with deep runtime integration: we may be able to offer forward compatible implementations when they are further along (e.g. available from some API level onwards). Whether we could desugar either proposal is a challenging proposition, for example, Android doesn't have legacy APIs that would support switching between virtual threads and carrying virtual thread state outside of the runtime itself and trying to integrate with I/O would likely be cumbersome.
al...@gmail.com <al...@gmail.com> #6
Yes, I understand that desugaring might be not possible for some of them. But being able to offer forward compatible implementations on future API releases is still great news.
gu...@gmail.com <gu...@gmail.com> #7
ji...@google.com <ji...@google.com>
ot...@google.com <ot...@google.com> #8
Thanks for the additional data point. We expect to do some evaluation of potential benefits / issues of virtual threads during the Android U timeframe. If that looks promising, we might expect an implementation for Android 16 and hopefully the upstream API will have finalised by then.
vi...@google.com <vi...@google.com>
ot...@google.com <ot...@google.com>
no...@gmail.com <no...@gmail.com> #9
so...@google.com <so...@google.com> #10
As per
In terms of timeline, Android currently (since 14) supports Java 17. Migration to Java 21 (the next LTS) will not be complete within the next release timeframe. So, as stated in
Description
Hi
Can you please add support for Java 19 virtual threads?
Regards