使用JConsole连接spring boot 服务

使用JConsole连接spring boot 服务


JConsole 是一个内置 Java 性能分析器,用于对JVM中内存,线程和类等的监控。
java基础入门的时候就会接触这个工具,那么如何使用JConsole来连接spring boot服务呢
其实很简单,只需要在启动服务的时候加入如下参数即可:

-Dcom.sun.management.jmxremote -Dcom.sun.management.jmxremote.port="6017"
-Dcom.sun.management.jmxremote.authenticate="false"
-Dcom.sun.management.jmxremote.ssl="false"

然后win+r打开jconsole
点击链接
点击连接即可连接上spring boot服务。

猜你喜欢

转载自blog.csdn.net/weixin_43186603/article/details/85245701