Conversation
Clarified behavior of DDL operations involving columns and indexes.
|
[APPROVALNOTIFIER] This PR is NOT APPROVED This pull-request has been approved by: The full list of commands accepted by this bot can be found here. DetailsNeeds approval from an approver in each of these files:Approvers can indicate their approval by writing |
|
No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review info⚙️ Run configurationConfiguration used: Path: .coderabbit.yaml Review profile: ASSERTIVE Plan: Advanced Run ID: 📒 Files selected for processing (1)
Included review availability: Your plan provides up to 4 included reviews per hour; 2 remain after this review. 📝 WalkthroughWalkthrough本次变更更新 DDL 白名单文档。文档新增有效索引变更说明,并将 ChangesDDL 白名单说明
Priority: ⬇️ Low Estimated code review effort: 1 (Trivial) | ~2 minutes Change: Other Merge Risk: ⚪ Minimal · up to The documentation update has no unresolved material risk identified in the reviewed scope. 🚥 Pre-merge checks | ✅ 5✅ Passed checks (5 passed)
✨ Finishing Touches 💡 1🛠️ Fix failing CI checks 💡
🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
There was a problem hiding this comment.
Actionable comments posted: 1
ℹ️ Review info
⚙️ Run configuration
Configuration used: Path: .coderabbit.yaml
Review profile: ASSERTIVE
Plan: Advanced
Run ID: 6f742530-be2c-4da7-8e80-4eafe2a4306f
📒 Files selected for processing (1)
ticdc/ticdc-ddl.md
Included review availability: Your plan provides up to 4 included reviews per hour; 3 remain after this review.
| > | ||
| > - 当上游表不存在有效索引,且未配置 `force-replicate=true` 时,该表不会被同步,但是之后在该表上创建有效索引的 DDL (`CREATE INDEX`、`ADD INDEX` 和 `ADD PRIMARY KEY`)会被同步,下游表和上游表结构可能产生不一致从而导致后续数据同步失败。 | ||
| > - 删除最后一个有效索引的 DDL(`DROP INDEX` 和 `DROP PRIMARY KEY`)不会被同步,并且导致后续数据同步失败。 | ||
| > - 如果 `ADD COLUMN`,`DROP COLUMN`,`MODIFY COLUMN` 涉及到有效索引的添加删除,其行为表现应该与 `ADD INDEX`,`DROP INDEX`等 DDL 行为表现一致。 |
There was a problem hiding this comment.
🗄️ Data Integrity & Integration | 🟡 Minor | ⚡ Quick win
明确列出涉及有效索引变更的 DDL。
DDL 白名单列出了 CREATE INDEX、ADD INDEX、DROP INDEX、ADD PRIMARY KEY 和 DROP PRIMARY KEY。当前仅列出前两类操作,等 DDL 未明确涵盖主键变更。请替换为:
可直接提交的修改
| > - 如果 `ADD COLUMN`,`DROP COLUMN`,`MODIFY COLUMN` 涉及到有效索引的添加删除,其行为表现应该与 `ADD INDEX`,`DROP INDEX`等 DDL 行为表现一致。 | |
| > - 如果 `ADD COLUMN`、`DROP COLUMN` 或 `MODIFY COLUMN` 涉及添加或删除有效索引,其行为应与 `CREATE INDEX`、`ADD INDEX`、`DROP INDEX`、`ADD PRIMARY KEY` 和 `DROP PRIMARY KEY` 等 DDL 的行为一致。 |
📝 Committable suggestion
‼️ IMPORTANT
Carefully review the code before committing. Ensure that it accurately replaces the highlighted code, contains no missing lines, and has no issues with indentation. Thoroughly test & benchmark the code to ensure it meets the requirements.
| > - 如果 `ADD COLUMN`,`DROP COLUMN`,`MODIFY COLUMN` 涉及到有效索引的添加删除,其行为表现应该与 `ADD INDEX`,`DROP INDEX`等 DDL 行为表现一致。 | |
| > - 如果 `ADD COLUMN`、`DROP COLUMN` 或 `MODIFY COLUMN` 涉及添加或删除有效索引,其行为应与 `CREATE INDEX`、`ADD INDEX`、`DROP INDEX`、`ADD PRIMARY KEY` 和 `DROP PRIMARY KEY` 等 DDL 的行为一致。 |
|
@wk989898: 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-sigs/prow repository. I understand the commands that are listed here. |
Clarified behavior of DDL operations involving columns and indexes.
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 (in Chinese).
What is the related PR or file link(s)?
AI agent involvement
Do your changes match any of the following descriptions?
Summary by CodeRabbit
ADD COLUMN、DROP COLUMN或MODIFY COLUMN涉及有效索引的添加或删除时,其行为应与ADD INDEX、DROP INDEX等 DDL 操作保持一致。ADD COLUMN和MODIFY COLUMN的白名单说明:在force-replicate=false且无有效索引时,涉及有效索引添加则标记为 Y,否则标记为 N。