Skip to content

Load: fix memory leak when failed to send chunk data in first phase #15518

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

Merged
merged 1 commit into from
May 19, 2025

Conversation

DanielWang2035
Copy link
Collaborator

No description provided.

@DanielWang2035 DanielWang2035 requested a review from Copilot May 16, 2025 04:25
Copy link
Contributor

@Copilot Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull Request Overview

This PR addresses a memory leak issue in the load process by ensuring that memory usage is reduced even when the dispatch of a piece node fails. The key changes include:

  • Storing the result of the dispatch call in a variable (isDispatchSuccess) before reducing memory usage.
  • Deducting the memory usage prior to checking the dispatch result to avoid leaks.
  • Returning false immediately after the reduction when the dispatch fails.

@SteveYurongSu SteveYurongSu self-assigned this May 19, 2025
@SteveYurongSu SteveYurongSu merged commit 417ddd0 into apache:master May 19, 2025
17 checks passed
DanielWang2035 added a commit to DanielWang2035/iotdb that referenced this pull request May 20, 2025
…pache#15518)

This commit addresses a memory leak issue in the load process by ensuring that memory usage is reduced even when the dispatch of a piece node fails. The key changes include:

- Storing the result of the dispatch call in a variable (isDispatchSuccess) before reducing memory usage.
- Deducting the memory usage prior to checking the dispatch result to avoid leaks.
- Returning false immediately after the reduction when the dispatch fails.

(cherry picked from commit 417ddd0)
SteveYurongSu pushed a commit that referenced this pull request May 20, 2025
…15518) (#15542)

This commit addresses a memory leak issue in the load process by ensuring that memory usage is reduced even when the dispatch of a piece node fails. The key changes include:

- Storing the result of the dispatch call in a variable (isDispatchSuccess) before reducing memory usage.
- Deducting the memory usage prior to checking the dispatch result to avoid leaks.
- Returning false immediately after the reduction when the dispatch fails.

(cherry picked from commit 417ddd0)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants