Skip to content

Fix memory leak in aggregation function in window#9933

Merged
ti-chi-bot[bot] merged 5 commits intopingcap:masterfrom
xzhangxian1008:fix-9930
Mar 4, 2025
Merged

Fix memory leak in aggregation function in window#9933
ti-chi-bot[bot] merged 5 commits intopingcap:masterfrom
xzhangxian1008:fix-9930

Conversation

@xzhangxian1008
Copy link
Contributor

What problem does this PR solve?

Issue Number: close #9930

Problem Summary:

What is changed and how it works?


Check List

Tests

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

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

Fix memory leak in aggregation function in window

@ti-chi-bot ti-chi-bot bot added do-not-merge/needs-triage-completed release-note Denotes a PR that will be considered when it comes time to generate release notes. size/XS Denotes a PR that changes 0-9 lines, ignoring generated files. labels Feb 28, 2025
@xzhangxian1008
Copy link
Contributor Author

/cc @windtalker @yibin87

@xzhangxian1008
Copy link
Contributor Author

/cc @windtalker @yibin87

@xzhangxian1008
Copy link
Contributor Author

/retest

Copy link
Contributor

@windtalker windtalker left a comment

Choose a reason for hiding this comment

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

no test?

}
}

agg_func->reset(agg_state.data());
Copy link
Contributor

Choose a reason for hiding this comment

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

why not use destroy here?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

why not use destroy here?

done

@xzhangxian1008
Copy link
Contributor Author

no test?

Origin tests could cover the memory leak case.

@xzhangxian1008
Copy link
Contributor Author

/cc @windtalker @yibin87

@ti-chi-bot ti-chi-bot bot requested a review from windtalker March 4, 2025 01:19
Copy link
Contributor

@windtalker windtalker left a comment

Choose a reason for hiding this comment

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

lgtm

@ti-chi-bot ti-chi-bot bot added needs-1-more-lgtm Indicates a PR needs 1 more LGTM. approved labels Mar 4, 2025
Copy link
Contributor

@yibin87 yibin87 left a comment

Choose a reason for hiding this comment

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

LGTM

@ti-chi-bot
Copy link
Contributor

ti-chi-bot bot commented Mar 4, 2025

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: windtalker, yibin87

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

The pull request process is described here

Details Needs approval from an approver in each of these files:

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 Mar 4, 2025
@ti-chi-bot
Copy link
Contributor

ti-chi-bot bot commented Mar 4, 2025

[LGTM Timeline notifier]

Timeline:

  • 2025-03-04 05:47:14.836013711 +0000 UTC m=+334147.964933450: ☑️ agreed by windtalker.
  • 2025-03-04 07:38:32.869116405 +0000 UTC m=+340825.998036149: ☑️ agreed by yibin87.

@ti-chi-bot ti-chi-bot bot merged commit 42af0a9 into pingcap:master Mar 4, 2025
5 checks passed
@xzhangxian1008 xzhangxian1008 deleted the fix-9930 branch March 5, 2025 01:08
@xzhangxian1008
Copy link
Contributor Author

/cherrypick release-8.5-20250310-v8.5.1

@ti-chi-bot
Copy link
Member

@xzhangxian1008: new pull request created to branch release-8.5-20250310-v8.5.1: #9984.

Details

In response to this:

/cherrypick release-8.5-20250310-v8.5.1

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 bot pushed a commit that referenced this pull request Mar 11, 2025
close #9930

Co-authored-by: xzhangxian1008 <xzhangxian@foxmail.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

approved lgtm release-note Denotes a PR that will be considered when it comes time to generate release notes. size/XS Denotes a PR that changes 0-9 lines, ignoring generated files.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Memory leak in aggregation function in window

4 participants