-
Notifications
You must be signed in to change notification settings - Fork 728
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
resource_manager: implement the token-consuming by client #6039
Conversation
Signed-off-by: husharp <jinhao.hu@pingcap.com>
[REVIEW NOTIFICATION] This pull request has been approved by:
To complete the pull request process, please ask the reviewers in the list to review by filling The full list of commands accepted by this bot can be found here. Reviewer can indicate their review by submitting an approval review. |
Hi @HuSharp. Thanks for your PR. I'm waiting for a tikv member to verify that this patch is reasonable to test. If it is, they should reply with Once the patch is verified, the new status will be reflected by the 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/test-infra repository. |
/ok-to-test |
Signed-off-by: husharp <jinhao.hu@pingcap.com>
Signed-off-by: husharp <jinhao.hu@pingcap.com>
Codecov ReportPatch coverage:
Additional details and impacted files@@ Coverage Diff @@
## master #6039 +/- ##
==========================================
- Coverage 74.94% 74.69% -0.26%
==========================================
Files 395 395
Lines 38770 38760 -10
==========================================
- Hits 29058 28953 -105
- Misses 7192 7259 +67
- Partials 2520 2548 +28
Flags with carried forward coverage won't be shown. Click here to find out more.
... and 36 files with indirect coverage changes Help us with your feedback. Take ten seconds to tell us how you rate us. Have a feature suggestion? Share it here. ☔ View full report in Codecov by Sentry. |
883415a
to
3ca42f5
Compare
Signed-off-by: husharp <jinhao.hu@pingcap.com>
3ca42f5
to
384406e
Compare
37b3a1e
to
ae36e6b
Compare
Signed-off-by: husharp <jinhao.hu@pingcap.com>
@@ -30,6 +30,7 @@ const ( | |||
const ( | |||
defaultReserveRatio = 0.05 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Now that we've implemented slot, can we make defaultReserveRatio
bigger?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
modify to 0.5
Signed-off-by: husharp <jinhao.hu@pingcap.com>
Signed-off-by: husharp <jinhao.hu@pingcap.com>
Signed-off-by: husharp <jinhao.hu@pingcap.com>
if settings := group.GetRUSettings(); settings != nil { | ||
rg.RUSettings = NewRequestUnitSettings(settings.GetRU()) | ||
if group.GetRUSettings() == nil { | ||
rg.RUSettings = NewRequestUnitSettings(nil) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Will this cause some unexpect behavior?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I found CheckAndInit has redundant code and function with FromProtoResourceGroup,
So i replace CheckAndInit
with FromProtoResourceGroup
.
- for
CheckAndInit
can keep original logic - for other way which call
FromProtoResourceGroup
, if set nil, just keep it.
AndRequestRU
will check it.
So i think it will be ok.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
lgtm
/merge |
@nolouch: It seems you want to merge this PR, I will help you trigger all the tests: /run-all-tests 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. |
This pull request has been accepted and is ready to merge. Commit hash: 5d73b28
|
Signed-off-by: husharp <jinhao.hu@pingcap.com>
Signed-off-by: husharp <jinhao.hu@pingcap.com>
Signed-off-by: husharp <jinhao.hu@pingcap.com>
/merge |
@CabinfeverB: It seems you want to merge this PR, I will help you trigger all the tests: /run-all-tests 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. |
This pull request has been accepted and is ready to merge. Commit hash: ceec274
|
In response to a cherrypick label: new pull request created to branch |
close tikv#5947 - Introduce the token slot to balance the QPS within the same resource group. Signed-off-by: husharp <jinhao.hu@pingcap.com> Co-authored-by: Ti Chi Robot <ti-community-prow-bot@tidb.io>
close tikv#5947 - Introduce the token slot to balance the QPS within the same resource group. Signed-off-by: husharp <jinhao.hu@pingcap.com> Co-authored-by: Ti Chi Robot <ti-community-prow-bot@tidb.io> Signed-off-by: husharp <jinhao.hu@pingcap.com>
close tikv#5947 - Introduce the token slot to balance the QPS within the same resource group. Signed-off-by: Hu# <jinhao.hu@pingcap.com> Co-authored-by: Ti Chi Robot <ti-community-prow-bot@tidb.io>
What problem does this PR solve?
Issue Number: close #5947
What is changed and how does it work?
Check List
Tests
Code changes
Release note