parser,ddl: add background job syntax and meta management for resource control#45189
parser,ddl: add background job syntax and meta management for resource control#45189ti-chi-bot[bot] merged 9 commits intopingcap:masterfrom
Conversation
|
Hi @glorv. Thanks for your PR. PRs from untrusted users cannot be marked as trusted with I understand the commands that are listed here. DetailsInstructions 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. |
| } | ||
|
|
||
| DirectResourceGroupBackgroundOption: | ||
| "TASK_NAMES" EqOpt stringLit |
There was a problem hiding this comment.
Is the task name an enumeration type? I find PD and TiDB won't check whether name is valid, user can't get feedback if the name is wrong.
There was a problem hiding this comment.
Yes, you can check the enum here. @CabinfeverB
https://github.com/tikv/client-go/pull/868/files#diff-6bd1a8e867c588123e135e97a8474639b648d9b6e4ab28c5b29338b388505dfbR41
There was a problem hiding this comment.
My main concern is that when setting the backgroup, if the user input is wrong, it will not report an error.
There was a problem hiding this comment.
Added a check in ddl api
|
@CabinfeverB @HuSharp @nolouch PTAL again, thanks |
| } | ||
| } | ||
| case ast.ResourceGroupBackground: | ||
| if groupInfo.Name.L != rg.DefaultResourceGroupName { |
There was a problem hiding this comment.
I noticed this restriction, so maybe need to update pr description?
There was a problem hiding this comment.
There is a NOTE in the PR description.
There was a problem hiding this comment.
oops, sorrrry! I must be blind!
parser/ast/ddl.go
Outdated
| ctx.WritePlain(", ") | ||
| } | ||
| if err := option.Restore(ctx); err != nil { | ||
| return errors.Annotatef(err, "An error occurred while splicing ResourceGroup Background Option") |
There was a problem hiding this comment.
Do we need to unify error with ResourceGroupRunaway to expose i?
| return errors.Annotatef(err, "An error occurred while splicing ResourceGroup Background Option") | |
| return errors.Annotatef(err, "An error occurred while splicing ResourceGroup Background Option: [%v]", i") |
parser/ast/ddl.go
Outdated
| ctx.WritePlain(" ") | ||
| } | ||
| if err := option.Restore(ctx); err != nil { | ||
| return errors.Annotatef(err, "An error occurred while splicing CreateResourceGroupStmt Option: [%v]", i) |
There was a problem hiding this comment.
| return errors.Annotatef(err, "An error occurred while splicing CreateResourceGroupStmt Option: [%v]", i) | |
| return errors.Annotatef(err, "An error occurred while splicing ResourceGroupRunaway Option: [%v]", i) |
|
@HuSharp: adding LGTM is restricted to approvers and reviewers in OWNERS files. DetailsIn response to this:
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. |
|
@glorv: The following test failed, say
Full PR test history. Your PR dashboard. DetailsInstructions 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. I understand the commands that are listed here. |
|
/retest |
|
@glorv: Cannot trigger testing until a trusted user reviews the PR and leaves an DetailsIn response to this:
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. |
|
@glorv: Cannot trigger testing until a trusted user reviews the PR and leaves an DetailsIn response to this:
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. |
|
[APPROVALNOTIFIER] This PR is APPROVED This pull-request has been approved by: 3pointer, HuSharp, nolouch 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 |
|
/hold |
|
@glorv: The following test failed, say
Full PR test history. Your PR dashboard. DetailsInstructions 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. I understand the commands that are listed here. |
|
/unhold |
What problem does this PR solve?
Issue Number: ref #44517
Problem Summary:
What is changed and how it works?
Resource control add new syntax for background tasks management as following:
NOTE: in the first phase, we only support changing the
defaultresource group's background config.Check List
Tests
Side effects
Documentation
Release note
Please refer to Release Notes Language Style Guide to write a quality release note.