Skip to content

Conversation

joccau
Copy link
Contributor

@joccau joccau commented Dec 27, 2024

What problem does this PR solve?

Issue Number: close #58680

Problem Summary:

What changed and how does it work?

  • The feature of import into can be run with the option of thread=1
  • Simplify the code.

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.

The feature of `import into` with the options `global-sort` can be run at the server that only consumes 1 core resource.

@joccau joccau added the do-not-merge/hold Indicates that a PR should not merge because someone has issued a /hold command. label Dec 27, 2024
@ti-chi-bot ti-chi-bot bot added the size/XS Denotes a PR that changes 0-9 lines, ignoring generated files. label Dec 27, 2024
Copy link

codecov bot commented Dec 27, 2024

Codecov Report

Attention: Patch coverage is 80.64516% with 6 lines in your changes missing coverage. Please review.

Project coverage is 73.3884%. Comparing base (d93c233) to head (516d575).
Report is 1 commits behind head on master.

Additional details and impacted files
@@               Coverage Diff                @@
##             master     #58572        +/-   ##
================================================
+ Coverage   72.9581%   73.3884%   +0.4302%     
================================================
  Files          1697       1697                
  Lines        468911     468932        +21     
================================================
+ Hits         342109     344142      +2033     
+ Misses       105737     103739      -1998     
+ Partials      21065      21051        -14     
Flag Coverage Δ
integration 42.7869% <0.0000%> (?)
unit 72.1713% <80.6451%> (+0.0225%) ⬆️

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

Components Coverage Δ
dumpling 52.6910% <ø> (ø)
parser ∅ <ø> (∅)
br 45.1107% <ø> (+0.0112%) ⬆️

joccau added 2 commits December 31, 2024 12:00
Signed-off-by: joccau <[email protected]>
Signed-off-by: joccau <[email protected]>
@ti-chi-bot ti-chi-bot bot added size/L Denotes a PR that changes 100-499 lines, ignoring generated files. and removed size/XS Denotes a PR that changes 0-9 lines, ignoring generated files. labels Jan 3, 2025
Signed-off-by: joccau <[email protected]>
@joccau joccau force-pushed the global-sort-based-1c branch from 86b5522 to 1c99267 Compare January 3, 2025 06:59
@joccau joccau changed the title import-into: the feature of 'import into' with the option of 'global sort' to support 1c resource.[wip] import-into: 'import into' with the option of 'global sort' supports 1c CPU resource.[wip] Jan 3, 2025
@ti-chi-bot ti-chi-bot bot added release-note Denotes a PR that will be considered when it comes time to generate release notes. and removed do-not-merge/needs-linked-issue do-not-merge/needs-tests-checked release-note-none Denotes a PR that doesn't merit a release note. labels Jan 3, 2025
Signed-off-by: joccau <[email protected]>
@joccau joccau force-pushed the global-sort-based-1c branch from c7b1279 to 0c0396b Compare January 3, 2025 09:58
@joccau joccau removed the do-not-merge/hold Indicates that a PR should not merge because someone has issued a /hold command. label Jan 3, 2025
@joccau
Copy link
Contributor Author

joccau commented Jan 3, 2025

/test pull-lightning-integration-test

Copy link

tiprow bot commented Jan 3, 2025

@joccau: The specified target(s) for /test were not found.
The following commands are available to trigger required jobs:

  • /test fast_test_tiprow
  • /test tidb_parser_test

Use /test all to run all jobs.

In response to this:

/test pull-lightning-integration-test

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.

@joccau joccau changed the title import-into: 'import into' with the option of 'global sort' supports 1c CPU resource.[wip] import-into: 'import into' with the option of 'global sort' supports 1c CPU resource. Jan 9, 2025
@joccau joccau requested a review from D3Hunter January 9, 2025 08:00
@joccau
Copy link
Contributor Author

joccau commented Jan 10, 2025

/test unit-test

Copy link

tiprow bot commented Jan 10, 2025

@joccau: The specified target(s) for /test were not found.
The following commands are available to trigger required jobs:

  • /test fast_test_tiprow
  • /test tidb_parser_test

Use /test all to run all jobs.

In response to this:

/test unit-test

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.

@joccau
Copy link
Contributor Author

joccau commented Jan 10, 2025

/test pull-lightning-integration-test

@joccau joccau requested a review from lance6716 January 17, 2025 06:55
@lance6716
Copy link
Contributor

only consume 1 core resource.

If the goal is during the whole IMPORT INTO only ~100% CPU is used, I think your internal test report can't achieve it.

@D3Hunter D3Hunter changed the title import-into: 'import into' with the option of 'global sort' supports 1c CPU resource. import-into: support running with 1 thread when using global sort Jan 20, 2025
@D3Hunter
Copy link
Contributor

/hold

this PR and related test hasn't reproduced the OOM we meet before, so there is no optimization for memory

@ti-chi-bot ti-chi-bot bot added the do-not-merge/hold Indicates that a PR should not merge because someone has issued a /hold command. label Jan 22, 2025
@joccau joccau requested a review from D3Hunter February 20, 2025 03:57
@joccau
Copy link
Contributor Author

joccau commented Feb 21, 2025

/unhold

@ti-chi-bot ti-chi-bot bot removed the do-not-merge/hold Indicates that a PR should not merge because someone has issued a /hold command. label Feb 21, 2025
Copy link
Contributor

@D3Hunter D3Hunter left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

rest lgtm

@ti-chi-bot ti-chi-bot bot added approved needs-1-more-lgtm Indicates a PR needs 1 more LGTM. labels Feb 21, 2025
Copy link

ti-chi-bot bot commented Feb 24, 2025

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: D3Hunter, lance6716

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 ti-chi-bot bot added lgtm and removed needs-1-more-lgtm Indicates a PR needs 1 more LGTM. labels Feb 24, 2025
Copy link

ti-chi-bot bot commented Feb 24, 2025

[LGTM Timeline notifier]

Timeline:

  • 2025-02-21 08:19:59.696832802 +0000 UTC m=+1208642.093054859: ☑️ agreed by D3Hunter.
  • 2025-02-24 03:25:44.421860066 +0000 UTC m=+239892.375018330: ☑️ agreed by lance6716.

@joccau
Copy link
Contributor Author

joccau commented Feb 24, 2025

/test check-dev2

Copy link

tiprow bot commented Feb 24, 2025

@joccau: The specified target(s) for /test were not found.
The following commands are available to trigger required jobs:

  • /test fast_test_tiprow
  • /test tidb_parser_test

Use /test all to run all jobs.

In response to this:

/test check-dev2

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.

@ti-chi-bot ti-chi-bot bot merged commit e2d5d1c into pingcap:master Feb 24, 2025
25 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
approved lgtm release-note Denotes a PR that will be considered when it comes time to generate release notes. size/L Denotes a PR that changes 100-499 lines, ignoring generated files.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

import-into: support running with 1 thread when using global sort
3 participants