RFR: 8301627: System.exit and Runtime.exit debug logging [v3]

Daniel Fuchs dfuchs at openjdk.org
Tue Feb 14 17:18:46 UTC 2023


On Tue, 14 Feb 2023 16:46:29 GMT, Roger Riggs <rriggs at openjdk.org> wrote:

>> It can be difficult to find the cause of calls to `java.lang.System.exit(status)` and `Runtime.exit(status)` because the Java runtime exits.
>> The status value and stack trace are logged using the System Logger named `java.lang.Runtime` with message level `System.Logger.Level.DEBUG`.
>
> Roger Riggs has updated the pull request incrementally with one additional commit since the last revision:
> 
>   Add an @implNote to Runtime.exit to describe the java.lang.Runtime logging.

src/java.base/share/classes/java/lang/Runtime.java line 160:

> 158:      *
> 159:      * @implNote
> 160:      * If the {@link System.Logger#getLogger(String) System.Logger.getLogger("java.lang.Runtime")}

The link looks wrong to me:
Suggestion:

     * If the {@link System#getLogger(String) System.getLogger("java.lang.Runtime")}

See https://docs.oracle.com/en/java/javase/19/docs/api/java.base/java/lang/System.html#getLogger(java.lang.String)

-------------

PR: https://git.openjdk.org/jdk/pull/12517


More information about the core-libs-dev mailing list