txnkv: add readPoolTaskDetails to SnapshotRuntimeStats (#2025)#2030
Conversation
|
@lcwangchao This PR has conflicts, I have hold it. |
|
Important Review skippedAuto reviews are disabled on base/target branches other than the default branch. Please check the settings in the CodeRabbit UI or the ⚙️ Run configurationConfiguration used: defaults Review profile: CHILL Plan: Pro Plus Run ID: You can disable this status message by setting the Use the checkbox below for a quick retry:
✨ Finishing Touches🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
|
/unhold |
|
/retest |
56dd220 to
7582747
Compare
ref tidbcloud/cloud-storage-engine#5480 Signed-off-by: ti-chi-bot <ti-community-prow-bot@tidb.io> Signed-off-by: Chao Wang <cclcwangchao@hotmail.com>
Signed-off-by: Chao Wang <cclcwangchao@hotmail.com>
Signed-off-by: Chao Wang <cclcwangchao@hotmail.com>
7582747 to
c992c2f
Compare
|
[APPROVALNOTIFIER] This PR is APPROVED This pull-request has been approved by: cfzjywxk, lcwangchao The full list of commands accepted by this bot can be found here. The pull request process is described here DetailsNeeds approval from an approver in each of these files:
Approvers can indicate their approval by writing |
[LGTM Timeline notifier]Timeline:
|
This is an automated cherry-pick of #2025
What problem does this PR solve?
Issue Number: ref https://github.com/tidbcloud/cloud-storage-engine/issues/5480
Problem Summary:
TiKV/CSE can now return optional request-level read-pool scheduling and execution metrics in
ExecDetailsV2.read_pool_task_details. client-go currently drops these details, so TiDB and other downstream consumers cannot include read-pool queueing, wakeup, dispatch/poll, and CPU/wall-time breakdowns in snapshot runtime diagnostics.What is changed and how it works?
PoolTaskDetailstoExecDetailsV2.util.PoolTaskDetailsto aggregate reported task samples, including:read_pool_task_detailsfrom responses intoSnapshotRuntimeStats.GetReadPoolTaskDetails()as a defensive copy so callers cannot mutate the stored runtime stats.The aggregation operates on reported response samples because the protobuf currently carries no task identity or delta information.
Check List
go test ./util ./txnkv/txnsnapshotgo test --tags=intest ./util ./txnkv/txnsnapshotread_pool_task_detailsis absent.Related changes
Summary by CodeRabbit