googleapis/java-storage

Improve Virtual Thread compatibility

BenWhitehead opened this issue · 0 comments

With the release of Java 21 Virtual Threads are now a first class feature.

To better support the use of virtual threads in applications we will need to evaluate and update certain assumptions and aspects the library is built upon today.

Virtual Threads: An Adoption Guide outlines several considerations we should keep in mind when doing this work.

Items to investigate:

  1. Timeline for java 21 CI/CD infrastructure readiness
  2. synchronized method and blocks
  3. Existing locking strategies
  4. ExecutorService usage
  5. Context propagation with other libraries (OTel, OpenCensus)
  6. Parallel Stream usage
  7. other java.util.concurrent usages