On 11/24/2015 05:49 PM, Jaroslav Bachorik wrote:
Hi,
while working on an issue to clean up a code in java.base module using
reflection to access RuntimeMXBean (from java.management module) in
order to get hold of the VM arguments (yes, this won't work with
module boundaries in place) it was pointed out that this functionality
should be available in java.base without going through JMX.
Isn't the following JDK9 API already providing that:
ProcessHandle.current().info().arguments();
Regards, Peter
For this, java.lang.Runtime seems to be the right place to add such
functionality.
A new public method 'List<String> getVMArguments()' would be added
with the same functionality as is currently provided by
j.l.m.RuntimeMXBean#getInputArguments().
While the change seems to be rather non-controversional I would rather
discuss it before going further with the implementation and requesting
code review.
Thanks,
-JB-