Skip to content

Description of TSO - cmd and TSO - request is wrong in "Key Metrics on Performance Overview" #20612

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

Open
ekexium opened this issue Mar 21, 2025 · 3 comments

Comments

@ekexium
Copy link
Member

ekexium commented Mar 21, 2025

Error Report

Please answer the following questions before submitting your issue. Thanks!

  1. What is the URL/path of the document related to this issue?

https://docs.pingcap.com/tidb/stable/grafana-performance-overview-dashboard/#key-metrics-on-performance-overview

  1. How would you like to improve it?

TSO cmds are smaller units of operation. Multiple TSO commands can be batched into a single TSO request. Therefore, we should observe in the metrics that the number of TSO commands is greater than or equal to the number of TSO requests. However, the documentation describes this relationship incorrectly.

@Oreoxmt
Copy link
Collaborator

Oreoxmt commented Mar 21, 2025

@JmPotato Could you please help take a look at this issue regarding the incorrect description of tso - cmd and tso - request metrics?

For reference, here are the related changes about tso - cmd and tso - request: pingcap/docs-cn#18463 and #18722

@JmPotato
Copy link
Member

After checking the relevant code, I found that the description here is indeed incorrect.

For TSO - cmd, each TSO request future is recorded as the smallest unit:

https://github.com/tikv/pd/blob/cf6b4752e7cbb4e9a6692ce9c04ccd986f20bf36/client/clients/tso/request.go#L77-L102

For TSO - request, it is recorded for each gRPC request, which serves as the unit for batched requests:

https://github.com/tikv/pd/blob/cf6b4752e7cbb4e9a6692ce9c04ccd986f20bf36/client/clients/tso/stream.go#L435

@Oreoxmt
Copy link
Collaborator

Oreoxmt commented Mar 25, 2025

@JmPotato Could you please help submit a pull request to fix it?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants