Skip to content

Added support for ALTER TABLE t REORGANIZE PARTITION p INTO (..)#6428

Merged
ti-chi-bot merged 10 commits into
pingcap:masterfrom
mjonss:reorganize-partition-schema-change
Feb 20, 2023
Merged

Added support for ALTER TABLE t REORGANIZE PARTITION p INTO (..)#6428
ti-chi-bot merged 10 commits into
pingcap:masterfrom
mjonss:reorganize-partition-schema-change

Conversation

@mjonss
Copy link
Copy Markdown
Contributor

@mjonss mjonss commented Dec 5, 2022

What problem does this PR solve?

Reference: pingcap/tidb#38535
Issue Number: close #6444

Problem Summary:
Support ALTER TABLE t REORGANIZE PARTITION INTO ()

What is changed and how it works?

Check List

Tests

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

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

None

@ti-chi-bot
Copy link
Copy Markdown
Member

ti-chi-bot commented Dec 5, 2022

[REVIEW NOTIFICATION]

This pull request has been approved by:

  • JaySon-Huang
  • hongyunyan

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.

Details

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 added do-not-merge/needs-linked-issue release-note-none Denotes a PR that doesn't merit a release note. size/XS Denotes a PR that changes 0-9 lines, ignoring generated files. labels Dec 5, 2022
@ti-chi-bot ti-chi-bot added size/M Denotes a PR that changes 30-99 lines, ignoring generated files. and removed size/XS Denotes a PR that changes 0-9 lines, ignoring generated files. labels Dec 7, 2022
Comment thread dbms/src/TiDB/Schema/SchemaGetter.h Outdated
@hongyunyan
Copy link
Copy Markdown
Contributor

It's better to add some Integration tests under tests/fullstack-test2/ddl to make verify.

@hongyunyan
Copy link
Copy Markdown
Contributor

/cc @JaySon-Huang

@JaySon-Huang
Copy link
Copy Markdown
Contributor

@mjonss report that he see this error ERROR 1105 (HY000): [FLASH:Coprocessor:RegionError] Region 99 is unavailable at 16: (while doing learner read for table, logical table_id: 80) when testing REORGANIZE PARTITION with this tiflash.
@hongyunyan Can you help @mjonss to verify the REORGANIZE PARTITION works well before getting this PR merged?

@hongyunyan
Copy link
Copy Markdown
Contributor

@mjonss report that he see this error ERROR 1105 (HY000): [FLASH:Coprocessor:RegionError] Region 99 is unavailable at 16: (while doing learner read for table, logical table_id: 80) when testing REORGANIZE PARTITION with this tiflash. @hongyunyan Can you help @mjonss to verify the REORGANIZE PARTITION works well before getting this PR merged?

No problem!While for this error @mjonss said he got that error even before running the new ALTER TABLE t REORGANIZE PARTITION.

@ti-chi-bot ti-chi-bot added the needs-rebase Indicates a PR cannot be merged because it has merge conflicts with HEAD. label Jan 4, 2023
@mjonss
Copy link
Copy Markdown
Contributor Author

mjonss commented Jan 19, 2023

@mjonss report that he see this error ERROR 1105 (HY000): [FLASH:Coprocessor:RegionError] Region 99 is unavailable at 16: (while doing learner read for table, logical table_id: 80) when testing REORGANIZE PARTITION with this tiflash. @hongyunyan Can you help @mjonss to verify the REORGANIZE PARTITION works well before getting this PR merged?

No problem!While for this error @mjonss said he got that error even before running the new ALTER TABLE t REORGANIZE PARTITION.

Seems related to arm64?
I created #6659.

@ti-chi-bot ti-chi-bot removed the needs-rebase Indicates a PR cannot be merged because it has merge conflicts with HEAD. label Jan 19, 2023
@mjonss
Copy link
Copy Markdown
Contributor Author

mjonss commented Feb 9, 2023

@hongyunyan Hi, the Reorganize partition feature in TiDB repo is in the merge queue, is it possible to review and merge this as well now?

@ti-chi-bot ti-chi-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 Feb 9, 2023
@JaySon-Huang
Copy link
Copy Markdown
Contributor

/rebuild

Copy link
Copy Markdown
Contributor

@JaySon-Huang JaySon-Huang 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 added the status/LGT1 Indicates that a PR has LGTM 1. label Feb 13, 2023
@JaySon-Huang
Copy link
Copy Markdown
Contributor

/run-all-tests

@mjonss
Copy link
Copy Markdown
Contributor Author

mjonss commented Feb 13, 2023

/run-integration-test

Copy link
Copy Markdown
Contributor

@hongyunyan hongyunyan 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 added status/LGT2 Indicates that a PR has LGTM 2. and removed status/LGT1 Indicates that a PR has LGTM 1. labels Feb 20, 2023
@hongyunyan
Copy link
Copy Markdown
Contributor

/merge

@ti-chi-bot
Copy link
Copy Markdown
Member

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

Details

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
Copy Markdown
Member

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

DetailsCommit hash: 9705af7

@ti-chi-bot ti-chi-bot added the status/can-merge Indicates a PR has been approved by a committer. label Feb 20, 2023
@ti-chi-bot
Copy link
Copy Markdown
Member

@mjonss: Your PR was out of date, I have automatically updated it for you.

At the same time I will also trigger all tests for you:

/run-all-tests

trigger some heavy tests which will not run always when PR updated.

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.

Details

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 ti-chi-bot merged commit a8c4d47 into pingcap:master Feb 20, 2023
@mjonss mjonss deleted the reorganize-partition-schema-change branch March 7, 2023 22:00
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.

Support ALTER TABLE t REORGANIZE PARTITION <list of partitions> INTO (<list of partition definitions>)

4 participants