常用arthas命令

发布时间 2023-04-03 10:47:48作者: daheww

查看调用方法的堆栈

stack demo.MathGame primeFactors

方法内部调用路径,并输出方法路径上的每个节点上耗时

trace demo.MathGame run

观察函数调用返回时的参数、this 对象和返回值

watch demo.MathGame primeFactors


方法执行监控

monitor -c 5 demo.MathGame primeFactors

记录下指定方法每次调用的入参和返回信息

tt -t demo.MathGame primeFactors

当前系统的实时数据面板

dashboard

查看类的静态属性

getstatic demo.MathGame random

下载dump文档

heapdump

jvisualvm

查看当前 JVM 信息

jvm

查看 JVM 内存信息

memory

查看环境变量

sysenv

jvm的系统属性

sysprop