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: add more test cases for global-level stats #23049

Merged
merged 9 commits into from
Mar 4, 2021

Conversation

Reminiscent
Copy link
Contributor

What problem does this PR solve?

Add more tests about global-level stats to ensure their correctness

What is changed and how it works?

Add more tests about global-level stats to ensure their correctness

Related changes

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

Check List

Tests

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

Side effects

  • Performance regression
    • Consumes more CPU
    • Consumes more MEM
  • Breaking backward compatibility

Release note

  • add more test cases for global-level stats

@Reminiscent Reminiscent requested a review from a team as a code owner March 2, 2021 07:52
@Reminiscent Reminiscent requested review from lzmhhh123 and removed request for a team March 2, 2021 07:52
@ti-chi-bot ti-chi-bot added the size/L Denotes a PR that changes 100-499 lines, ignoring generated files. label Mar 2, 2021
Comment on lines 419 to 425
globalStats.Hg[i], err = statistics.MergePartitionHist2GlobalHist(sc, allHg[i], popedTopN, numBuckets)
if err != nil {
return
if numBuckets != 0 {
globalStats.Hg[i], err = statistics.MergePartitionHist2GlobalHist(sc, allHg[i], popedTopN, numBuckets)
if err != nil {
return
}
} else {
globalStats.Hg[i] = allHg[i][0].Copy()
Copy link
Contributor Author

Choose a reason for hiding this comment

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

Only use to avoid some bugs. It will be deleted until these bugs have been fixed.

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
Copy link
Contributor

qw4990 commented Mar 4, 2021

/LGTM

@ti-chi-bot ti-chi-bot added the status/LGT1 Indicates that a PR has LGTM 1. label Mar 4, 2021
@ti-chi-bot
Copy link
Member

[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 writing /lgtm in a comment.
Reviewer can cancel approval by writing /lgtm cancel in a comment.

@ti-chi-bot ti-chi-bot added status/LGT2 Indicates that a PR has LGTM 2. and removed status/LGT1 Indicates that a PR has LGTM 1. labels Mar 4, 2021
@qw4990
Copy link
Contributor

qw4990 commented Mar 4, 2021

/run-all-tests

@qw4990 qw4990 added the status/can-merge Indicates a PR has been approved by a committer. label Mar 4, 2021
@ti-chi-bot ti-chi-bot removed the status/can-merge Indicates a PR has been approved by a committer. label Mar 4, 2021
@qw4990 qw4990 merged commit 1ae775f into pingcap:master Mar 4, 2021
@Reminiscent Reminiscent deleted the global-stats-test branch August 5, 2021 01:56
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
component/statistics size/L Denotes a PR that changes 100-499 lines, ignoring generated files. status/LGT2 Indicates that a PR has LGTM 2.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants