Summary
Change the default Console implementation returned by System.console()
from the JLine-based implementation to the built-in one in the java.base
module.
Problem
JDK has been using JLine based Console implementation, in JDK20 as opt-in, then in JDK22 as the default. While it has been providing rich functionality for Console, it is increasingly difficult to maintain as a Console implementation. Examples are terminal escape sequence handling (https://bugs.openjdk.org/browse/JDK-8348052) and signal handling (https://bugs.openjdk.org/browse/JDK-8346805)
Solution
In light of the on-ramp feature (https://bugs.openjdk.org/browse/JDK-8344699), which proposes switching the java.lang.IO
class to use System.in
and System.out
instead of Console, reverting the default Console implementation to JDK's built-in one in the java.base
module is considered desirable.
Specification
N/A. Behavior change only.
- csr of
-
JDK-8351435 Change the default Console implementation back to the built-in one in `java.base` module
-
- In Progress
-