Skip to content

Conversation

D3Hunter
Copy link
Contributor

@D3Hunter D3Hunter commented Jan 15, 2025

What problem does this PR solve?

Issue Number: ref #57497

Problem Summary:

What changed and how does it work?

  • start a routine to detect and handle param modify for active running subtask, including concurrency and application specific param
  • add ResourceModified to notify application to adjust resource usage
  • will add integration test later, PR too large

Check List

Tests

  • Unit test
  • Integration test
  • Manual test (add detailed scripts or steps below)
  • No need to test
    • I checked and no code files have been changed.

Side effects

  • Performance regression: Consumes more CPU
  • Performance regression: Consumes more Memory
  • Breaking backward compatibility

Documentation

  • Affects user behaviors
  • Contains syntax changes
  • Contains variable changes
  • Contains experimental features
  • Changes MySQL compatibility

Release note

Please refer to Release Notes Language Style Guide to write a quality release note.

None

@ti-chi-bot ti-chi-bot bot added 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. labels Jan 15, 2025
Copy link

tiprow bot commented Jan 15, 2025

Hi @D3Hunter. Thanks for your PR.

PRs from untrusted users cannot be marked as trusted with /ok-to-test in this repo meaning untrusted PR authors can never trigger tests themselves. Collaborators can still trigger tests on the PR using /test all.

I understand the commands that are listed here.

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 kubernetes-sigs/prow repository.

Copy link

codecov bot commented Jan 15, 2025

Codecov Report

Attention: Patch coverage is 90.90909% with 10 lines in your changes missing coverage. Please review.

Project coverage is 73.7395%. Comparing base (4e1cf8a) to head (1417141).
Report is 19 commits behind head on master.

Additional details and impacted files
@@               Coverage Diff                @@
##             master     #58935        +/-   ##
================================================
+ Coverage   73.0706%   73.7395%   +0.6688%     
================================================
  Files          1683       1684         +1     
  Lines        465734     469481      +3747     
================================================
+ Hits         340315     346193      +5878     
+ Misses       104494     102378      -2116     
+ Partials      20925      20910        -15     
Flag Coverage Δ
integration 43.0948% <0.0000%> (?)
unit 72.5412% <90.9090%> (+0.2855%) ⬆️

Flags with carried forward coverage won't be shown. Click here to find out more.

Components Coverage Δ
dumpling 52.6910% <ø> (ø)
parser ∅ <ø> (∅)
br 45.2816% <ø> (-0.0180%) ⬇️

@D3Hunter
Copy link
Contributor Author

@lance6716

Copy link
Contributor

@lance6716 lance6716 left a comment

Choose a reason for hiding this comment

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

To check if the modification really take effect, we need to search for the log line? Do you design to add a more convenient way to query it?

@@ -78,6 +83,10 @@ func NewParamForTest(taskTable TaskTable, slotMgr *slotManager, nodeRc *NodeReso
// BaseTaskExecutor is the base implementation of TaskExecutor.
type BaseTaskExecutor struct {
Param
// this field represents the last task that we have refreshed from the system
Copy link
Contributor

Choose a reason for hiding this comment

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

I think the comment can be explained as

task is a local state of executor that periodically aligned with the state saved in system table.

@ti-chi-bot ti-chi-bot bot added approved needs-1-more-lgtm Indicates a PR needs 1 more LGTM. labels Jan 21, 2025
@D3Hunter
Copy link
Contributor Author

To check if the modification really take effect, we need to search for the log line? Do you design to add a more convenient way to query it?

as we have discussed, to check whether it takes effect, user can

  • check log
  • check dashboard, different param need to see different panel
    • such as for concurrency, user can check the CPU panel, or avaiable slots panel in DXF

Copy link

ti-chi-bot bot commented Jan 22, 2025

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: lance6716, wjhuang2016

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

The pull request process is described here

Needs approval from an approver in each of these files:

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@ti-chi-bot ti-chi-bot bot added lgtm and removed needs-1-more-lgtm Indicates a PR needs 1 more LGTM. labels Jan 22, 2025
Copy link

ti-chi-bot bot commented Jan 22, 2025

[LGTM Timeline notifier]

Timeline:

  • 2025-01-21 06:36:52.724045794 +0000 UTC m=+162740.054965198: ☑️ agreed by lance6716.
  • 2025-01-22 03:09:47.94921393 +0000 UTC m=+236715.280133333: ☑️ agreed by wjhuang2016.

@ti-chi-bot ti-chi-bot bot merged commit b9b9787 into pingcap:master Jan 22, 2025
24 checks passed
@D3Hunter D3Hunter deleted the dxf/modify-active-subtask branch January 22, 2025 04:02
zeminzhou pushed a commit to zeminzhou/tidb that referenced this pull request May 6, 2025
D3Hunter added a commit to D3Hunter/tidb that referenced this pull request Jun 30, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
approved lgtm 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.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants