tidb icon indicating copy to clipboard operation
tidb copied to clipboard

ddl: refine the criterion for modify column

Open joechenrh opened this issue 3 weeks ago • 8 comments

What problem does this PR solve?

Issue Number: ref https://github.com/pingcap/tidb/issues/63366

Problem Summary:

What changed and how does it work?

Disable lossy modify column optimization in the following cases:

  • table contains TiFlash replica, ref https://github.com/pingcap/tiflash/issues/10509
  • signed/unsigned changes, or string with different collations.

Besides, this PR do some minor refactor to the check of modify column type, to support more changes with reorg, ref https://github.com/pingcap/tidb/commit/8f380b5b704ccd2b43dfa85b564d5a248b0b184b)

Check List

Tests

  • [x] Unit test
  • [ ] Integration test
  • [ ] Manual test (add detailed scripts or steps below)
  • [ ] No need to test
    • [ ] I checked and no code files have been changed.

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

Please refer to Release Notes Language Style Guide to write a quality release note.

None

joechenrh avatar Dec 03 '25 06:12 joechenrh

Hi @joechenrh. Thanks for your PR.

PRs from untrusted users cannot be marked as trusted with /ok-to-test in this repo meaning untrusted PR authors can never trigger tests themselves. Collaborators can still trigger tests on the PR using /test all.

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-sigs/prow repository.

tiprow[bot] avatar Dec 03 '25 06:12 tiprow[bot]

Codecov Report

:x: Patch coverage is 85.00000% with 3 lines in your changes missing coverage. Please review. :white_check_mark: Project coverage is 71.1897%. Comparing base (dc7d3a0) to head (2414e61). :warning: Report is 5 commits behind head on master.

Additional details and impacted files
@@               Coverage Diff                @@
##             master     #64834        +/-   ##
================================================
+ Coverage   70.7644%   71.1897%   +0.4252%     
================================================
  Files          1895       1895                
  Lines        517880     517996       +116     
================================================
+ Hits         366475     368760      +2285     
+ Misses       126907     124859      -2048     
+ Partials      24498      24377       -121     
Flag Coverage Δ
integration 48.0075% <80.0000%> (-0.1621%) :arrow_down:
unit 65.9610% <85.0000%> (+0.4341%) :arrow_up:

Flags with carried forward coverage won't be shown. Click here to find out more.

Components Coverage Δ
dumpling 52.8700% <ø> (ø)
parser ∅ <ø> (∅)
br 58.6765% <ø> (+0.4496%) :arrow_up:
:rocket: New features to boost your workflow:
  • :snowflake: Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • :package: JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

codecov[bot] avatar Dec 03 '25 06:12 codecov[bot]

/retest

joechenrh avatar Dec 11 '25 12:12 joechenrh

@joechenrh: Cannot trigger testing until a trusted user reviews the PR and leaves an /ok-to-test message.

In response to this:

/retest

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.

tiprow[bot] avatar Dec 11 '25 12:12 tiprow[bot]

/hold

joechenrh avatar Dec 11 '25 13:12 joechenrh

/retest

joechenrh avatar Dec 11 '25 14:12 joechenrh

@joechenrh: Cannot trigger testing until a trusted user reviews the PR and leaves an /ok-to-test message.

In response to this:

/retest

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.

tiprow[bot] avatar Dec 11 '25 14:12 tiprow[bot]

/retest

joechenrh avatar Dec 15 '25 07:12 joechenrh

@joechenrh: Cannot trigger testing until a trusted user reviews the PR and leaves an /ok-to-test message.

In response to this:

/retest

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.

tiprow[bot] avatar Dec 15 '25 07:12 tiprow[bot]

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: fzzf678, wjhuang2016

The full list of commands accepted by this bot can be found here.

The pull request process is described here

Needs approval from an approver in each of these files:

Approvers can indicate their approval by writing /approve in a comment Approvers can cancel approval by writing /approve cancel in a comment

ti-chi-bot[bot] avatar Dec 16 '25 03:12 ti-chi-bot[bot]

[LGTM Timeline notifier]

Timeline:

  • 2025-12-15 04:34:40.876554704 +0000 UTC m=+1447625.690332286: :ballot_box_with_check: agreed by fzzf678.
  • 2025-12-16 03:03:52.564837347 +0000 UTC m=+1528577.378614919: :ballot_box_with_check: agreed by wjhuang2016.

ti-chi-bot[bot] avatar Dec 16 '25 03:12 ti-chi-bot[bot]

Remove needs-cherry-pick-release-8.5 as we will manually cherry-pick this.

joechenrh avatar Dec 16 '25 03:12 joechenrh

/retest

joechenrh avatar Dec 16 '25 03:12 joechenrh

@joechenrh: Cannot trigger testing until a trusted user reviews the PR and leaves an /ok-to-test message.

In response to this:

/retest

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.

tiprow[bot] avatar Dec 16 '25 03:12 tiprow[bot]

/retest

joechenrh avatar Dec 16 '25 06:12 joechenrh

@joechenrh: Cannot trigger testing until a trusted user reviews the PR and leaves an /ok-to-test message.

In response to this:

/retest

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.

tiprow[bot] avatar Dec 16 '25 06:12 tiprow[bot]

/retest

joechenrh avatar Dec 16 '25 08:12 joechenrh

@joechenrh: Cannot trigger testing until a trusted user reviews the PR and leaves an /ok-to-test message.

In response to this:

/retest

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.

tiprow[bot] avatar Dec 16 '25 08:12 tiprow[bot]

/retest

joechenrh avatar Dec 16 '25 10:12 joechenrh

@joechenrh: Cannot trigger testing until a trusted user reviews the PR and leaves an /ok-to-test message.

In response to this:

/retest

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.

tiprow[bot] avatar Dec 16 '25 10:12 tiprow[bot]

/retest

joechenrh avatar Dec 16 '25 15:12 joechenrh

@joechenrh: Cannot trigger testing until a trusted user reviews the PR and leaves an /ok-to-test message.

In response to this:

/retest

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.

tiprow[bot] avatar Dec 16 '25 15:12 tiprow[bot]

/retest

joechenrh avatar Dec 17 '25 07:12 joechenrh

@joechenrh: Cannot trigger testing until a trusted user reviews the PR and leaves an /ok-to-test message.

In response to this:

/retest

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.

tiprow[bot] avatar Dec 17 '25 07:12 tiprow[bot]

/retest

joechenrh avatar Dec 17 '25 07:12 joechenrh

@joechenrh: Cannot trigger testing until a trusted user reviews the PR and leaves an /ok-to-test message.

In response to this:

/retest

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.

tiprow[bot] avatar Dec 17 '25 07:12 tiprow[bot]

/retest

joechenrh avatar Dec 17 '25 11:12 joechenrh

@joechenrh: Cannot trigger testing until a trusted user reviews the PR and leaves an /ok-to-test message.

In response to this:

/retest

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.

tiprow[bot] avatar Dec 17 '25 11:12 tiprow[bot]

/retest

joechenrh avatar Dec 18 '25 06:12 joechenrh

@joechenrh: Cannot trigger testing until a trusted user reviews the PR and leaves an /ok-to-test message.

In response to this:

/retest

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.

tiprow[bot] avatar Dec 18 '25 06:12 tiprow[bot]