RFR: 8358686: CDS and AOT can cause buffer truncation warning even when logging is disabled

Yudi Zheng yzheng at openjdk.org
Wed Jun 18 08:51:03 UTC 2025


When CDS and AOT loggings are disabled, HotSpot may still warn about `Mismatched values for property jdk.module.addexports:`. This warn message could be large and exceeds the current logging buffer length, and it leads to a non-informative message:

Java HotSpot(TM) 64-Bit Server VM warning: outputStream::do_vsnprintf output truncated -- buffer length is 2000 bytes but 4276 bytes are needed.

This PR skips reporting loading error when CDS and AOT loggings are disabled.

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

Commit messages:
 - CDS and AOT can cause buffer truncation warning even when logging is disabled

Changes: https://git.openjdk.org/jdk/pull/25866/files
  Webrev: https://webrevs.openjdk.org/?repo=jdk&pr=25866&range=00
  Issue: https://bugs.openjdk.org/browse/JDK-8358686
  Stats: 4 lines in 1 file changed: 4 ins; 0 del; 0 mod
  Patch: https://git.openjdk.org/jdk/pull/25866.diff
  Fetch: git fetch https://git.openjdk.org/jdk.git pull/25866/head:pull/25866

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


More information about the hotspot-runtime-dev mailing list