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

statistics: compute and store column order correlation with handle #9315

Merged
merged 7 commits into from
Feb 27, 2019

Conversation

eurekaka
Copy link
Contributor

@eurekaka eurekaka commented Feb 15, 2019

What problem does this PR solve?

First step to fix #9067

What is changed and how it works?

  • compute order correlations between columns and handle column;
  • store this correlation in mysql.stats_histograms, i.e, in a newly added column Correlation;
  • update the upgrade logic and show stats_histograms correspondingly;

Check List

Tests

  • Unit test

Code changes

  • Has persistent data change

Side effects

  • Increased code complexity
  • Breaking backward compatibility: upgrade logic has been addressed in this PR also.

Related changes

N/A

@codecov-io
Copy link

codecov-io commented Feb 15, 2019

Codecov Report

❗ No coverage uploaded for pull request base (master@511a80b). Click here to learn what that means.
The diff coverage is 88.33%.

Impacted file tree graph

@@           Coverage Diff            @@
##             master   #9315   +/-   ##
========================================
  Coverage          ?   67.4%           
========================================
  Files             ?     373           
  Lines             ?   78557           
  Branches          ?       0           
========================================
  Hits              ?   52953           
  Misses            ?   20846           
  Partials          ?    4758
Impacted Files Coverage Δ
executor/builder.go 83.79% <ø> (ø)
executor/analyze.go 63.63% <100%> (ø)
statistics/table.go 83.11% <100%> (ø)
statistics/bootstrap.go 75% <100%> (ø)
executor/show_stats.go 89.78% <100%> (ø)
statistics/histogram.go 81.46% <100%> (ø)
session/bootstrap.go 83.43% <100%> (ø)
planner/core/planbuilder.go 49.02% <20%> (ø)
statistics/sample.go 88.88% <92%> (ø)
statistics/builder.go 89.88% <93.33%> (ø)

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 511a80b...720540b. Read the comment docs.

@eurekaka
Copy link
Contributor Author

/run-all-tests

@eurekaka
Copy link
Contributor Author

/run-all-tests tidb-test=pr/740

@qw4990 qw4990 self-requested a review February 22, 2019 02:44
@eurekaka
Copy link
Contributor Author

/run-all-tests tidb-test=pr/740

1 similar comment
@eurekaka
Copy link
Contributor Author

/run-all-tests tidb-test=pr/740

Copy link
Contributor

@alivxxx alivxxx left a comment

Choose a reason for hiding this comment

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

LGTM

@alivxxx alivxxx added the status/LGT1 Indicates that a PR has LGTM 1. label Feb 22, 2019
statistics/sample.go Outdated Show resolved Hide resolved
@eurekaka eurekaka requested a review from qw4990 February 26, 2019 09:47
Copy link
Contributor

@qw4990 qw4990 left a comment

Choose a reason for hiding this comment

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

LGTM

@qw4990 qw4990 added status/LGT2 Indicates that a PR has LGTM 2. and removed status/LGT1 Indicates that a PR has LGTM 1. labels Feb 26, 2019
qw4990
qw4990 previously approved these changes Feb 26, 2019
@eurekaka
Copy link
Contributor Author

Wait for https://github.com/pingcap/tidb-test/pull/740 to be merged together.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
component/statistics sig/execution SIG execution status/LGT2 Indicates that a PR has LGTM 2.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

YCSB workloade is too slow for scan operation
5 participants