Skip to content

util: record schedule wait duration of yatp pool#12441

Merged
ti-chi-bot merged 9 commits intotikv:masterfrom
sticnarf:pool-sched-duration-metrics
Jun 1, 2022
Merged

util: record schedule wait duration of yatp pool#12441
ti-chi-bot merged 9 commits intotikv:masterfrom
sticnarf:pool-sched-duration-metrics

Conversation

@sticnarf
Copy link
Contributor

@sticnarf sticnarf commented Apr 27, 2022

What is changed and how it works?

Issue Number: Close #12359

What's Changed:

This commit makes use of the `schedule_time` in yatp to calculate
the wait duration of each wake.

The wait duration panel is added to the grafana for the unified read
pool and the txn scheduler pool.

image

Check List

Tests

  • Unit test
  • Manual test

Release note

None

@ti-chi-bot
Copy link
Member

ti-chi-bot commented Apr 27, 2022

[REVIEW NOTIFICATION]

This pull request has been approved by:

  • cfzjywxk
  • you06

To complete the pull request process, please ask the reviewers in the list to review by filling /cc @reviewer in the comment.
After your PR has acquired the required number of LGTMs, you can assign this pull request to the committer in the list by filling /assign @committer in the comment to help you merge this pull request.

The full list of commands accepted by this bot can be found here.

Details

Reviewer can indicate their review by submitting an approval review.
Reviewer can cancel approval by submitting a request changes review.

@ti-chi-bot ti-chi-bot added do-not-merge/needs-linked-issue release-note Denotes a PR that will be considered when it comes time to generate release notes. do-not-merge/work-in-progress Indicates that a PR should not merge because it is a work in progress. size/M Denotes a PR that changes 30-99 lines, ignoring generated files. labels Apr 27, 2022
@sticnarf sticnarf force-pushed the pool-sched-duration-metrics branch from 1bdb281 to 5b3d28c Compare April 28, 2022 12:00
@sticnarf sticnarf force-pushed the pool-sched-duration-metrics branch from 5b3d28c to ff44ce0 Compare May 6, 2022 07:07
Signed-off-by: Yilin Chen <sticnarf@gmail.com>
@sticnarf sticnarf force-pushed the pool-sched-duration-metrics branch from ff44ce0 to 2d050a9 Compare May 6, 2022 08:00
@ti-chi-bot ti-chi-bot added size/L Denotes a PR that changes 100-499 lines, ignoring generated files. release-note-none Denotes a PR that doesn't merit a release note. and removed size/M Denotes a PR that changes 30-99 lines, ignoring generated files. do-not-merge/needs-linked-issue release-note Denotes a PR that will be considered when it comes time to generate release notes. labels May 6, 2022
@sticnarf sticnarf marked this pull request as ready for review May 6, 2022 08:05
@ti-chi-bot ti-chi-bot removed the do-not-merge/work-in-progress Indicates that a PR should not merge because it is a work in progress. label May 6, 2022
@sticnarf sticnarf requested review from cfzjywxk and you06 May 6, 2022 08:06
{
"exemplar": true,
"expr": "rate(tikv_yatp_pool_schedule_wait_duration_bucket{k8s_cluster=\"$k8s_cluster\", tidb_cluster=\"$tidb_cluster\", instance=~\"$instance\", name=~\"unified-read.*\"}[1m])",
"format": "heatmap",
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Should we add some avg and P99/max like lines or panels?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The unified read pool and scheduler pool are the most latency-critical pools. So, I use heatmap to show the distribution more clearly.

Now, I add avg and P99 lines to server, showing the wait duration of all pools

image

Signed-off-by: Yilin Chen <sticnarf@gmail.com>
@ti-chi-bot ti-chi-bot added size/XL Denotes a PR that changes 500-999 lines, ignoring generated files. and removed size/L Denotes a PR that changes 100-499 lines, ignoring generated files. labels May 6, 2022
Copy link
Collaborator

@cfzjywxk cfzjywxk left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@ti-chi-bot ti-chi-bot added the status/LGT1 Indicates that a PR has LGTM 1. label May 6, 2022
@ti-chi-bot ti-chi-bot added status/LGT2 Indicates that a PR has LGTM 2. and removed status/LGT1 Indicates that a PR has LGTM 1. labels May 11, 2022
Copy link
Contributor Author

@sticnarf sticnarf left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

/merge

@ti-chi-bot
Copy link
Member

@sticnarf: It seems you want to merge this PR, I will help you trigger all the tests:

/run-all-tests

You only need to trigger /merge once, and if the CI test fails, you just re-trigger the test that failed and the bot will merge the PR for you after the CI passes.

If you have any questions about the PR merge process, please refer to pr process.

Details

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the ti-community-infra/tichi repository.

@sticnarf
Copy link
Contributor Author

/test

1 similar comment
@sticnarf
Copy link
Contributor Author

/test

@sticnarf
Copy link
Contributor Author

sticnarf commented Jun 1, 2022

/merge

@ti-chi-bot
Copy link
Member

@sticnarf: It seems you want to merge this PR, I will help you trigger all the tests:

/run-all-tests

You only need to trigger /merge once, and if the CI test fails, you just re-trigger the test that failed and the bot will merge the PR for you after the CI passes.

If you have any questions about the PR merge process, please refer to pr process.

Details

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the ti-community-infra/tichi repository.

@ti-chi-bot
Copy link
Member

This pull request has been accepted and is ready to merge.

DetailsCommit hash: b749520

@ti-chi-bot ti-chi-bot added the status/can-merge Indicates a PR has been approved by a committer. label Jun 1, 2022
@sticnarf
Copy link
Contributor Author

sticnarf commented Jun 1, 2022

/test

@ti-chi-bot
Copy link
Member

@sticnarf: Your PR was out of date, I have automatically updated it for you.

At the same time I will also trigger all tests for you:

/run-all-tests

If the CI test fails, you just re-trigger the test that failed and the bot will merge the PR for you after the CI passes.

Details

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the ti-community-infra/tichi repository.

@sticnarf
Copy link
Contributor Author

sticnarf commented Jun 1, 2022

/test

Signed-off-by: Yilin Chen <sticnarf@gmail.com>
@ti-chi-bot ti-chi-bot removed the status/can-merge Indicates a PR has been approved by a committer. label Jun 1, 2022
@sticnarf
Copy link
Contributor Author

sticnarf commented Jun 1, 2022

/merge

@ti-chi-bot
Copy link
Member

@sticnarf: It seems you want to merge this PR, I will help you trigger all the tests:

/run-all-tests

You only need to trigger /merge once, and if the CI test fails, you just re-trigger the test that failed and the bot will merge the PR for you after the CI passes.

If you have any questions about the PR merge process, please refer to pr process.

Details

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the ti-community-infra/tichi repository.

@ti-chi-bot
Copy link
Member

This pull request has been accepted and is ready to merge.

DetailsCommit hash: c9d8f22

@ti-chi-bot ti-chi-bot added the status/can-merge Indicates a PR has been approved by a committer. label Jun 1, 2022
@ti-chi-bot ti-chi-bot merged commit a5987f3 into tikv:master Jun 1, 2022
BusyJay added a commit to BusyJay/tikv that referenced this pull request Aug 12, 2022
This reverts commit a5987f3.

Signed-off-by: Jay Lee <BusyJayLee@gmail.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

release-note-none Denotes a PR that doesn't merit a release note. size/XL Denotes a PR that changes 500-999 lines, ignoring generated files. status/can-merge Indicates a PR has been approved by a committer. status/LGT2 Indicates that a PR has LGTM 2.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Scheduler: There's no conclusive way to determine the wait time of a request for scheduler worker

4 participants