RFR: 8311653: Modify -XshowSettings launcher behavior
Roger Riggs
rriggs at openjdk.org
Mon Jul 24 19:00:49 UTC 2023
On Mon, 24 Jul 2023 16:00:52 GMT, Sean Coffey <coffeys at openjdk.org> wrote:
> Modify the -XshowSettings launcher option to print non-verbose settings details of all components by default. Verbose settings details will be printed via the -XshowSettings:all option. Modify the -XshowSettings option to reject bad values passed to it. Print an error message in such scenarios and abort the VM launch.
src/java.base/share/classes/sun/launcher/LauncherHelper.java line 132:
> 130: *
> 131: * suboption values include "all", "locale", "properties", "security",
> 132: * "system"(Linux only) and "vm". Help message printed for bad value.
Suggestion:
* Suboption values include "all", "locale", "properties", "security",
* "system" (Linux only) and "vm". A help message is printed for an unknown suboption value.
src/java.base/share/classes/sun/launcher/LauncherHelper.java line 164:
> 162: case "system" -> printSystemMetrics();
> 163: case "vm" -> printVmSettings(initialHeapSize, maxHeapSize, stackSize);
> 164: case "" -> printAllSettings(false, initialHeapSize, maxHeapSize, stackSize);
There's mix in the arguments of where the "verbose" option is included.
Can they be consistent? (For example put the verbose option as the last argument).
src/java.base/share/classes/sun/launcher/LauncherHelper.java line 170:
> 168:
> 169: /*
> 170: * prints all available settings. Verbose option.
Don't take too many shortcuts in writing the description. Complete sentences are nice.
-------------
PR Review Comment: https://git.openjdk.org/jdk/pull/15001#discussion_r1272622823
PR Review Comment: https://git.openjdk.org/jdk/pull/15001#discussion_r1272627486
PR Review Comment: https://git.openjdk.org/jdk/pull/15001#discussion_r1272630327
More information about the core-libs-dev
mailing list