Skip to content

session: add index on 'user' field for mysql tables | tidb-test=pr/2430#57470

Merged
ti-chi-bot[bot] merged 11 commits into
pingcap:masterfrom
tiancaiamao:user-index
Dec 26, 2024
Merged

session: add index on 'user' field for mysql tables | tidb-test=pr/2430#57470
ti-chi-bot[bot] merged 11 commits into
pingcap:masterfrom
tiancaiamao:user-index

Conversation

@tiancaiamao

Copy link
Copy Markdown
Contributor

What problem does this PR solve?

Issue Number: ref #55563

Problem Summary:

What changed and how does it work?

Another solution for the same purpose, see #57320
If this one is chosen, that one could be closed.

Check List

Tests

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

create new cluster and upgrade old cluster, show create table to see the result.

  • 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

@ti-chi-bot ti-chi-bot Bot added the release-note-none Denotes a PR that doesn't merit a release note. label Nov 18, 2024
@tiancaiamao tiancaiamao requested a review from D3Hunter November 18, 2024 13:53
@ti-chi-bot ti-chi-bot Bot added the size/M Denotes a PR that changes 30-99 lines, ignoring generated files. label Nov 18, 2024
@tiancaiamao tiancaiamao requested a review from bb7133 November 18, 2024 13:54
@codecov

codecov Bot commented Nov 18, 2024

Copy link
Copy Markdown

Codecov Report

Attention: Patch coverage is 72.72727% with 3 lines in your changes missing coverage. Please review.

Project coverage is 74.7442%. Comparing base (b079b5f) to head (d1a80bd).
Report is 356 commits behind head on master.

Additional details and impacted files
@@               Coverage Diff                @@
##             master     #57470        +/-   ##
================================================
+ Coverage   73.5301%   74.7442%   +1.2141%     
================================================
  Files          1681       1696        +15     
  Lines        464298     468650      +4352     
================================================
+ Hits         341399     350289      +8890     
+ Misses       102058      96727      -5331     
- Partials      20841      21634       +793     
Flag Coverage Δ
integration 46.2240% <0.0000%> (?)
unit 72.2666% <72.7272%> (-0.0369%) ⬇️

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

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

@tiancaiamao tiancaiamao changed the title session: add index on 'user' field for mysql tables session: add index on 'user' field for mysql tables | tidb-test=pr/2430 Nov 19, 2024
Comment thread pkg/session/bootstrap.go Outdated

@D3Hunter D3Hunter left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

rest lgtm

@tiancaiamao

Copy link
Copy Markdown
Contributor Author

/test mysql-test

@tiprow

tiprow Bot commented Dec 12, 2024

Copy link
Copy Markdown

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

Details

In response to this:

/test mysql-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.

@tiancaiamao

Copy link
Copy Markdown
Contributor Author

/test mysql-test

@tiancaiamao tiancaiamao requested a review from D3Hunter December 12, 2024 03:02
@tiprow

tiprow Bot commented Dec 12, 2024

Copy link
Copy Markdown

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

Details

In response to this:

/test mysql-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.

@tiancaiamao

Copy link
Copy Markdown
Contributor Author

/test unit-test

@tiprow

tiprow Bot commented Dec 12, 2024

Copy link
Copy Markdown

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

Details

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.

@tiancaiamao

Copy link
Copy Markdown
Contributor Author

PTAL @bb7133

@bb7133 bb7133 left a comment

Copy link
Copy Markdown
Member

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 Bot added the needs-1-more-lgtm Indicates a PR needs 1 more LGTM. label Dec 26, 2024
Comment thread pkg/session/bootstrap.go Outdated
// Add index on user field for some mysql tables.
version240 = 240

// Add indexes to mysql.analyze_jobs to speed up the query.

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

comments of 240/241 should be exchanged

@ti-chi-bot ti-chi-bot Bot added the lgtm label Dec 26, 2024
@ti-chi-bot ti-chi-bot Bot removed the needs-1-more-lgtm Indicates a PR needs 1 more LGTM. label Dec 26, 2024
@ti-chi-bot

ti-chi-bot Bot commented Dec 26, 2024

Copy link
Copy Markdown

[LGTM Timeline notifier]

Timeline:

  • 2024-12-26 03:57:34.528428073 +0000 UTC m=+1706844.617230616: ☑️ agreed by bb7133.
  • 2024-12-26 04:05:17.93485587 +0000 UTC m=+1707308.023658412: ☑️ agreed by D3Hunter.

@tiprow

tiprow Bot commented Dec 26, 2024

Copy link
Copy Markdown

@tiancaiamao: The following test failed, say /retest to rerun all failed tests or /retest-required to rerun all mandatory failed tests:

Test name Commit Details Required Rerun command
fast_test_tiprow 624934f link true /test fast_test_tiprow

Full PR test history. Your PR dashboard.

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 kubernetes-sigs/prow repository. I understand the commands that are listed here.

@ti-chi-bot

ti-chi-bot Bot commented Dec 26, 2024

Copy link
Copy Markdown

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: bb7133, BornChanger, D3Hunter, yudongusa

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

The pull request process is described here

Details 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 the approved label Dec 26, 2024
@ti-chi-bot ti-chi-bot Bot merged commit 8e1a47d into pingcap:master Dec 26, 2024
@tiancaiamao tiancaiamao deleted the user-index branch December 26, 2024 06:43
@ti-chi-bot ti-chi-bot Bot added the needs-cherry-pick-release-8.5 Should cherry pick this PR to release-8.5 branch. label Feb 27, 2025
@ti-chi-bot

Copy link
Copy Markdown
Member

In response to a cherrypick label: new pull request created to branch release-8.5: #59805.
But this PR has conflicts, please resolve them!

ti-chi-bot pushed a commit to ti-chi-bot/tidb that referenced this pull request Feb 27, 2025
Signed-off-by: ti-chi-bot <ti-community-prow-bot@tidb.io>
@ti-chi-bot ti-chi-bot Bot removed the needs-cherry-pick-release-8.5 Should cherry pick this PR to release-8.5 branch. label Apr 9, 2025
CbcWestwolf added a commit to CbcWestwolf/tidb that referenced this pull request Aug 5, 2025
CbcWestwolf added a commit to CbcWestwolf/tidb that referenced this pull request Aug 5, 2025
CbcWestwolf added a commit to CbcWestwolf/tidb that referenced this pull request Aug 6, 2025
tiancaiamao added a commit to tiancaiamao/tidb that referenced this pull request Jan 28, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

approved lgtm release-note-none Denotes a PR that doesn't merit a release note. size/M Denotes a PR that changes 30-99 lines, ignoring generated files.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

6 participants