Shawyeok commented on PR #15766:
URL: https://github.com/apache/pulsar/pull/15766#issuecomment-1136718087

   > Thread1: topicPublishRateLimiter is null, and and it will not invoke close 
in line:1216. Then it stop before line:1219
   Thread2: set topicPublishRateLimiter a new value, for example, limiter2. 
Then thread2 stop.
   Thread1: set topicPublishRateLimiter as 
PublishRateLimiter.DISABLED_RATE_LIMITER at line:1219
   limter2 will never be accessable, and may cause resource leakages.
   
   In scenario above, `limiter2` could be garbage collected, correct me if I 
miss something.


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to