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

planner: introduce hashEquals interface for expression.Expression #55793

Merged

Conversation

AilinKid
Copy link
Contributor

@AilinKid AilinKid commented Sep 2, 2024

What problem does this PR solve?

Issue Number: ref #51664

Problem Summary:

What changed and how does it work?

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

.
Signed-off-by: arenatlx <314806019@qq.com>
@ti-chi-bot ti-chi-bot bot added release-note-none Denotes a PR that doesn't merit a release note. sig/planner SIG: Planner size/L Denotes a PR that changes 100-499 lines, ignoring generated files. labels Sep 2, 2024
Copy link

tiprow bot commented Sep 2, 2024

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

.
Signed-off-by: arenatlx <314806019@qq.com>
Copy link

codecov bot commented Sep 2, 2024

Codecov Report

Attention: Patch coverage is 49.60630% with 64 lines in your changes missing coverage. Please review.

Project coverage is 58.8680%. Comparing base (dd114f1) to head (3a95596).
Report is 68 commits behind head on master.

Additional details and impacted files
@@                Coverage Diff                @@
##             master     #55793         +/-   ##
=================================================
- Coverage   72.8820%   58.8680%   -14.0141%     
=================================================
  Files          1584       1760        +176     
  Lines        443197     660620     +217423     
=================================================
+ Hits         323011     388894      +65883     
- Misses       100342     246149     +145807     
- Partials      19844      25577       +5733     
Flag Coverage Δ
integration 41.7353% <0.0000%> (?)
unit 74.0141% <41.0714%> (+2.0014%) ⬆️

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

Components Coverage Δ
dumpling 54.5253% <ø> (+1.5686%) ⬆️
parser ∅ <ø> (∅)
br 63.6488% <ø> (+18.1872%) ⬆️

.
Signed-off-by: arenatlx <314806019@qq.com>
.
Signed-off-by: arenatlx <314806019@qq.com>
.
Signed-off-by: arenatlx <314806019@qq.com>
.
Signed-off-by: arenatlx <314806019@qq.com>
.
Signed-off-by: arenatlx <314806019@qq.com>
@AilinKid
Copy link
Contributor Author

AilinKid commented Sep 2, 2024

/ok-to-test

@ti-chi-bot ti-chi-bot bot added the ok-to-test Indicates a PR is ready to be tested. label Sep 2, 2024
.
Signed-off-by: arenatlx <314806019@qq.com>
ok = ok && (sf.RetType == nil && sf2.RetType == nil || sf.RetType != nil && sf2.RetType != nil && sf.RetType.Equals(sf2.RetType))
if len(sf.GetArgs()) != len(sf2.GetArgs()) {
return false
}
Copy link
Member

Choose a reason for hiding this comment

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

so if ok is false, we can return first.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

make sense

Copy link
Contributor

@elsa0520 elsa0520 left a comment

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 Sep 6, 2024
Copy link
Contributor

@windtalker windtalker left a comment

Choose a reason for hiding this comment

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

LGTM

default:
return false
}
return col.Column.Equals(&col2.Column)
Copy link
Contributor

Choose a reason for hiding this comment

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

Don't need to check Data in CorrelatedColumn?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

runtime bound data shouldn‘t be cared in planner phase

Copy link
Contributor

Choose a reason for hiding this comment

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

OK

Copy link

ti-chi-bot bot commented Sep 6, 2024

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: elsa0520, windtalker

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 approved lgtm and removed needs-1-more-lgtm Indicates a PR needs 1 more LGTM. labels Sep 6, 2024
Copy link

ti-chi-bot bot commented Sep 6, 2024

[LGTM Timeline notifier]

Timeline:

  • 2024-09-06 07:22:00.818758579 +0000 UTC m=+601845.336811518: ☑️ agreed by elsa0520.
  • 2024-09-06 09:48:17.053830557 +0000 UTC m=+4166.794254491: ☑️ agreed by windtalker.

@windtalker
Copy link
Contributor

/hold

@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 Sep 6, 2024
@windtalker
Copy link
Contributor

/hold cancel

@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 Sep 9, 2024
@ti-chi-bot ti-chi-bot bot merged commit 4ab1765 into pingcap:master Sep 9, 2024
23 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
approved lgtm ok-to-test Indicates a PR is ready to be tested. release-note-none Denotes a PR that doesn't merit a release note. sig/planner SIG: Planner 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.

4 participants