Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

ddl: Non clustered reorg part optimistic backfill #60382

Open
wants to merge 89 commits into
base: master
Choose a base branch
from

Conversation

mjonss
Copy link
Contributor

@mjonss mjonss commented Apr 2, 2025

What problem does this PR solve?

Issue Number: close #60381

Problem Summary:
To be fully consistent during backfill of reorganize partition, we check every row by trying to read the rows before writing them, to avoid overwriting. This read can be skipped if we set the PresumeKeyNotExists flag instead

What changed and how does it work?

Do one try with PresumeKeyNotExists and if failing, fallback to current implementation.

Build upon #60132.

Check List

Tests

  • 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.

Optimizing REORGANIZE PARTITION by avoiding read of new partitions.

TODO: Still check issues with new _tidb_rowid's when it comes to
INDEX as well as updating both new+old set of partition
as well as old+new...
@ti-chi-bot ti-chi-bot bot added do-not-merge/invalid-title release-note Denotes a PR that will be considered when it comes time to generate release notes. size/XXL Denotes a PR that changes 1000+ lines, ignoring generated files. labels Apr 2, 2025
Copy link

tiprow bot commented Apr 2, 2025

Hi @mjonss. 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.

@mjonss mjonss changed the title Non clustered reorg part optimistic backfill ddl: Non clustered reorg part optimistic backfill Apr 2, 2025
Copy link

codecov bot commented Apr 2, 2025

Codecov Report

Attention: Patch coverage is 84.21053% with 9 lines in your changes missing coverage. Please review.

Project coverage is 74.8644%. Comparing base (d0e4cd4) to head (d71f46f).
Report is 3 commits behind head on master.

Additional details and impacted files
@@               Coverage Diff                @@
##             master     #60382        +/-   ##
================================================
+ Coverage   73.0980%   74.8644%   +1.7664%     
================================================
  Files          1714       1760        +46     
  Lines        474475     482791      +8316     
================================================
+ Hits         346832     361439     +14607     
+ Misses       106307      98551      -7756     
- Partials      21336      22801      +1465     
Flag Coverage Δ
integration 48.8950% <84.2105%> (?)
unit 72.3536% <78.9473%> (+0.0374%) ⬆️

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

Components Coverage Δ
dumpling 52.6553% <ø> (ø)
parser ∅ <ø> (∅)
br 62.3400% <ø> (+15.1126%) ⬆️
🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

@mjonss
Copy link
Contributor Author

mjonss commented Apr 2, 2025

/retest

Copy link

tiprow bot commented Apr 2, 2025

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

@mjonss
Copy link
Contributor Author

mjonss commented Apr 4, 2025

/retest

Copy link

tiprow bot commented Apr 4, 2025

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

Copy link

ti-chi-bot bot commented Apr 10, 2025

[APPROVALNOTIFIER] This PR is NOT APPROVED

This pull-request has been approved by:
Once this PR has been reviewed and has the lgtm label, please assign tangenta for approval. For more information see the Code Review Process.

The full list of commands accepted by this bot can be found 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

@mjonss
Copy link
Contributor Author

mjonss commented Apr 10, 2025

/retest

Copy link

tiprow bot commented Apr 10, 2025

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

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
release-note Denotes a PR that will be considered when it comes time to generate release notes. size/XXL Denotes a PR that changes 1000+ lines, ignoring generated files.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Optimize reorganize partition backfill data copying
1 participant