Robert Toyonaga

Results 100 comments of Robert Toyonaga

The Javadoc [here](https://github.com/oracle/graal/blob/a96025039f6c18d1d4031240c5ea4741356a5852/substratevm/src/com.oracle.svm.core/src/com/oracle/svm/core/jdk/management/ManagementSupport.java#L77-L78) says that the MBeanServer should be initialized at runtime. Is the intent here that the user, in their application code, manually initializes it by calling `ManagementFactory.getPlatformMBeanServer()`? Would...

It looks like [jdk.internal.agent.Agent](https://github.com/openjdk/jdk17/blob/master/src/jdk.management.agent/share/classes/jdk/internal/agent/Agent.java#L61) initializes the `JMXConnecterServer`. It also initializes the `MBeanServer` by calling `ManagementFactory.getPlatformMBeanServer()`. Hotspot calls on this class to do all the initialization if JMX is specified at...

After some basic experimenting, it seems like reusing the JDK infrastructure is possible. And it is also possible to do the `MBeanServer` and `JMXConnecterServer` initialization at runtime with a start-up...

Thanks Fabio! Yes I can give that a try. The reflection json file is about 600 lines (so maybe ~200 classes), but all the other config files are pretty small...

Doing all the configuration inside of a feature is working well. I am thinking of splitting the configuration for the client and server into 2 separate `Feature` classes. What do...

Ok I have created a draft PR here: https://github.com/oracle/graal/pull/4786 I added some comments to explain the current state of the work.

To reproduce the error you need to start any native image executable built with my branch using these runtime flags: `-Dcom.sun.management.jmxremote.authenticate=true -Dcom.sun.management.jmxremote.ssl=false -Dcom.sun.management.jmxremote.local.only=false -Dcom.sun.management.jmxremote.port=9999 -Dcom.sun.management.jmxremote.access.file=jmxremote/jmxremote.access -Dcom.sun.management.jmxremote.password.file=jmxremote/jmxremote.password `. This will enable...

> To reproduce the error you need to start any native image executable built with my branch using these runtime flags: `-Dcom.sun.management.jmxremote.authenticate=true -Dcom.sun.management.jmxremote.ssl=false -Dcom.sun.management.jmxremote.local.only=false -Dcom.sun.management.jmxremote.port=9999 -Dcom.sun.management.jmxremote.access.file=jmxremote/jmxremote.access -Dcom.sun.management.jmxremote.password.file=jmxremote/jmxremote.password `. This will...

I was linking the `libmanagement_agent` native library using `NativeLibraries.addStaticJniLibrary(String)` but its methods were not being recognized. I needed to use `PlatformNativeLibrarySupport.addBuiltinPkgNativePrefix(String)` to essentially register the prefix `jdk_internal_agent`. This way the...

I think the first iteration of the work is ready for review now. The associated PR is updated. Please let me know if the current approach is on the right...