Skip to content
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

scheduler: enhance output when scheduler config update #6927

Merged
merged 7 commits into from
Aug 31, 2023

Conversation

lhy1024
Copy link
Contributor

@lhy1024 lhy1024 commented Aug 9, 2023

What problem does this PR solve?

Issue Number: Close #4607

What is changed and how does it work?

  1. reduce unnecessary config check in pd-ctl.
  2. return result when run successfully
  3. add log when config changed

Check List

Tests

  • Unit test
  • Integration test
  • Manual test (add detailed scripts or steps below)
    image

Release note

None.

@ti-chi-bot
Copy link
Contributor

ti-chi-bot bot commented Aug 9, 2023

[REVIEW NOTIFICATION]

This pull request has been approved by:

  • HuSharp
  • nolouch

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.

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 bot added the release-note-none Denotes a PR that doesn't merit a release note. label Aug 9, 2023
@ti-chi-bot ti-chi-bot bot requested review from HunDunDM and rleungx August 9, 2023 11:07
@ti-chi-bot ti-chi-bot bot added the size/M Denotes a PR that changes 30-99 lines, ignoring generated files. label Aug 9, 2023
@lhy1024 lhy1024 changed the title scheduler: enhance scheduler config update scheduler: enhance output when scheduler config update Aug 9, 2023
@codecov
Copy link

codecov bot commented Aug 9, 2023

Codecov Report

Merging #6927 (8cf2243) into master (a7353bb) will increase coverage by 0.09%.
Report is 2 commits behind head on master.
The diff coverage is 72.22%.

❗ Current head 8cf2243 differs from pull request most recent head c36f8dd. Consider uploading reports for the commit c36f8dd to get more accurate results

@@            Coverage Diff             @@
##           master    #6927      +/-   ##
==========================================
+ Coverage   74.22%   74.32%   +0.09%     
==========================================
  Files         433      434       +1     
  Lines       46139    46073      -66     
==========================================
- Hits        34247    34242       -5     
+ Misses       8876     8821      -55     
+ Partials     3016     3010       -6     
Flag Coverage Δ
unittests 74.32% <72.22%> (+0.09%) ⬆️

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

server/api/scheduler_test.go Outdated Show resolved Hide resolved
@ti-chi-bot ti-chi-bot bot added size/L Denotes a PR that changes 100-499 lines, ignoring generated files. and removed size/M Denotes a PR that changes 30-99 lines, ignoring generated files. labels Aug 10, 2023
Signed-off-by: lhy1024 <[email protected]>
@lhy1024 lhy1024 requested a review from nolouch August 14, 2023 07:12
cmd.Println("priorities shouldn't be repeated")
return
}
input[key] = strings.Split(value, ",")
Copy link
Contributor

Choose a reason for hiding this comment

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

why remove it? I think the check priority should be one of [%s, %s, %s] is necessary.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

http interface will check it also

Copy link
Member

Choose a reason for hiding this comment

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

Can you point out the exact address which checked?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

func isPriorityValid(priorities []string) (map[string]bool, error) {

Copy link
Member

@HuSharp HuSharp left a comment

Choose a reason for hiding this comment

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

btw, I noticed there are too many api/v1/scheduler-config var, do we need to unify them?

pkg/schedule/schedulers/balance_witness.go Outdated Show resolved Hide resolved
pkg/schedule/schedulers/hot_region_config.go Outdated Show resolved Hide resolved
cmd.Println("priorities shouldn't be repeated")
return
}
input[key] = strings.Split(value, ",")
Copy link
Member

Choose a reason for hiding this comment

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

Can you point out the exact address which checked?

HuSharp

This comment was marked as duplicate.

Signed-off-by: lhy1024 <[email protected]>
Copy link
Contributor

@nolouch nolouch 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 bot added the status/LGT1 Indicates that a PR has LGTM 1. label Aug 31, 2023
Signed-off-by: lhy1024 <[email protected]>
Copy link
Member

@HuSharp HuSharp left a comment

Choose a reason for hiding this comment

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

LGTM! Thx for your work!

@ti-chi-bot ti-chi-bot bot added status/LGT2 Indicates that a PR has LGTM 2. and removed status/LGT1 Indicates that a PR has LGTM 1. labels Aug 31, 2023
@lhy1024
Copy link
Contributor Author

lhy1024 commented Aug 31, 2023

/merge

@ti-chi-bot
Copy link
Contributor

ti-chi-bot bot commented Aug 31, 2023

@lhy1024: 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.

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
Contributor

ti-chi-bot bot commented Aug 31, 2023

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

Commit hash: c36f8dd

@ti-chi-bot ti-chi-bot bot added the status/can-merge Indicates a PR has been approved by a committer. label Aug 31, 2023
@ti-chi-bot ti-chi-bot bot merged commit a0b2f3d into tikv:master Aug 31, 2023
19 checks passed
rleungx pushed a commit to rleungx/pd that referenced this pull request Dec 4, 2023
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/L Denotes a PR that changes 100-499 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.

No update logs when set balance-hot-region-scheduler attributes
3 participants