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: move MergePartTopN2GlobalTopN into handle/globalstats #47901

Merged
merged 3 commits into from
Oct 23, 2023

Conversation

hawkingrei
Copy link
Member

@hawkingrei hawkingrei commented Oct 23, 2023

What problem does this PR solve?

Issue Number: ref #46905

Problem Summary:

What is changed and how it works?

We find it just use 100+ MB memory when to merge global topn without the largest number of partition. so for speeding up the merge-topn, we need to add more data structures such as bloomfilter. so we need to move the MergePartTopN2GlobalTopN into handle/globalstats.

just move the code. not change logical.

Check List

Tests

  • Unit test
  • Integration test
  • Manual test (add detailed scripts or steps below)
  • No need to test
    • I checked and no code files have been changed.

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

Please refer to Release Notes Language Style Guide to write a quality release note.

None

Signed-off-by: Weizhen Wang <wangweizhen@pingcap.com>
@ti-chi-bot ti-chi-bot bot added do-not-merge/needs-linked-issue do-not-merge/needs-tests-checked release-note-none Denotes a PR that doesn't merit a release note. size/L Denotes a PR that changes 100-499 lines, ignoring generated files. needs-cherry-pick-release-7.5 Should cherry pick this PR to release-7.5 branch. and removed do-not-merge/needs-linked-issue do-not-merge/needs-tests-checked labels Oct 23, 2023
Signed-off-by: Weizhen Wang <wangweizhen@pingcap.com>
Signed-off-by: Weizhen Wang <wangweizhen@pingcap.com>
@ti-chi-bot ti-chi-bot bot added size/XL Denotes a PR that changes 500-999 lines, ignoring generated files. and removed size/L Denotes a PR that changes 100-499 lines, ignoring generated files. labels Oct 23, 2023
@codecov
Copy link

codecov bot commented Oct 23, 2023

Codecov Report

Merging #47901 (e3c86ab) into master (515899f) will increase coverage by 1.1114%.
Report is 1 commits behind head on master.
The diff coverage is 77.7777%.

Additional details and impacted files
@@               Coverage Diff                @@
##             master     #47901        +/-   ##
================================================
+ Coverage   71.7312%   72.8427%   +1.1114%     
================================================
  Files          1399       1422        +23     
  Lines        405473     411974      +6501     
================================================
+ Hits         290851     300093      +9242     
+ Misses        94905      93033      -1872     
+ Partials      19717      18848       -869     
Flag Coverage Δ
integration 41.8404% <68.5185%> (?)
unit 71.7947% <77.7777%> (+0.0634%) ⬆️

Flags with carried forward coverage won't be shown. Click here to find out more.

Components Coverage Δ
dumpling 53.9913% <ø> (ø)
parser ∅ <ø> (∅)
br 48.8839% <ø> (-4.0817%) ⬇️

@ti-chi-bot ti-chi-bot bot added approved needs-1-more-lgtm Indicates a PR needs 1 more LGTM. labels Oct 23, 2023
@ti-chi-bot
Copy link

ti-chi-bot bot commented Oct 23, 2023

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: qw4990, time-and-fate

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

The pull request process is described here

Needs approval from an approver in each of these files:
  • OWNERS [qw4990,time-and-fate]

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@ti-chi-bot ti-chi-bot bot added lgtm and removed needs-1-more-lgtm Indicates a PR needs 1 more LGTM. labels Oct 23, 2023
@ti-chi-bot
Copy link

ti-chi-bot bot commented Oct 23, 2023

[LGTM Timeline notifier]

Timeline:

  • 2023-10-23 02:40:03.414742151 +0000 UTC m=+2229601.001852297: ☑️ agreed by qw4990.
  • 2023-10-23 03:29:47.97192902 +0000 UTC m=+2232585.559039164: ☑️ agreed by time-and-fate.

@ti-chi-bot ti-chi-bot bot merged commit 98b6c43 into pingcap:master Oct 23, 2023
@hawkingrei
Copy link
Member Author

/cherrypick release-7.5

@ti-chi-bot
Copy link
Member

In response to a cherrypick label: new pull request created to branch release-7.5: #47911.

@ti-chi-bot
Copy link
Member

@hawkingrei: new pull request could not be created: failed to create pull request against pingcap/tidb#release-7.5 from head ti-chi-bot:cherry-pick-47901-to-release-7.5: status code 422 not one of [201], body: {"message":"Validation Failed","errors":[{"resource":"PullRequest","code":"custom","message":"A pull request already exists for ti-chi-bot:cherry-pick-47901-to-release-7.5."}],"documentation_url":"https://docs.github.com/rest/pulls/pulls#create-a-pull-request"}

In response to this:

/cherrypick release-7.5

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the ti-community-infra/tichi repository.

ti-chi-bot pushed a commit to ti-chi-bot/tidb that referenced this pull request Oct 23, 2023
Signed-off-by: ti-chi-bot <ti-community-prow-bot@tidb.io>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
approved lgtm needs-cherry-pick-release-7.5 Should cherry pick this PR to release-7.5 branch. release-note-none Denotes a PR that doesn't merit a release note. size/XL Denotes a PR that changes 500-999 lines, ignoring generated files.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants