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

[fix][client] Fix memory leak in ClientCnx.newLookup when there's TooManyRequestsException #23971

Conversation

lhotari
Copy link
Member

@lhotari lhotari commented Feb 12, 2025

Motivation

There's a Netty ByteBuf leak in ClientCnx.newLookup when there's TooManyRequestsException.

Modifications

  • release the buffer before returning

Documentation

  • doc
  • doc-required
  • doc-not-needed
  • doc-complete

@lhotari lhotari added this to the 4.1.0 milestone Feb 12, 2025
@lhotari lhotari self-assigned this Feb 12, 2025
@lhotari lhotari changed the title [fix][client] Fix leak in ClientCnx.newLookup when there's TooManyRequestsException [fix][client] Fix memory leak in ClientCnx.newLookup when there's TooManyRequestsException Feb 12, 2025
@github-actions github-actions bot added the doc-not-needed Your PR changes do not impact docs label Feb 12, 2025
@codecov-commenter
Copy link

codecov-commenter commented Feb 12, 2025

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 74.22%. Comparing base (bbc6224) to head (9278e1b).
Report is 905 commits behind head on master.

Additional details and impacted files

Impacted file tree graph

@@             Coverage Diff              @@
##             master   #23971      +/-   ##
============================================
+ Coverage     73.57%   74.22%   +0.64%     
+ Complexity    32624    32270     -354     
============================================
  Files          1877     1853      -24     
  Lines        139502   143821    +4319     
  Branches      15299    16337    +1038     
============================================
+ Hits         102638   106748    +4110     
+ Misses        28908    28684     -224     
- Partials       7956     8389     +433     
Flag Coverage Δ
inttests 26.75% <0.00%> (+2.17%) ⬆️
systests 23.27% <0.00%> (-1.06%) ⬇️
unittests 73.73% <100.00%> (+0.88%) ⬆️

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

Files with missing lines Coverage Δ
.../java/org/apache/pulsar/client/impl/ClientCnx.java 72.89% <100.00%> (+1.11%) ⬆️

... and 1041 files with indirect coverage changes

@merlimat merlimat merged commit b898cb9 into apache:master Feb 12, 2025
56 of 58 checks passed
merlimat pushed a commit that referenced this pull request Feb 12, 2025
merlimat pushed a commit that referenced this pull request Feb 12, 2025
merlimat pushed a commit that referenced this pull request Feb 12, 2025
nikhil-ctds pushed a commit to datastax/pulsar that referenced this pull request Feb 19, 2025
mukesh-ctds pushed a commit to datastax/pulsar that referenced this pull request Feb 20, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants