[Rev 08] RFR: 6656: Allow capturing field values with path syntax

Marcus Hirt hirt at openjdk.java.net
Thu Feb 6 09:13:07 UTC 2020


On Mon, 20 Jan 2020 15:26:11 GMT, Marcus Hirt <hirt at openjdk.org> wrote:

>> The pull request has been updated with a new target base due to a merge or a rebase.
> 
> core/org.openjdk.jmc.agent/src/main/java/org/openjdk/jmc/agent/Transformer.java line 72:
> 
>> 71: 				// Don't reuse this class loader instance. We want the loader and its class to unload after we're done.
>> 72: 				classBeingRedefined = new InspectionClassLoader(loader)
>> 73: 						.loadClass(TypeUtils.getCanonicalName(className));
> 
> We only need to parse/load the class if we are looking up fields. Can't we do this later, and only if we need it lazily? It's seems a bit premature to do it here in the Transformer.

@tabjy - did you have a chance to look at this?

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

PR: https://git.openjdk.java.net/jmc/pull/20


More information about the jmc-dev mailing list