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

*: don't handle live updates of column size #58596

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

Conversation

winoros
Copy link
Member

@winoros winoros commented Dec 28, 2024

What problem does this PR solve?

Issue Number: close #58595

Problem Summary:

What changed and how does it work?

Just as the issue said. We dropped the maintenance of the column size updates during various DML statements.

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.

None

@ti-chi-bot ti-chi-bot bot added release-note-none Denotes a PR that doesn't merit a release note. size/XL Denotes a PR that changes 500-999 lines, ignoring generated files. sig/planner SIG: Planner labels Dec 28, 2024
Copy link

codecov bot commented Dec 28, 2024

Codecov Report

Attention: Patch coverage is 96.29630% with 1 line in your changes missing coverage. Please review.

Project coverage is 73.8917%. Comparing base (be6396c) to head (e2693d3).
Report is 11 commits behind head on master.

Additional details and impacted files
@@               Coverage Diff                @@
##             master     #58596        +/-   ##
================================================
+ Coverage   73.5326%   73.8917%   +0.3590%     
================================================
  Files          1680       1710        +30     
  Lines        464728     474884     +10156     
================================================
+ Hits         341727     350900      +9173     
- Misses       102158     102404       +246     
- Partials      20843      21580       +737     
Flag Coverage Δ
integration 45.6790% <44.4444%> (?)
unit 72.3399% <96.2963%> (+0.0661%) ⬆️

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

Components Coverage Δ
dumpling 52.6910% <ø> (ø)
parser ∅ <ø> (∅)
br 45.7463% <ø> (-0.0223%) ⬇️

@ti-chi-bot ti-chi-bot bot added the needs-1-more-lgtm Indicates a PR needs 1 more LGTM. label Dec 29, 2024
@ti-chi-bot ti-chi-bot bot added size/XXL Denotes a PR that changes 1000+ lines, ignoring generated files. and removed size/XL Denotes a PR that changes 500-999 lines, ignoring generated files. labels Dec 29, 2024
@winoros winoros force-pushed the remove-cols-live-updates branch from 297fb21 to 111a58d Compare December 29, 2024 20:24
@ti-chi-bot ti-chi-bot bot added lgtm and removed needs-1-more-lgtm Indicates a PR needs 1 more LGTM. labels Dec 30, 2024
Copy link

ti-chi-bot bot commented Dec 30, 2024

[LGTM Timeline notifier]

Timeline:

  • 2024-12-29 01:13:24.15158243 +0000 UTC m=+226539.507586969: ☑️ agreed by lance6716.
  • 2024-12-30 02:13:22.48680886 +0000 UTC m=+316537.842813398: ☑️ agreed by qw4990.

Copy link
Member

@Rustin170506 Rustin170506 left a comment

Choose a reason for hiding this comment

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

/hold

Thanks!

func (ctx *litTableMutateContext) UpdatePhysicalTableDelta(
physicalTableID int64, _ int64,
_ int64, cols variable.DeltaCols,
func (*litTableMutateContext) UpdatePhysicalTableDelta(
Copy link
Member

@Rustin170506 Rustin170506 Dec 30, 2024

Choose a reason for hiding this comment

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

Can we even delete this function? I believe we can delete the interface as well.

Copy link
Member Author

Choose a reason for hiding this comment

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

The interface MutateContext will be used in the normal write path. We cannot delete the MutateContext interface.
We can only let the litTableMutateContext not impl the interface StatisticsSupport and return a nil for its GetStatisticsSupport and add an intest.Assert(false) inside it.

@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 Dec 30, 2024
@@ -257,13 +252,11 @@ type RemoveRecordOption interface {

// ExtraPartialRowOption is the combined one of IndexesLayout and ColumnSizeOption.
type ExtraPartialRowOption struct {
IndexesRowLayout IndexesLayout
ColumnsSizeHelper *ColumnsSizeHelper
Copy link
Member

Choose a reason for hiding this comment

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

I think struct ColumnsSizeHelper can also be removed now.

@time-and-fate
Copy link
Member

I think the changes in the latest commit are incorrect.

@winoros winoros force-pushed the remove-cols-live-updates branch from b63ca1d to 1805653 Compare December 30, 2024 17:36
@winoros
Copy link
Member Author

winoros commented Dec 30, 2024

some tests like TestReplaceConflictOneUniqueKey failed if we cleaned the litTableMutateContext.
Reverted them.

Copy link

ti-chi-bot bot commented Dec 30, 2024

@winoros: 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
pull-unit-test-ddlv1 3ca5e1c link true /test pull-unit-test-ddlv1

Full PR test history. Your PR dashboard.

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.

Copy link
Member

@Rustin170506 Rustin170506 left a comment

Choose a reason for hiding this comment

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

Thanks! :shipit:

require.Equal(t, map[int64]int64{1: 2, 3: 9, 4: 3}, tblCtx.GetColumnSize(123))
// test gets a non-existed table
require.Empty(t, tblCtx.GetColumnSize(456))
stats.UpdatePhysicalTableDelta(123, 5, 2)
Copy link
Member

Choose a reason for hiding this comment

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

Perhaps we can delete them at all.

Copy link

ti-chi-bot bot commented Dec 31, 2024

[APPROVALNOTIFIER] This PR is NOT APPROVED

This pull-request has been approved by: lance6716, qw4990, Rustin170506
Once this PR has been reviewed and has the lgtm label, please assign gmhdbjd, yudongusa for approval, ensuring that each of them provides their approval before proceeding. 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

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
do-not-merge/hold Indicates that a PR should not merge because someone has issued a /hold command. lgtm release-note-none Denotes a PR that doesn't merit a release note. sig/planner SIG: Planner 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.

Drop live updates of the column size
5 participants