Java 21 is already here and it includes tons of performance updates we can get for free by just changing the JVM at runtime. Remember that issues that prevent Pinot to run with Java > 15 were solved before summer (see #10528). The objective of this issue is to discuss about the changes we want to make in order to support Java 21 in Apache Pinot.
To be clear, Apache Pinot should work with Java 21 as it is right now, but we don't run any test in Java 21 and we don't provide any docker image that uses Java 21.
Current state
The current state of Apache Pinot in relation to Java version is:
- Most of the source code must be compilable with Java 11. There are some Maven modules that must be compilable with Java 8 (mainly clients and their dependencies)
- We provide docker images running with Java 11 and 17.
- Our pipelines compile the source code using Java 11, 17 and 20.
- Our pipelines run tests with Java 11, 17 and 20.
Java 21
Being close to their release, we tried to add Java 21 to Apache Pinot pipelines during the changes applied early June, but we found out that there were some Maven plugins that didn't support that. Therefore we decided to test with Java 20 instead. It would be nice to be able to at least run the tests with Java 21, even if the code is compiled with an older version of Java.
If you try to compile the project with Java 21 as it is today, you will find issues with, at least:
It is also important to know that although Java 21 was released in Sept 19th, as today the only Java distribution we use that provide docker images for Java 21 is Amazon Corretto. The other two (Temurin and Microsoft) do not.
Plan
At short term
Given that it seems we cannot run all our pipeline with Java 21, we need to:
At long term
Java 21 is already here and it includes tons of performance updates we can get for free by just changing the JVM at runtime. Remember that issues that prevent Pinot to run with Java > 15 were solved before summer (see #10528). The objective of this issue is to discuss about the changes we want to make in order to support Java 21 in Apache Pinot.
To be clear, Apache Pinot should work with Java 21 as it is right now, but we don't run any test in Java 21 and we don't provide any docker image that uses Java 21.
Current state
The current state of Apache Pinot in relation to Java version is:
Java 21
Being close to their release, we tried to add Java 21 to Apache Pinot pipelines during the changes applied early June, but we found out that there were some Maven plugins that didn't support that. Therefore we decided to test with Java 20 instead. It would be nice to be able to at least run the tests with Java 21, even if the code is compiled with an older version of Java.
If you try to compile the project with Java 21 as it is today, you will find issues with, at least:
-Dspotless.skip. It seems they are working on supporting it in update palantirJavaFormat for Java 21 diffplug/spotless#1822.It is also important to know that although Java 21 was released in Sept 19th, as today the only Java distribution we use that provide docker images for Java 21 is Amazon Corretto. The other two (Temurin and Microsoft) do not.
Plan
At short term
Given that it seems we cannot run all our pipeline with Java 21, we need to:
At long term
UnsafePinotBufferFactory.