mirror of
https://github.com/alibaba/arthas.git
synced 2024-04-21 10:21:39 +00:00
update trace.md
This commit is contained in:
@@ -20,9 +20,7 @@
|
||||
| `#cost` | 方法执行耗时 |
|
||||
| `[m <arg>]` | 指定 Class 最大匹配数量,默认值为 50。长格式为`[maxMatch <arg>]`。 |
|
||||
|
||||
这里重点要说明的是观察表达式,观察表达式的构成主要由 ognl 表达式组成,所以你可以这样写`"{params,returnObj}"`,只要是一个合法的 ognl 表达式,都能被正常支持。
|
||||
|
||||
观察的维度也比较多,主要体现在参数 `advice` 的数据结构上。`Advice` 参数最主要是封装了通知节点的所有信息。
|
||||
这里重点要说明的是`条件表达式`,`条件表达式`的构成主要由 ognl 表达式组成,所以你可以这样写`"params[0]<0"`,只要是一个合法的 ognl 表达式,都能被正常支持。
|
||||
|
||||
请参考[表达式核心变量](advice-class.md)中关于该节点的描述。
|
||||
|
||||
|
||||
@@ -20,9 +20,7 @@ Trace method calling path, and output the time cost for each node in the path.
|
||||
| #cost | time cost |
|
||||
| `[m <arg>]` | Specify the max number of matched Classes, the default value is 50. Long format is `[maxMatch <arg>]`. |
|
||||
|
||||
There's one thing worthy noting here is observation expression. The observation expression supports OGNL grammar, for example, you can come up a expression like this `"{params,returnObj}"`. All OGNL expressions are supported as long as they are legal to the grammar.
|
||||
|
||||
Thanks for `advice`'s data structure, it is possible to observe from varieties of different angles. Inside `advice` parameter, all necessary information for notification can be found.
|
||||
There's one thing worthy noting here is `condition expression`. The `condition expression` supports OGNL grammar, for example, you can come up a expression like this `"params[0]<0"`. All OGNL expressions are supported as long as they are legal to the grammar.
|
||||
|
||||
Pls. refer to [core parameters in expression](advice-class.md) for more details.
|
||||
|
||||
|
||||
Reference in New Issue
Block a user