Re: [preview] Adding java.lang.Runtime.getVMArguments() method

2015-11-27 Thread Jaroslav Bachorik
On 26.11.2015 12:59, Jaroslav Bachorik wrote: On 26.11.2015 12:48, Jaroslav Bachorik wrote: On 25.11.2015 04:11, Mandy Chung wrote: > On Nov 24, 2015, at 6:24 PM, David Holmes wrote: > > On 25/11/2015 10:06 AM, Mandy Chung wrote: >> >>> On Nov 24, 2015, at 3:45 PM, Peter Levart wrote: >>> >>

Re: [preview] Adding java.lang.Runtime.getVMArguments() method

2015-11-26 Thread Jaroslav Bachorik
On 25.11.2015 04:11, Mandy Chung wrote: > On Nov 24, 2015, at 6:24 PM, David Holmes wrote: > > On 25/11/2015 10:06 AM, Mandy Chung wrote: >> >>> On Nov 24, 2015, at 3:45 PM, Peter Levart wrote: >>> >>> >>> >>> On 11/24/2015 05:49 PM, Jaroslav Bachorik wrote: Hi, while working on

Re: [preview] Adding java.lang.Runtime.getVMArguments() method

2015-11-26 Thread Jaroslav Bachorik
On 26.11.2015 12:48, Jaroslav Bachorik wrote: On 25.11.2015 04:11, Mandy Chung wrote: > On Nov 24, 2015, at 6:24 PM, David Holmes wrote: > > On 25/11/2015 10:06 AM, Mandy Chung wrote: >> >>> On Nov 24, 2015, at 3:45 PM, Peter Levart wrote: >>> >>> >>> >>> On 11/24/2015 05:49 PM, Jaroslav Bach

Re: [preview] Adding java.lang.Runtime.getVMArguments() method

2015-11-25 Thread Staffan Larsen
Also remember that that java launcher is not the only launcher used with the JVM. There are lots of apps that use the invocation API to start the JVM, and there is no standardized way to propagate the command line or even the Main-Class to the JVM. This is currently an outage in serviceability t

Re: [preview] Adding java.lang.Runtime.getVMArguments() method

2015-11-24 Thread Mandy Chung
> On Nov 24, 2015, at 6:24 PM, David Holmes wrote: > > On 25/11/2015 10:06 AM, Mandy Chung wrote: >> >>> On Nov 24, 2015, at 3:45 PM, Peter Levart wrote: >>> >>> >>> >>> On 11/24/2015 05:49 PM, Jaroslav Bachorik wrote: Hi, while working on an issue to clean up a code in java

Re: [preview] Adding java.lang.Runtime.getVMArguments() method

2015-11-24 Thread Roger Riggs
Hi, The ProcessHandle.current().info().arguments() has the operating system's view of the command and arguments. Which may differ from what is passed to main[] args. Perhaps for current() it should be special cased to exactly and always match main(args) but that's a different question. If t

Re: [preview] Adding java.lang.Runtime.getVMArguments() method

2015-11-24 Thread David Holmes
On 25/11/2015 10:06 AM, Mandy Chung wrote: On Nov 24, 2015, at 3:45 PM, Peter Levart wrote: 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 orde

Re: [preview] Adding java.lang.Runtime.getVMArguments() method

2015-11-24 Thread Mandy Chung
> On Nov 24, 2015, at 3:45 PM, Peter Levart wrote: > > > > 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

Re: [preview] Adding java.lang.Runtime.getVMArguments() method

2015-11-24 Thread Peter Levart
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

Re: [preview] Adding java.lang.Runtime.getVMArguments() method

2015-11-24 Thread mark . reinhold
2015/11/24 9:05 -0800, roger.ri...@oracle.com: > The arguments may contain sensitive information so the method will need > a SecurityManager > check and appropriate permission. Yes, definitely. > The method name should be more > appropriate; the JRE is not just

Re: [preview] Adding java.lang.Runtime.getVMArguments() method

2015-11-24 Thread Roger Riggs
Hi Jaroslav, The arguments may contain sensitive information so the method will need a SecurityManager check and appropriate permission. The method name should be more appropriate; the JRE is not just the VM. Perhaps commandArguments() or something that related to the process command arguments

[preview] Adding java.lang.Runtime.getVMArguments() method

2015-11-24 Thread Jaroslav Bachorik
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 avai