-
Notifications
You must be signed in to change notification settings - Fork 1.2k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
*: add slow-query doc #849
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM
op-guide/tidb-config-file.md
Outdated
|
||
+ 慢查询日志的文件名。 | ||
+ 默认: "" | ||
+ 设置后,慢查询日志单独会输出到该文件。 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
单独会 -> 会单独
sql/slow-query.md
Outdated
|
||
# 慢查询日志 | ||
|
||
一个不合理的 SQL 语句会导致整个集群压力增大,响应变慢。对于这种问题,我们需要用慢查询日志来定位有问题的语句,解决性能问题。 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
一个 -> 一条
sql/slow-query.md
Outdated
|
||
### 获取 | ||
|
||
通过在 TiDB 的日志文件上 grep SLOW_QUERY 这个关键字, 可以得到执行时间超过 [slow-threshold](../op-guide/tidb-config-file.md#slow-threshold) 的语句日志。 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
SLOW_QUERY -> SLOW_QUERY
关键字, -> 关键字,(Please change the English comma to the Chinese comma.)
sql/slow-query.md
Outdated
|
||
一个不合理的 SQL 语句会导致整个集群压力增大,响应变慢。对于这种问题,我们需要用慢查询日志来定位有问题的语句,解决性能问题。 | ||
|
||
### 获取 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Add more details in this heading:
获取 -> 获取日志
sql/slow-query.md
Outdated
|
||
#### backoff_time | ||
|
||
表示语句遇到需要重试的错误,在重试前等待的时间,有很多种可能,常见的原因有遇到了 lock,region 分裂, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
- region -> Region
- In a Chinese text, use a Chinese back-sloping comma (顿号) to separate items in a list:
lock,region 分裂, -> lock、Region 分裂、 - Rewrite advice: 表示语句遇到需要重试的错误时在重试前等待的时间,遇到错误有几种常见的原因:lock、Region 分裂和 tikv server is busy 等。
sql/slow-query.md
Outdated
|
||
#### cost_time | ||
|
||
表示执行这个语句花费的时间。只有执行时间超过 slow-threshold |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
There are some redundant line breaks (换行符) in this document, please remove them.
sql/slow-query.md
Outdated
|
||
#### succ | ||
|
||
请求是否执行成功 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Keep consistent with the above descriptions below headings:
请求是否执行成功 -> 表示请求是否执行成功。
sql/slow-query.md
Outdated
|
||
#### con | ||
|
||
connection ID,即 session ID, 可以用类似 `con:3 ` 的关键字在日志中 grep 出 session ID 为 3 的日志。 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Please add "表示" at the beginning of every description sentences below and add the period (句号) if needed.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@yikeke |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM
via: pingcap/docs pingcap#849
No description provided.