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

plan: do not cache plan for query on range partition table (#15697) #15749

Closed

Conversation

sre-bot
Copy link
Contributor

@sre-bot sre-bot commented Mar 26, 2020

cherry-pick #15697 to release-3.1


What problem does this PR solve?

Issue Number: close #15720

Problem Summary:
Query on range partition may return error when using prepared plan cache, because table id is written in physical plan. Some user may use partition + plan cache when TiDB 4.0-rc released. So currently let plan-cache do not cache query on range partition table.

What is changed and how it works?

Proposal: xxx

What's Changed:

Add isRangePartition to check whether a plan is on range partition table.

How it Works:

If a plan is on range partition table, plan cache will not cache it.

Related changes

  • PR to update pingcap/docs/pingcap/docs-cn:
  • PR to update pingcap/tidb-ansible:
  • Need to cherry-pick to the release branch

Check List

Tests

  • Unit test

Side effects

  • Performance regression
    • Consumes more CPU (a little)

Release note

@sre-bot
Copy link
Contributor Author

sre-bot commented Mar 26, 2020

/run-all-tests

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants