I'm build up a deployment where I've got many java processes on one machine. I'd like to be able to connect to their JMX mbeans from the comfort of my laptop.
To do this, I'm apparently faced with two choices:
I don't really like either, so I'm hoping that someone can offer me one or more others that I haven't thought of yet. Is there any way for code inside the process to interact with the JMX agent and enable, and set the port for, remote access? Then I could at least use my service backbone to negotiate port assignments for all of these processes.
Could consider starting a JMX client locally as a proxy so you only have a single port
Use the attach API to connect to all the local JVM's with active MBean servers running This way no JVM's need remote access configured except your proxy instance.
Don't expect it will be easy to find off the shelf, so there will be some coding involved. Perhaps this will give you a head start.
http://blogs.oracle.com/jmxetc/entry/proxying_a_jmx_connection_adapting
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.