Re: RFR: 8160950 Agent JAR added to app class loader rather than system class loader when running with -Djava.system.class.loader

2016-09-08 Thread serguei.spit...@oracle.com
Mandy, Thank you for the review. On 9/8/16 14:55, Mandy Chung wrote: On Sep 7, 2016, at 12:27 PM, serguei.spit...@oracle.com wrote: Webrev: http://cr.openjdk.java.net/~sspitsyn/webrevs/2016/jdk/8160950-JLI-WLS.jdk2/ CustomLoader.java 62 File f = new

Re: RFR: 8160950 Agent JAR added to app class loader rather than system class loader when running with -Djava.system.class.loader

2016-09-08 Thread Mandy Chung
> On Sep 7, 2016, at 12:27 PM, serguei.spit...@oracle.com wrote: > > Webrev: > http://cr.openjdk.java.net/~sspitsyn/webrevs/2016/jdk/8160950-JLI-WLS.jdk2/ CustomLoader.java 62 File f = new File(System.getProperty("test.classes", "."), "Agent.class”); CustomLoader should

Re: RFR: 8160950 Agent JAR added to app class loader rather than system class loader when running with -Djava.system.class.loader

2016-09-08 Thread serguei.spit...@oracle.com
Thank you for the review, Alan! Serguei On 9/8/16 05:59, Alan Bateman wrote: On 07/09/2016 20:27, serguei.spit...@oracle.com wrote: Please, review the fix for: https://bugs.openjdk.java.net/browse/JDK-8160950 Webrev:

Re: RFR: 8160950 Agent JAR added to app class loader rather than system class loader when running with -Djava.system.class.loader

2016-09-08 Thread Alan Bateman
On 07/09/2016 20:27, serguei.spit...@oracle.com wrote: Please, review the fix for: https://bugs.openjdk.java.net/browse/JDK-8160950 Webrev: http://cr.openjdk.java.net/~sspitsyn/webrevs/2016/jdk/8160950-JLI-WLS.jdk2/ I think the changes are okay. A simpler custom ClassLoader would be to

Re: RFR: 8160950 Agent JAR added to app class loader rather than system class loader when running with -Djava.system.class.loader

2016-09-08 Thread Alan Bateman
On 08/09/2016 11:06, David Holmes wrote: Okay so ... that means this: JvmtiEnv::AddToSystemClassLoaderSearch(const char* segment) { jvmtiPhase phase = get_phase(); if (phase == JVMTI_PHASE_ONLOAD) { for (SystemProperty* p = Arguments::system_properties(); p != NULL; p = p->next())

Re: RFR: 8160950 Agent JAR added to app class loader rather than system class loader when running with -Djava.system.class.loader

2016-09-08 Thread David Holmes
On 8/09/2016 7:52 PM, serguei.spit...@oracle.com wrote: Hi David, On 9/8/16 02:30, David Holmes wrote: Hi Serguei, To the review ... Thank you for looking at this! On 8/09/2016 5:27 AM, serguei.spit...@oracle.com wrote: Please, review the fix for:

Re: RFR: 8160950 Agent JAR added to app class loader rather than system class loader when running with -Djava.system.class.loader

2016-09-08 Thread serguei.spit...@oracle.com
Hi David, On 9/8/16 02:30, David Holmes wrote: Hi Serguei, To the review ... Thank you for looking at this! On 8/09/2016 5:27 AM, serguei.spit...@oracle.com wrote: Please, review the fix for: https://bugs.openjdk.java.net/browse/JDK-8160950 Webrev:

Re: RFR: 8160950 Agent JAR added to app class loader rather than system class loader when running with -Djava.system.class.loader

2016-09-08 Thread David Holmes
Hi Serguei, To the review ... On 8/09/2016 5:27 AM, serguei.spit...@oracle.com wrote: Please, review the fix for: https://bugs.openjdk.java.net/browse/JDK-8160950 Webrev: http://cr.openjdk.java.net/~sspitsyn/webrevs/2016/jdk/8160950-JLI-WLS.jdk2/

Re: RFR: 8160950 Agent JAR added to app class loader rather than system class loader when running with -Djava.system.class.loader

2016-09-08 Thread Alan Bateman
On 08/09/2016 09:36, David Holmes wrote: Confused again - the main class should not be loaded by the built-in App loader if a custom system loader was specified! The class path you specify to the java launcher is the application class path. The application class loader loads from that class

Re: RFR: 8160950 Agent JAR added to app class loader rather than system class loader when running with -Djava.system.class.loader

2016-09-08 Thread David Holmes
On 8/09/2016 5:44 PM, serguei.spit...@oracle.com wrote: On 9/8/16 00:38, David Holmes wrote: On 8/09/2016 5:33 PM, serguei.spit...@oracle.com wrote: Hi David, On 9/8/16 00:22, David Holmes wrote: Hi Serguei, On 8/09/2016 5:27 AM, serguei.spit...@oracle.com wrote: Please, review the fix

Re: RFR: 8160950 Agent JAR added to app class loader rather than system class loader when running with -Djava.system.class.loader

2016-09-08 Thread Alan Bateman
On 08/09/2016 08:43, David Holmes wrote: I'd overlooked that the default system loader is used as the parent of the custom system loader. But it will be very confusing if you refer to the built-in loader as the "application" loader because the "application" loader and the "system" loader

Re: RFR: 8160950 Agent JAR added to app class loader rather than system class loader when running with -Djava.system.class.loader

2016-09-08 Thread serguei.spit...@oracle.com
On 9/8/16 00:38, David Holmes wrote: On 8/09/2016 5:33 PM, serguei.spit...@oracle.com wrote: Hi David, On 9/8/16 00:22, David Holmes wrote: Hi Serguei, On 8/09/2016 5:27 AM, serguei.spit...@oracle.com wrote: Please, review the fix for: https://bugs.openjdk.java.net/browse/JDK-8160950

Re: RFR: 8160950 Agent JAR added to app class loader rather than system class loader when running with -Djava.system.class.loader

2016-09-08 Thread David Holmes
On 8/09/2016 5:38 PM, Alan Bateman wrote: On 08/09/2016 08:22, David Holmes wrote: Hi Serguei, On 8/09/2016 5:27 AM, serguei.spit...@oracle.com wrote: Please, review the fix for: https://bugs.openjdk.java.net/browse/JDK-8160950 Webrev:

Re: RFR: 8160950 Agent JAR added to app class loader rather than system class loader when running with -Djava.system.class.loader

2016-09-08 Thread Alan Bateman
On 08/09/2016 08:22, David Holmes wrote: Hi Serguei, On 8/09/2016 5:27 AM, serguei.spit...@oracle.com wrote: Please, review the fix for: https://bugs.openjdk.java.net/browse/JDK-8160950 Webrev: http://cr.openjdk.java.net/~sspitsyn/webrevs/2016/jdk/8160950-JLI-WLS.jdk2/ Summary:

Re: RFR: 8160950 Agent JAR added to app class loader rather than system class loader when running with -Djava.system.class.loader

2016-09-08 Thread David Holmes
On 8/09/2016 5:33 PM, serguei.spit...@oracle.com wrote: Hi David, On 9/8/16 00:22, David Holmes wrote: Hi Serguei, On 8/09/2016 5:27 AM, serguei.spit...@oracle.com wrote: Please, review the fix for: https://bugs.openjdk.java.net/browse/JDK-8160950 Webrev:

Re: RFR: 8160950 Agent JAR added to app class loader rather than system class loader when running with -Djava.system.class.loader

2016-09-08 Thread serguei.spit...@oracle.com
Hi David, On 9/8/16 00:22, David Holmes wrote: Hi Serguei, On 8/09/2016 5:27 AM, serguei.spit...@oracle.com wrote: Please, review the fix for: https://bugs.openjdk.java.net/browse/JDK-8160950 Webrev: http://cr.openjdk.java.net/~sspitsyn/webrevs/2016/jdk/8160950-JLI-WLS.jdk2/ Summary:

Re: RFR: 8160950 Agent JAR added to app class loader rather than system class loader when running with -Djava.system.class.loader

2016-09-08 Thread David Holmes
Hi Serguei, On 8/09/2016 5:27 AM, serguei.spit...@oracle.com wrote: Please, review the fix for: https://bugs.openjdk.java.net/browse/JDK-8160950 Webrev: http://cr.openjdk.java.net/~sspitsyn/webrevs/2016/jdk/8160950-JLI-WLS.jdk2/ Summary: When running a java application with the options

RFR: 8160950 Agent JAR added to app class loader rather than system class loader when running with -Djava.system.class.loader

2016-09-07 Thread serguei.spit...@oracle.com
Please, review the fix for: https://bugs.openjdk.java.net/browse/JDK-8160950 Webrev: http://cr.openjdk.java.net/~sspitsyn/webrevs/2016/jdk/8160950-JLI-WLS.jdk2/ Summary: When running a java application with the options `-javaagent:myagent.jar -Djava.system.classloader=MyClassLoader` then