Current state: Adopted
Discussion thread: link
Vote thread: link
- - KAFKA-12929Getting issue details... STATUS (3.0)
KAFKA-12894Getting issue details...
Please keep the discussion on the mailing list rather than commenting on the wiki (wiki discussions get unwieldy fast).
Kafka currently supports Java 8, 11 and 15 (soon to be 16). In other words, we support the two most recent LTS versions and the most recent non LTS version. Since we have to compile and run the tests on each supported version, there is a non-trivial cost from a development and testing perspective.
Java 17 will be released later this year and it will be a LTS release. To avoid supporting 4 Java releases once Java 18 is released, we would like to drop support for Java 8. However, there are additional considerations:
- Java 8 is still the most widely used Java version even though it was released in March 2014 (7 years ago). Java 11 was released in September 2018 (nearly 3 years ago).
- A deprecation period is required before we remove support for a given Java version and the removal should happen in a major Kafka release.
- Important projects we depend on may remove support for Java 8 before we do, which may result in challenges when it comes to updates required due to CVEs. One example is Jetty 10.
- It's often harder to upgrade the Java version in all applications than upgrade the Java version in services (eg brokers, connect, etc.).
We expect Apache Kafka 3.0 to be released around July/August 2021 and 4.0 will be at least 16 months after that. Given this and the above, we propose deprecating Java 8 support in Apache Kafka 3.0 and dropping support in Apache Kafka 4.0. Users will have ample time and warning to migrate away from Java 8.
- Deprecate Java 8 build in Kafka 3.0: update documentation including the downloads page.
- In Kafka 4.0:
- Remove all Java 8 specific code (including workarounds and conditional code based on the Java version).
- Update Readme and documentation (including the downloads page) not to mention Java 8 as a supported version.
Compatibility, Deprecation, and Migration Plan
Users who have not and cannot upgrade to Java 11 can continue to use Kafka 3.x until they can upgrade the given application or cluster. This can be done incrementally since the protocol is compatible independently of the Java version.
- Continue supporting Java 8 in the clients module.