Open andrewazores opened 1 year ago
I think this happened when I was helping someone get Cryostat to discover and connect to an application, and the JMX ports were set up like I had written in this blog post:
https://quarkus.io/blog/monitoring-quarkus-jvm-mode-with-cryostat/
-Dcom.sun.management.jmxremote
-Dcom.sun.management.jmxremote.port=${RJMX_PORT}
-Dcom.sun.management.jmxremote.rmi.port=${RJMX_PORT}
-Djava.rmi.server.hostname=127.0.0.1
-Dcom.sun.management.jmxremote.authenticate=false
-Dcom.sun.management.jmxremote.ssl=false
-Dcom.sun.management.jmxremote.local.only=false
Where both the remote JMX and RMI ports were set to ex. 9091
.
Trimming these env vars down to simply:
-Dcom.sun.management.jmxremote.port=${RJMX_PORT}
-Dcom.sun.management.jmxremote.ssl=false
-Dcom.sun.management.jmxremote.authenticate=false
resolved the issue.
I seem to remember using the original configuration successfully in the past, and I did document this in the linked blog post, so I don't know what the difference is compared to now. I need to verify that this is actually the root cause and a real fix for the problem, not just a heisenbug and a coincidence. If this is real then it would be good to understand why, and at least to document the updated requirements.
https://stackoverflow.com/questions/645208/java-rmi-nosuchobjectexception-no-such-object-in-table