[Feature] JMX Proxy - Attach to running JVM and make available remotely
Nobody has claimed this yet.
- Dominant language
- Java
- Stars
- 3.3k
- Forks
- 334
- PR merge metrics
- No merged PRs in 30d
Description
Feature Requests - JMX Proxy
I came across the blog post here that shows how to use jstatd to basically proxy connections to a running JVM from a remote VisualVM instance. How cool. But it is limited and I wish there was a way to do this w/ JMX. Sure, I could stop the JVM and add the jmxremote* JVM properties, but then I'd have to stop a Tomcat instance in this case.
I am not a Java Developer or I would take it on myself, but I presume the maintainers of VisualVM are java developers. Furthermore, a JMX proxy might be something other VisualVM users are interested in. Is this a feature/tool you would consider taking on?
Obligatory ASCII Art
+----Host----+ +--Workstation-+
||Target JVM|| | |
|| || | |
|| ^ || | |
|------------| | |
||Proxy|JVM--| +-VisualVM/ETC-+
|| + || || ||
|| ^--------TCP--------+ ||
|------------| |--------------|
+------------+ +--------------+
Example Usage
- Connect to remote machine
- Run
java -jar com.foo.jmx-proxy.jar -Djmx-proxy.localpid=1234 -Djmx-proxy.port=9999 -Djmx-proxy.address=localhost - SSH and tunnel 9999 to target box
- Start Visual VM on workstation, connect to localhost:9999
- Profit!
Thoughts
- Similar settings to
com.sun.management.jmxremote.*- Auth, ssl, port, server etc
- Maybe socks proxy support?
ssh -D - Instead of specifying PID could it be selectable like w/ jstatd+VisualVM
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
No repository files, tests, or entry points are named. Start by reviewing VisualVM's existing remote connection flow and the Java JMX remote settings described in the issue; done would require a defined proxy design, including attachment to a running JVM, remote access, authentication, SSL, and port configuration.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- java
- Domain
- devtools, observability
- Issue type
- Feature
- Difficulty
- 5/5
- Estimated time
- Over a week
- Activity status
- Stale
- Clarity
- Needs clarification
- Newbie friendliness
- 20/100