resource control: support more mode for BURSTABLE#21138
resource control: support more mode for BURSTABLE#21138ti-chi-bot[bot] merged 14 commits intopingcap:masterfrom
Conversation
Signed-off-by: lhy1024 <admin@liudos.us>
There was a problem hiding this comment.
Hello @lhy1024, I'm Gemini Code Assist1! I'm currently reviewing this pull request and will post my feedback shortly. In the meantime, here's a summary to help you and other reviewers quickly get up to speed!
Summary of Changes
Hello! I'm gemini-code-assist, here to provide a summary of this pull request. This PR primarily focuses on updating the documentation related to TiDB's resource control feature. Specifically, it introduces and documents the support for more granular modes for the BURSTABLE option within resource groups. The changes involve updating the syntax descriptions for CREATE RESOURCE GROUP and ALTER RESOURCE GROUP statements, as well as clarifying the behavior and available modes (OFF, MODERATED, UNLIMITED) for BURSTABLE in the documentation for the INFORMATION_SCHEMA.RESOURCE_GROUPS table. Several examples showing the output of querying INFORMATION_SCHEMA.RESOURCE_GROUPS are also updated to reflect the new BURSTABLE output format and include columns for QUERY_LIMIT and BACKGROUND.
Highlights
- Documentation Updates: Documentation for
CREATE RESOURCE GROUP,ALTER RESOURCE GROUP, andINFORMATION_SCHEMA.RESOURCE_GROUPSis modified to include the newBURSTABLEmodes and their descriptions. - Example Updates: Examples showing the output of
SELECT * FROM information_schema.resource_groupsare updated to display the newBURSTABLEformat (e.g.,YES(UNLIMITED)) and include theQUERY_LIMITandBACKGROUNDcolumns.
Changelog
Click here to see the changelog
- information-schema/information-schema-resource-groups.md
- Updated example output for
DESC resource_groups;to includeQUERY_LIMITandBACKGROUNDcolumns and changeRU_PER_SECtype display frombigint(21)tovarchar(21)(lines 20-29). - Updated example output for
SELECT * FROM information_schema.resource_groups;to includeQUERY_LIMITandBACKGROUNDcolumns and showBURSTABLEasYES(UNLIMITED)for the default group (lines 40-44). - Updated example output for
SELECT * FROM information_schema.resource_groups WHERE NAME = 'rg1';to includeQUERY_LIMITandBACKGROUNDcolumns (lines 73-77). - Updated the description of the
BURSTABLEcolumn to explain theOFF,MODERATED, andUNLIMITEDmodes and clarify the default mode for thedefaultresource group (lines 86-90).
- Updated example output for
- sql-statements/sql-statement-alter-resource-group.md
- Updated the grammar definition for
ALTER RESOURCE GROUPto explicitly listMODERATED,UNLIMITED, andOFFas valid options forBURSTABLE(lines 36-38). - Updated the description table for
DirectResourceGroupOptionto explain the threeBURSTABLEmodes and the default behavior (lines 89). - Updated example output for
SELECT * FROM information_schema.resource_groups WHERE NAME ='default';to showBURSTABLEasYES(UNLIMITED)(lines 173-177).
- Updated the grammar definition for
- sql-statements/sql-statement-create-resource-group.md
- Updated the grammar definition for
CREATE RESOURCE GROUPto explicitly listMODERATED,UNLIMITED, andOFFas valid options forBURSTABLE(lines 36-38). - Updated the description table for
DirectResourceGroupOptionto explain the threeBURSTABLEmodes and the default behavior (lines 86). - Clarified the default
BURSTABLEmode for thedefaultresource group isUNLIMITEDin the note section (line 92). - Added a new example for creating a resource group with
BURSTABLE=UNLIMITED(lines 206-210). - Updated example output for
SELECT * FROM information_schema.resource_groups WHERE NAME ='rg1' or NAME = 'rg2';to showBURSTABLEasYES(MODERATED)forrg1andNOforrg2(lines 132-137).
- Updated the grammar definition for
- sql-statements/sql-statement-drop-resource-group.md
- Updated example output for
SELECT * FROM information_schema.resource_groups WHERE NAME ='rg1';to showBURSTABLEasYES(MODERATED)(lines 58-62).
- Updated example output for
- tidb-resource-control-background-tasks.md
- Updated example output for
SELECT * FROM information_schema.resource_groups;to showBURSTABLEasYES(UNLIMITED)for the default group (lines 80-84).
- Updated example output for
Using Gemini Code Assist
The full guide for Gemini Code Assist can be found on our documentation page, here are some quick tips.
Invoking Gemini
You can request assistance from Gemini at any point in your pull request via creating an issue comment (i.e. comment on the pull request page) using either /gemini <command> or @gemini-code-assist <command>. Below is a summary of the supported commands.
| Feature | Command | Description |
|---|---|---|
| Code Review | /gemini review |
Performs a code review for the current pull request in its current state. |
| Pull Request Summary | /gemini summary |
Provides a summary of the current pull request in its current state. |
| Comment | @gemini-code-assist | Responds in comments when explicitly tagged, both in issue comments and review comments. |
| Help | /gemini help |
Displays a list of available commands. |
Customization
To customize Gemini Code Assist for GitHub experience, repository maintainers can create a configuration file and/or provide a custom code review style guide (such as PEP-8 for Python) by creating and adding files to a .gemini/ folder in the base of the repository. Detailed instructions can be found here.
Limitations & Feedback
Gemini Code Assist is currently in preview and may make mistakes. Please leave feedback on any instances where its feedback is incorrect or counter productive. You can react with 👍 and 👎 on @gemini-code-assist comments to provide feedback.
You can also get AI-powered code generation, chat, as well as code reviews directly in the IDE at no cost with the Gemini Code Assist IDE Extension.
Footnotes
-
Review the Privacy Notices, Generative AI Prohibited Use Policy, Terms of Service, and learn how to configure Gemini Code Assist in GitHub here. Gemini can make mistakes, so double check it and use code with caution. ↩
There was a problem hiding this comment.
Code Review
This pull request updates the documentation to reflect the new modes available for the BURSTABLE option in resource groups. The changes are mostly in table outputs and descriptions across several files. Overall, the updates clarify the new functionality. However, there are a few areas that need attention to ensure accuracy and consistency, primarily related to example outputs and a typo.
Summary of Findings
- Documentation Accuracy: There's an incorrect row count in the
DESC resource_groups;output ininformation-schema/information-schema-resource-groups.md. - Spelling Error: A typo "UNLIMTED" was found in
sql-statements/sql-statement-create-resource-group.md. It should be "UNLIMITED". - Example Consistency: In
tidb-resource-control-ru-groups.md, an example description refers torg1while the SQL code createsrg4. - Readability: The description of the
BURSTABLEoption is quite long in several files and could be broken down for better readability. - Formatting Consistency: EBNF diagrams in
sql-statement-alter-resource-group.mdandsql-statement-create-resource-group.mdhave inconsistent indentation for the newBURSTABLEoptions.
Merge Readiness
The pull request introduces important documentation updates for the BURSTABLE resource control option. While the changes are largely good, there are a few issues related to accuracy (incorrect command output, typo) and consistency (example naming) that should be addressed before merging. Addressing these will improve the clarity and correctness of the documentation. I am unable to approve pull requests, so please ensure these changes are reviewed and approved by a maintainer.
|
@gemini-code-assist[bot]: 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-sigs/prow repository. |
Co-authored-by: gemini-code-assist[bot] <176961590+gemini-code-assist[bot]@users.noreply.github.com>
Co-authored-by: gemini-code-assist[bot] <176961590+gemini-code-assist[bot]@users.noreply.github.com>
Co-authored-by: gemini-code-assist[bot] <176961590+gemini-code-assist[bot]@users.noreply.github.com>
Co-authored-by: Lilian Lee <lilin@pingcap.com>
Co-authored-by: Lilian Lee <lilin@pingcap.com>
|
@songrijie: 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-sigs/prow repository. |
Co-authored-by: xixirangrang <hfxsd@hotmail.com>
Co-authored-by: xixirangrang <hfxsd@hotmail.com>
Co-authored-by: xixirangrang <hfxsd@hotmail.com>
|
This PR is ready for merging. |
|
/unhold |
|
/approve |
|
[APPROVALNOTIFIER] This PR is APPROVED This pull-request has been approved by: lilin90 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 |
First-time contributors' checklist
What is changed, added or deleted? (Required)
Which TiDB version(s) do your changes apply to? (Required)
Tips for choosing the affected version(s):
By default, CHOOSE MASTER ONLY so your changes will be applied to the next TiDB major or minor releases. If your PR involves a product feature behavior change or a compatibility change, CHOOSE THE AFFECTED RELEASE BRANCH(ES) AND MASTER.
For details, see tips for choosing the affected versions.
What is the related PR or file link(s)?
Do your changes match any of the following descriptions?