update doc

This commit is contained in:
hengyunabc committed 2020-08-11 00:46:35 +08:00
1 parent da7f56955b
commit da13c6dce1
193 files changed
+1699 -2068

No files matched your search

+2 -2
View File
@@ -135,8 +135,8 @@ Escape character is '^]'.
`--' `--'`--' '--' `--' `--' `--'`--' `--'`-----'
wiki https://alibaba.github.io/arthas
tutorials https://alibaba.github.io/arthas/arthas-tutorials
wiki https://arthas.aliyun.com/doc
tutorials https://arthas.aliyun.com/doc/arthas-tutorials.html
version 3.3.6
pid 58883
```
+1 -1
View File
@@ -27,7 +27,7 @@ watch com.alibaba.sample.petstore.web.store.module.screen.ItemList add "params +
为了避免这个问题,Arthas 3.0中使用了ognl这个更加轻量的表达式求值库来代替groovy,彻底解决了groovy引起的FGC风险。但由于这个替换,导致原来使用groovy脚本编写的自定义脚本失效。这个问题留待后续解决。
在3.0中,watch命令的表达式部分的书写有了一些改变,详见[这里](https://alibaba.github.io/arthas/watch)
在3.0中,watch命令的表达式部分的书写有了一些改变,详见[这里](https://arthas.aliyun.com/doc/watch)
#### 提升rt统计精度
+1 -1
View File
@@ -63,7 +63,7 @@ watch com.alibaba.sample.petstore.web.store.module.screen.ItemList add "params +
为了避免这个问题,Arthas 3.0中使用了ognl这个更加轻量的表达式求值库来代替groovy,彻底解决了groovy引起的FGC风险。但由于这个替换,导致原来使用groovy脚本编写的自定义脚本失效。这个问题留待后续解决。
在3.0中,watch命令的表达式部分的书写有了一些改变,详见[这里](https://alibaba.github.io/arthas/watch)
在3.0中,watch命令的表达式部分的书写有了一些改变,详见[这里](https://arthas.aliyun.com/doc/watch)
### 提升rt统计精度
Arthas 2.0中,统计rt都是以`ms`为单位,对于某些比较小的方法调用,耗时在毫秒以下的都会被认为是0ms,造成trace总时间和各方法的时间相加不一致等问题(虽然这里面确实会有误差,主要Arthas自身的开销)。Arthas 3.0中所有rt的单位统一改为使用`ns`来统计,精准捕获你的方法耗时,让0ms这样无意义的统计数据不再出现!
+6 -3
View File
@@ -1,6 +1,9 @@
Arthas异步调用
Arthas后台异步任务
===
arthas中的异步调用,使用了仿linux系统任务相关的命令。[linux任务相关介绍](https://ehlxr.me/2017/01/18/Linux-%E4%B8%AD-fg%E3%80%81bg%E3%80%81jobs%E3%80%81-%E6%8C%87%E4%BB%A4/)。
[`后台异步任务`在线教程](https://arthas.aliyun.com/doc/arthas-tutorials?language=cn&id=case-async-jobs)
arthas中的后台异步任务,使用了仿linux系统任务相关的命令。[linux任务相关介绍](https://ehlxr.me/2017/01/18/Linux-%E4%B8%AD-fg%E3%80%81bg%E3%80%81jobs%E3%80%81-%E6%8C%87%E4%BB%A4/)。
## 1. 使用&在后台执行任务
@@ -41,7 +44,7 @@ $ jobs
* 非当前session创建的job,只能由当前session fg到前台执行
## 5. 任务输出重定向
可通过`>`或者`>>`将任务输出结果输出到指定的文件中,可以和`&`一起使用,实现arthas命令的异步调用。比如:
可通过`>`或者`>>`将任务输出结果输出到指定的文件中,可以和`&`一起使用,实现arthas命令的后台异步任务。比如:
```bash
$ trace Test t >> test.out &
+1 -1
View File
@@ -1,7 +1,7 @@
cat
===
[`cat`在线教程](https://alibaba.github.io/arthas/arthas-tutorials?language=cn&id=command-cat)
[`cat`在线教程](https://arthas.aliyun.com/doc/arthas-tutorials.html?language=cn&id=command-cat)
> 打印文件内容,和linux里的cat命令类似。
+1 -1
View File
@@ -1,7 +1,7 @@
dashboard
===
[`dashboard`在线教程](https://alibaba.github.io/arthas/arthas-tutorials?language=cn&id=command-dashboard)
[`dashboard`在线教程](https://arthas.aliyun.com/doc/arthas-tutorials.html?language=cn&id=command-dashboard)
> 当前系统的实时数据面板,按 ctrl+c 退出。
+3 -3
View File
@@ -32,7 +32,7 @@ Docker
`--' `--'`--' '--' `--' `--' `--'`--' `--'`-----'
wiki: https://alibaba.github.io/arthas
wiki: https://arthas.aliyun.com/doc
version: 3.0.5
pid: 9
time: 2018-12-18 11:30:36
@@ -41,13 +41,13 @@ Docker
## 诊断Docker里的Java进程
```sh
docker exec -it ${containerId} /bin/bash -c "wget https://alibaba.github.io/arthas/arthas-boot.jar && java -jar arthas-boot.jar"
docker exec -it ${containerId} /bin/bash -c "wget https://arthas.aliyun.com/arthas-boot.jar && java -jar arthas-boot.jar"
```
## 诊断k8s里容器里的Java进程
```sh
kubectl exec -it ${pod} --container ${containerId} -- /bin/bash -c "wget https://alibaba.github.io/arthas/arthas-boot.jar && java -jar arthas-boot.jar"
kubectl exec -it ${pod} --container ${containerId} -- /bin/bash -c "wget https://arthas.aliyun.com/arthas-boot.jar && java -jar arthas-boot.jar"
```
## 把Arthas安装到基础镜像里
+2 -7
View File
@@ -5,12 +5,7 @@
### 从Maven仓库下载
最新版本,点击下载:[![](https://img.shields.io/maven-central/v/com.taobao.arthas/arthas-packaging.svg?style=flat-square "Arthas")](http://repository.sonatype.org/service/local/artifact/maven/redirect?r=central-proxy&g=com.taobao.arthas&a=arthas-packaging&e=zip&c=bin&v=LATEST)
如果下载速度比较慢,可以尝试用[阿里云的镜像仓库](https://maven.aliyun.com/),比如要下载`3.x.x`版本(替换`3.x.x`为最新版本),下载的url是:
https://maven.aliyun.com/repository/public/com/taobao/arthas/arthas-packaging/3.x.x/arthas-packaging-3.x.x-bin.zip
最新版本,点击下载:[![](https://img.shields.io/maven-central/v/com.taobao.arthas/arthas-packaging.svg?style=flat-square "Arthas")](https://arthas.aliyun.com/download/latest_version?mirror=aliyun)
### 从Github Releases页下载
@@ -49,5 +44,5 @@ java -jar arthas-boot.jar -h
## 下载离线文档
下载文档:[![](https://img.shields.io/maven-central/v/com.taobao.arthas/arthas-packaging.svg?style=flat-square "Arthas")](http://repository.sonatype.org/service/local/artifact/maven/redirect?r=central-proxy&g=com.taobao.arthas&a=arthas-packaging&e=zip&c=doc&v=LATEST)
下载文档:[![](https://img.shields.io/maven-central/v/com.taobao.arthas/arthas-packaging.svg?style=flat-square "Arthas")](https://arthas.aliyun.com/download/doc/latest_version?mirror=aliyun)
+11 -1
View File
@@ -1,6 +1,8 @@
dump
===
[`dump`在线教程](https://arthas.aliyun.com/doc/arthas-tutorials?language=cn&id=command-dump)
> dump 已加载类的 bytecode 到特定目录
### 参数说明
@@ -9,6 +11,7 @@ dump
|---:|:---|
|*class-pattern*|类名表达式匹配|
|`[c:]`|类所属 ClassLoader 的 hashcode|
|`[d:]`|设置类文件的目标目录|
|[E]|开启正则表达式匹配,默认为通配符匹配|
### 使用参考
@@ -26,4 +29,11 @@ $ dump demo.*
3d4eac69 +-sun.misc.Launcher$AppClassLoader@3d4eac69 /Users/admin/logs/arthas/classdump/sun.misc.Launcher$AppClassLoader-3d4eac69/demo/MathGame.class
+-sun.misc.Launcher$ExtClassLoader@66350f69
Affect(row-cnt:1) cost in 39 ms.
```
```
```bash
$ dump -d /tmp/output java.lang.String
HASHCODE CLASSLOADER LOCATION
null /tmp/output/java/lang/String.class
Affect(row-cnt:1) cost in 138 ms.
```
+1 -1
View File
@@ -1,7 +1,7 @@
echo
===
[`echo`在线教程](https://alibaba.github.io/arthas/arthas-tutorials?language=cn&id=command-echo)
[`echo`在线教程](https://arthas.aliyun.com/doc/arthas-tutorials.html?language=cn&id=command-echo)
> 打印参数,和linux里的echo命令类似。
+2
View File
@@ -1,6 +1,8 @@
getstatic
===
[`getstatic`在线教程](https://arthas.aliyun.com/doc/arthas-tutorials.html?language=cn&id=command-getstatic)
* 推荐直接使用[ognl](ognl.md)命令,更加灵活。
通过getstatic命令可以方便的查看类的静态属性。使用方法为`getstatic class_name field_name`
+2 -2
View File
@@ -1,7 +1,7 @@
grep
===
[`grep`在线教程](https://alibaba.github.io/arthas/arthas-tutorials?language=cn&id=command-grep)
[`grep`在线教程](https://arthas.aliyun.com/doc/arthas-tutorials.html?language=cn&id=command-grep)
> 类似传统的`grep`命令。
@@ -22,7 +22,7 @@ grep
thread | grep -m 10 -e "TIMED_WAITING|WAITING"
WIKI:
https://alibaba.github.io/arthas/grep
https://arthas.aliyun.com/doc/grep
OPTIONS:
-A, --after-context <value> Print NUM lines of trailing context)
+2
View File
@@ -1,6 +1,8 @@
heapdump
===
[`heapdump`在线教程](https://arthas.aliyun.com/doc/arthas-tutorials.html?language=cn&id=command-heapdump)
> dump java heap, 类似jmap命令的heap dump功能。
+4 -3
View File
@@ -1,7 +1,7 @@
Arthas 用户文档
===
**[English Docs](https://alibaba.github.io/arthas/en/)**
**[English Docs](https://arthas.aliyun.com/doc/en/)**
## Arthas(阿尔萨斯) 能为你做什么?
@@ -29,14 +29,15 @@ Contents
* [应届生招聘!](https://mp.weixin.qq.com/s/VVSc_a3mLELW35lMH7rR0Q)
* [社招信息!](https://mp.weixin.qq.com/s/677GO-3kYx5ygG9rlOlfQg)
* [技术征文!](https://developer.aliyun.com/article/751641)
* [English Docs](https://alibaba.github.io/arthas/en/)
* [在线教程(推荐)](https://alibaba.github.io/arthas/arthas-tutorials?language=cn)
* [English Docs](https://arthas.aliyun.com/doc/en/)
* [在线教程(推荐)](https://arthas.aliyun.com/doc/arthas-tutorials.html?language=cn)
* [安装](install-detail.md)
* [下载](download.md)
* [快速入门](quick-start.md)
* [进阶使用](advanced-use.md)
* [命令列表](commands.md)
* [WebConsole](web-console.md)
* [Http API](http-api.md)
* [Docker](docker.md)
* [Arthas Spring Boot Starter](spring-boot-starter.md)
* [用户案例](https://github.com/alibaba/arthas/issues?q=label%3Auser-case)
+4 -4
View File
@@ -8,7 +8,7 @@ Arthas Install
下载`arthas-boot.jar`,然后用`java -jar`的方式启动:
```bash
curl -O https://alibaba.github.io/arthas/arthas-boot.jar
curl -O https://arthas.aliyun.com/arthas-boot.jar
java -jar arthas-boot.jar
```
@@ -36,7 +36,7 @@ java -jar arthas-boot.jar -h
Arthas 支持在 Linux/Unix/Mac 等平台上一键安装,请复制以下内容,并粘贴到命令行中,敲 `回车` 执行即可:
```bash
curl -L https://alibaba.github.io/arthas/install.sh | sh
curl -L https://arthas.aliyun.com/install.sh | sh
```
上述命令会下载启动脚本文件 `as.sh` 到当前目录,你可以放在任何地方或将其加入到 `$PATH` 中。
@@ -53,7 +53,7 @@ curl -L https://alibaba.github.io/arthas/install.sh | sh
## 全量安装
最新版本,点击下载:[![](https://img.shields.io/maven-central/v/com.taobao.arthas/arthas-packaging.svg?style=flat-square "Arthas")](http://repository.sonatype.org/service/local/artifact/maven/redirect?r=central-proxy&g=com.taobao.arthas&a=arthas-packaging&e=zip&c=bin&v=LATEST)
最新版本,点击下载:[![](https://img.shields.io/maven-central/v/com.taobao.arthas/arthas-packaging.svg?style=flat-square "Arthas")](https://arthas.aliyun.com/download/latest_version?mirror=aliyun)
解压后,在文件夹里有`arthas-boot.jar`,直接用`java -jar`的方式启动:
@@ -103,7 +103,7 @@ as.sh
## 离线帮助文档
最新版本离线文档下载:[![](https://img.shields.io/maven-central/v/com.taobao.arthas/arthas-packaging.svg?style=flat-square "Arthas")](http://repository.sonatype.org/service/local/artifact/maven/redirect?r=central-proxy&g=com.taobao.arthas&a=arthas-packaging&e=zip&c=doc&v=LATEST)
最新版本离线文档下载:[![](https://img.shields.io/maven-central/v/com.taobao.arthas/arthas-packaging.svg?style=flat-square "Arthas")](https://arthas.aliyun.com/download/doc/latest_version?mirror=aliyun)
## 卸载
+1 -1
View File
@@ -1,7 +1,7 @@
jvm
===
[`sysenv`在线教程](https://alibaba.github.io/arthas/arthas-tutorials?language=cn&id=command-sysenv)
[`sysenv`在线教程](https://arthas.aliyun.com/doc/arthas-tutorials.html?language=cn&id=command-sysenv)
> 查看当前JVM信息
+1 -1
View File
@@ -1,7 +1,7 @@
Arthas 命令行快捷键
===
[`keymap`在线教程](https://alibaba.github.io/arthas/arthas-tutorials?language=cn&id=command-keymap)
[`keymap`在线教程](https://arthas.aliyun.com/doc/arthas-tutorials.html?language=cn&id=command-keymap)
`keymap`命令输出当前的快捷键映射表:
+3 -10
View File
@@ -6,14 +6,7 @@
1. 下载最新版本
**最新版本,点击下载**:[![](https://img.shields.io/maven-central/v/com.taobao.arthas/arthas-packaging.svg?style=flat-square "Arthas")](http://repository.sonatype.org/service/local/artifact/maven/redirect?r=central-proxy&g=com.taobao.arthas&a=arthas-packaging&e=zip&c=bin&v=LATEST)
如果下载速度比较慢,可以尝试用[阿里云的镜像仓库](https://maven.aliyun.com/),比如要下载`3.x.x`版本(替换`3.x.x`为最新版本),下载的url是:
https://maven.aliyun.com/repository/public/com/taobao/arthas/arthas-packaging/3.x.x/arthas-packaging-3.x.x-bin.zip
**最新版本,点击下载**:[![](https://img.shields.io/maven-central/v/com.taobao.arthas/arthas-packaging.svg?style=flat-square "Arthas")](https://arthas.aliyun.com/download/latest_version?mirror=aliyun)
2. 解压缩arthas的压缩包
```
@@ -46,7 +39,7 @@
Arthas 支持在 Linux/Unix/Mac 等平台上一键安装,请复制以下内容,并粘贴到命令行中,敲 `回车` 执行即可:
```bash
curl -L https://alibaba.github.io/arthas/install.sh | sh
curl -L https://arthas.aliyun.com/install.sh | sh
```
上述命令会下载启动脚本文件 `as.sh` 到当前目录,你可以放在任何地方或将其加入到 `$PATH` 中。
@@ -58,7 +51,7 @@ curl -L https://alibaba.github.io/arthas/install.sh | sh
### Windows
最新版本,点击下载:[![](https://img.shields.io/maven-central/v/com.taobao.arthas/arthas-packaging.svg?style=flat-square "Arthas")](http://repository.sonatype.org/service/local/artifact/maven/redirect?r=central-proxy&g=com.taobao.arthas&a=arthas-packaging&e=zip&c=bin&v=LATEST)
最新版本,点击下载:[![](https://img.shields.io/maven-central/v/com.taobao.arthas/arthas-packaging.svg?style=flat-square "Arthas")](https://arthas.aliyun.com/download/latest_version?mirror=aliyun)
下载解压后在bin目录有 `as.bat`。此脚本暂时只接受一个参数 pid,即只能诊断本机上的 Java 进程。(欢迎精通bat脚本的开发者改进)
+2
View File
@@ -1,6 +1,8 @@
mbean
=======
[`mbean`在线教程](https://arthas.aliyun.com/doc/arthas-tutorials.html?language=cn&id=command-mbean)
> 查看 Mbean 的信息
这个命令可以便捷的查看或监控 Mbean 的属性信息。
+2
View File
@@ -1,6 +1,8 @@
monitor
=======
[`monitor`在线教程](https://arthas.aliyun.com/doc/arthas-tutorials.html?language=cn&id=command-monitor)
> 方法执行监控
对匹配 `class-pattern`/`method-pattern`的类、方法的调用进行监控。
+35
View File
@@ -1,6 +1,8 @@
ognl
===
[`ognl`在线教程](https://arthas.aliyun.com/doc/arthas-tutorials?language=cn&id=command-ognl)
> 执行ognl表达式
从3.0.5版本增加
@@ -11,6 +13,7 @@ ognl
|---:|:---|
|*express*|执行的表达式|
|`[c:]`|执行表达式的 ClassLoader 的 hashcode,默认值是SystemClassLoader|
|`[classLoaderClass:]`|指定执行表达式的 ClassLoader 的 class name|
|[x]|结果对象的展开层次,默认值1|
@@ -50,6 +53,38 @@ $ ognl '@demo.MathGame@random'
]
```
通过hashcode指定ClassLoader:
```bash
$ classloader -t
+-BootstrapClassLoader
+-jdk.internal.loader.ClassLoaders$PlatformClassLoader@301ec38b
+-com.taobao.arthas.agent.ArthasClassloader@472067c7
+-jdk.internal.loader.ClassLoaders$AppClassLoader@4b85612c
+-org.springframework.boot.loader.LaunchedURLClassLoader@7f9a81e8
$ ognl -c 7f9a81e8 @org.springframework.boot.SpringApplication@logger
@Slf4jLocationAwareLog[
FQCN=@String[org.apache.commons.logging.LogAdapter$Slf4jLocationAwareLog],
name=@String[org.springframework.boot.SpringApplication],
logger=@Logger[Logger[org.springframework.boot.SpringApplication]],
]
$
```
注意hashcode是变化的,需要先查看当前的ClassLoader信息,提取对应ClassLoader的hashcode。
对于只有唯一实例的ClassLoader可以通过class name指定,使用起来更加方便:
```bash
$ ognl --classLoaderClass org.springframework.boot.loader.LaunchedURLClassLoader @org.springframework.boot.SpringApplication@logger
@Slf4jLocationAwareLog[
FQCN=@String[org.apache.commons.logging.LogAdapter$Slf4jLocationAwareLog],
name=@String[org.springframework.boot.SpringApplication],
logger=@Logger[Logger[org.springframework.boot.SpringApplication]],
]
```
执行多行表达式,赋值给临时变量,返回一个List:
```bash
+2
View File
@@ -1,6 +1,8 @@
options
===
[`options`在线教程](https://arthas.aliyun.com/doc/arthas-tutorials.html?language=cn&id=command-options)
> 全局开关
| 名称 | 默认值 | 描述 |
+1 -1
View File
@@ -1,7 +1,7 @@
perfcounter
===
[`perfcounter`在线教程](https://alibaba.github.io/arthas/arthas-tutorials?language=cn&id=command-perfcounter)
[`perfcounter`在线教程](https://arthas.aliyun.com/doc/arthas-tutorials.html?language=cn&id=command-perfcounter)
> 查看当前JVM的 Perf Counter信息
+1 -1
View File
@@ -1,7 +1,7 @@
pwd
===
[`pwd`在线教程](https://alibaba.github.io/arthas/arthas-tutorials?language=cn&id=command-pwd)
[`pwd`在线教程](https://arthas.aliyun.com/doc/arthas-tutorials.html?language=cn&id=command-pwd)
> 返回当前的工作目录,和linux命令类似
+3 -3
View File
@@ -4,7 +4,7 @@
## 1. 启动Demo
```bash
curl -O https://alibaba.github.io/arthas/arthas-demo.jar
curl -O https://arthas.aliyun.com/arthas-demo.jar
java -jar arthas-demo.jar
```
@@ -18,7 +18,7 @@ java -jar arthas-demo.jar
在命令行下面执行(使用和目标进程一致的用户启动,否则可能attach失败):
```bash
curl -O https://alibaba.github.io/arthas/arthas-boot.jar
curl -O https://arthas.aliyun.com/arthas-boot.jar
java -jar arthas-boot.jar
```
@@ -49,7 +49,7 @@ Demo进程是第2个,则输入2,再输入`回车/enter`。Arthas会attach到
`--' `--'`--' '--' `--' `--' `--'`--' `--'`-----'
wiki: https://alibaba.github.io/arthas
wiki: https://arthas.aliyun.com/doc
version: 3.0.5.20181127201536
pid: 71560
time: 2018-11-28 19:16:24
+1 -1
View File
@@ -1,7 +1,7 @@
reset命令
===
[`reset`在线教程](https://alibaba.github.io/arthas/arthas-tutorials?language=cn&id=command-reset)
[`reset`在线教程](https://arthas.aliyun.com/doc/arthas-tutorials.html?language=cn&id=command-reset)
> 重置增强类,将被 Arthas 增强过的类全部还原,Arthas 服务端`stop`时会重置所有增强过的类
+2
View File
@@ -1,6 +1,8 @@
执行结果存日志
===
[`执行结果存日志`在线教程](https://arthas.aliyun.com/doc/arthas-tutorials?language=cn&id=case-save-log)
> 将命令的结果完整保存在日志文件中,便于后续进行分析
* 默认情况下,该功能是关闭的,如果需要开启,请执行以下命令:
+2
View File
@@ -1,6 +1,8 @@
stack
===
[`stack`在线教程](https://arthas.aliyun.com/doc/arthas-tutorials.html?language=cn&id=command-stack)
> 输出当前方法被调用的调用路径
很多时候我们都知道一个方法被执行,但这个方法被执行的路径非常多,或者你根本就不知道这个方法是从那里被执行了,此时你需要的是 stack 命令。
+2 -2
View File
@@ -1,7 +1,7 @@
sysenv
=======================
[`sysenv`在线教程](https://alibaba.github.io/arthas/arthas-tutorials?language=cn&id=command-sysenv)
[`sysenv`在线教程](https://arthas.aliyun.com/doc/arthas-tutorials.html?language=cn&id=command-sysenv)
> 查看当前JVM的环境属性(`System Environment Variables`)
@@ -19,7 +19,7 @@ sysenv
sysenv USER
WIKI:
https://alibaba.github.io/arthas/sysenv
https://arthas.aliyun.com/doc/sysenv
OPTIONS:
-h, --help this help
+2 -2
View File
@@ -1,7 +1,7 @@
sysprop
=======================
[`sysprop`在线教程](https://alibaba.github.io/arthas/arthas-tutorials?language=cn&id=command-sysprop)
[`sysprop`在线教程](https://arthas.aliyun.com/doc/arthas-tutorials.html?language=cn&id=command-sysprop)
> 查看当前JVM的系统属性(`System Property`)
@@ -20,7 +20,7 @@ sysprop
sysprop production.mode true
WIKI:
https://alibaba.github.io/arthas/sysprop
https://arthas.aliyun.com/doc/sysprop
OPTIONS:
-h, --help this help
+2 -2
View File
@@ -1,7 +1,7 @@
tee
===
[`tee`在线教程](https://alibaba.github.io/arthas/arthas-tutorials?language=cn&id=command-tee)
[`tee`在线教程](https://arthas.aliyun.com/doc/arthas-tutorials.html?language=cn&id=command-tee)
> 类似传统的`tee`命令, 用于读取标准输入的数据,并将其内容输出成文件。
@@ -20,7 +20,7 @@ tee
sysprop | tee -a /path/to/logfile | grep java
WIKI:
https://alibaba.github.io/arthas/tee
https://arthas.aliyun.com/doc/tee
OPTIONS:
-a, --append Append to file
+1 -1
View File
@@ -1,7 +1,7 @@
thread
===
[`thread`在线教程](https://alibaba.github.io/arthas/arthas-tutorials?language=cn&id=command-thread)
[`thread`在线教程](https://arthas.aliyun.com/doc/arthas-tutorials.html?language=cn&id=command-thread)
> 查看当前线程信息,查看线程的堆栈
+2
View File
@@ -1,6 +1,8 @@
trace
===
[`trace`在线教程](https://arthas.aliyun.com/doc/arthas-tutorials.html?language=cn&id=command-trace)
> 方法内部调用路径,并输出方法路径上的每个节点上耗时
`trace` 命令能主动搜索 `class-pattern`/`method-pattern` 对应的方法调用路径,渲染和统计整个调用链路上的所有性能开销和追踪调用链路。
+2
View File
@@ -1,6 +1,8 @@
tt
===
[`tt`在线教程](https://arthas.aliyun.com/doc/arthas-tutorials.html?language=cn&id=command-tt)
> 方法执行数据的时空隧道,记录下指定方法每次调用的入参和返回信息,并能对这些不同的时间下调用进行观测
`watch` 虽然很方便和灵活,但需要提前想清楚观察表达式的拼写,这对排查问题而言要求太高,因为很多时候我们并不清楚问题出自于何方,只能靠蛛丝马迹进行猜测。
+1 -1
View File
@@ -1,7 +1,7 @@
vmoption
===
[`vmoption`在线教程](https://alibaba.github.io/arthas/arthas-tutorials?language=cn&id=command-vmoption)
[`vmoption`在线教程](https://arthas.aliyun.com/doc/arthas-tutorials.html?language=cn&id=command-vmoption)
> 查看,更新VM诊断相关的参数
+2
View File
@@ -1,6 +1,8 @@
watch
===
[`watch`在线教程](https://arthas.aliyun.com/doc/arthas-tutorials.html?language=cn&id=command-watch)
> 方法执行数据观测
让你能方便的观察到指定方法的调用情况。能观察到的范围为:`返回值`、`抛出异常`、`入参`,通过编写 OGNL 表达式进行对应变量的查看。
+3 -3
View File
@@ -1,7 +1,7 @@
Web Console
===
[`Web Console`在线教程](https://arthas.aliyun.com/doc/arthas-tutorials.html?language=cn&id=case-web-console)
### 通过浏览器连接arthas
@@ -64,8 +64,8 @@ attach成功之后,会打印出agentId,比如:
`--' `--'`--' '--' `--' `--' `--'`--' `--'`-----'
wiki https://alibaba.github.io/arthas
tutorials https://alibaba.github.io/arthas/arthas-tutorials
wiki https://arthas.aliyun.com/doc
tutorials https://arthas.aliyun.com/doc/arthas-tutorials.html
version 3.1.2
pid 86183
time 2019-08-30 15:40:53