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: re-compile query if range rebuild fails for cached plan #17090

Merged
merged 6 commits into from
May 12, 2020

Conversation

eurekaka
Copy link
Contributor

What problem does this PR solve?

Issue Number: close #10111

Problem Summary:

Overflow error for unsigned handle is reported when plan cache is enabled.

What is changed and how it works?

What's Changed:

Fallback to optimizer if rebuildRange failed, instead of reporting error.

How it Works:

This PR can avoid error for the issue case, the complete fix is differentiate user variable types.

Related changes

  • Need to cherry-pick to the release branch

Check List

Tests

  • Unit test

Side effects

N/A

Release note

  • re-compile query if range rebuild fails for cached plan

@eurekaka eurekaka added type/enhancement The issue or PR belongs to an enhancement. sig/planner SIG: Planner needs-cherry-pick-4.0 labels May 11, 2020
@eurekaka eurekaka requested a review from a team as a code owner May 11, 2020 08:14
@ghost ghost requested review from francis0407 and removed request for a team May 11, 2020 08:14
planner/core/common_plans.go Outdated Show resolved Hide resolved
planner/core/prepare_test.go Show resolved Hide resolved
@codecov
Copy link

codecov bot commented May 11, 2020

Codecov Report

Merging #17090 into master will increase coverage by 0.0583%.
The diff coverage is n/a.

@@               Coverage Diff                @@
##             master     #17090        +/-   ##
================================================
+ Coverage   79.9933%   80.0517%   +0.0583%     
================================================
  Files           510        510                
  Lines        139009     139235       +226     
================================================
+ Hits         111198     111460       +262     
+ Misses        18844      18819        -25     
+ Partials       8967       8956        -11     

@eurekaka eurekaka requested a review from danmay319 May 11, 2020 08:52
@eurekaka eurekaka requested a review from zz-jason May 11, 2020 09:04
Copy link
Member

@zz-jason zz-jason left a comment

Choose a reason for hiding this comment

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

LGTM

@zz-jason zz-jason added the status/LGT1 Indicates that a PR has LGTM 1. label May 11, 2020
Copy link
Contributor

@danmay319 danmay319 left a comment

Choose a reason for hiding this comment

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

LGTM

Copy link
Contributor

@lzmhhh123 lzmhhh123 left a comment

Choose a reason for hiding this comment

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

LGTM

@lzmhhh123 lzmhhh123 added status/can-merge Indicates a PR has been approved by a committer. status/LGT2 Indicates that a PR has LGTM 2. and removed status/LGT1 Indicates that a PR has LGTM 1. labels May 12, 2020
@sre-bot
Copy link
Contributor

sre-bot commented May 12, 2020

/run-all-tests

@sre-bot
Copy link
Contributor

sre-bot commented May 12, 2020

cherry pick to release-4.0 in PR #17120

@eurekaka eurekaka deleted the rebuild_range branch May 12, 2020 07:02
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
sig/planner SIG: Planner status/can-merge Indicates a PR has been approved by a committer. status/LGT2 Indicates that a PR has LGTM 2. type/enhancement The issue or PR belongs to an enhancement.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

big unsigned bigint primary key point-select with plan cache enable error
5 participants