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: allow refineArgs for plan cache in some situations #28944

Merged
merged 66 commits into from
Oct 29, 2021

Conversation

Reminiscent
Copy link
Contributor

@Reminiscent Reminiscent commented Oct 19, 2021

What problem does this PR solve?

Issue Number: close #28858

Problem Summary:
If we forbid the refineArgs for plan cache. The string <cmp> int will get an wrong answer. Because when we convert the string to double, it will lose precision.

What is changed and how it works?

  1. Allow refineArgs for plan cache in some situations. And forbid some plans to cache.
  2. When the plan can not be cached, we need to simplify the constant.

Check List

Tests

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

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

'None'

@ti-chi-bot
Copy link
Member

ti-chi-bot commented Oct 19, 2021

[REVIEW NOTIFICATION]

This pull request has been approved by:

  • qw4990
  • rebelice

To complete the pull request process, please ask the reviewers in the list to review by filling /cc @reviewer in the comment.
After your PR has acquired the required number of LGTMs, you can assign this pull request to the committer in the list by filling /assign @committer in the comment to help you merge this pull request.

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

Reviewer can indicate their review by submitting an approval review.
Reviewer can cancel approval by submitting a request changes review.

@ti-chi-bot ti-chi-bot added 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. labels Oct 19, 2021
@Reminiscent Reminiscent deleted the issue28858 branch October 19, 2021 07:06
@Reminiscent Reminiscent restored the issue28858 branch October 20, 2021 06:31
@Reminiscent Reminiscent reopened this Oct 20, 2021
@ti-chi-bot ti-chi-bot added size/L Denotes a PR that changes 100-499 lines, ignoring generated files. and removed size/M Denotes a PR that changes 30-99 lines, ignoring generated files. labels Oct 20, 2021
@qw4990
Copy link
Contributor

qw4990 commented Oct 29, 2021

/merge

@ti-chi-bot ti-chi-bot removed the status/can-merge Indicates a PR has been approved by a committer. label Oct 29, 2021
@qw4990
Copy link
Contributor

qw4990 commented Oct 29, 2021

/merge

@ti-chi-bot
Copy link
Member

This pull request has been accepted and is ready to merge.

Commit hash: 36c74af

@ti-chi-bot ti-chi-bot added the status/can-merge Indicates a PR has been approved by a committer. label Oct 29, 2021
@qw4990
Copy link
Contributor

qw4990 commented Oct 29, 2021

/merge

2 similar comments
@qw4990
Copy link
Contributor

qw4990 commented Oct 29, 2021

/merge

@qw4990
Copy link
Contributor

qw4990 commented Oct 29, 2021

/merge

@Reminiscent
Copy link
Contributor Author

/run-all-tests

@Reminiscent
Copy link
Contributor Author

/run-check_dev

1 similar comment
@qw4990
Copy link
Contributor

qw4990 commented Oct 29, 2021

/run-check_dev

@qw4990
Copy link
Contributor

qw4990 commented Oct 29, 2021

/run-all-tests

1 similar comment
@Reminiscent
Copy link
Contributor Author

/run-all-tests

@qw4990 qw4990 merged commit 83e559d into pingcap:master Oct 29, 2021
@Reminiscent Reminiscent deleted the issue28858 branch October 29, 2021 10:10
@qw4990
Copy link
Contributor

qw4990 commented Nov 4, 2021

/cherry-pick release-5.2

ti-srebot pushed a commit to ti-srebot/tidb that referenced this pull request Nov 4, 2021
Signed-off-by: ti-srebot <ti-srebot@pingcap.com>
@ti-srebot
Copy link
Contributor

cherry pick to release-5.2 in PR #29422

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
epic/plan-cache needs-cherry-pick-release-5.2 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. status/can-merge Indicates a PR has been approved by a committer. status/LGT2 Indicates that a PR has LGTM 2. type/bugfix This PR fixes a bug.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

prepare/execute return a wrong result after changing parameter's type
5 participants