Re: [PR] KAFKA-16086: Fix memory leak in RocksDBStore [kafka]
nicktelford commented on PR #15135: URL: https://github.com/apache/kafka/pull/15135#issuecomment-1878840727 IntelliJ will report a warning, provided that the object isn't passed to another method (as we do with `RocksDB.listColumnFamilies`). I can't get spotbugs to report this bug even if it's not passed to another method. I'm not even sure spotbugs is configured to report this problem, although I didn't see anything that would exclude it in `spotbugs-exclude.xml`. -- 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: jira-unsubscr...@kafka.apache.org For queries about this service, please contact Infrastructure at: us...@infra.apache.org
Re: [PR] KAFKA-16086: Fix memory leak in RocksDBStore [kafka]
lucasbru merged PR #15135: URL: https://github.com/apache/kafka/pull/15135 -- 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: jira-unsubscr...@kafka.apache.org For queries about this service, please contact Infrastructure at: us...@infra.apache.org
Re: [PR] KAFKA-16086: Fix memory leak in RocksDBStore [kafka]
lucasbru commented on PR #15135: URL: https://github.com/apache/kafka/pull/15135#issuecomment-1878750810 My hunch is that spotbugs won't report it when it's leaked from the method via another method call (here, `RocksDB.listColumnFamilies`). But yeah, better to check -- 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: jira-unsubscr...@kafka.apache.org For queries about this service, please contact Infrastructure at: us...@infra.apache.org
Re: [PR] KAFKA-16086: Fix memory leak in RocksDBStore [kafka]
divijvaidya commented on PR #15135: URL: https://github.com/apache/kafka/pull/15135#issuecomment-1878694769 I agree @nicktelford, there could be false positives. As a followup to this PR, can you please create a JIRA to investigate why spotbugs didn't catch it for us and make necessary changes. -- 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: jira-unsubscr...@kafka.apache.org For queries about this service, please contact Infrastructure at: us...@infra.apache.org
Re: [PR] KAFKA-16086: Fix memory leak in RocksDBStore [kafka]
nicktelford commented on PR #15135: URL: https://github.com/apache/kafka/pull/15135#issuecomment-1878591135 > Is there a way we could have caught this? (perhaps spotbugs telling that an autocloseable object is not getting closed) > > see: https://spotbugs.readthedocs.io/en/latest/bugDescriptions.html#obl-method-may-fail-to-clean-up-stream-or-resource-obl-unsatisfied-obligation It does seem like this could have been caught by some tooling. Usually, the problem with AutoCloseables are when they're created/closed across a scope that covers multiple methods, because you can't use a try-with-resources. But in this case, it's allocated in a local scope, so static analysis should be able to determine that it's never closed. -- 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: jira-unsubscr...@kafka.apache.org For queries about this service, please contact Infrastructure at: us...@infra.apache.org
Re: [PR] KAFKA-16086: Fix memory leak in RocksDBStore [kafka]
divijvaidya commented on PR #15135: URL: https://github.com/apache/kafka/pull/15135#issuecomment-1878582350 Is there a way we could have caught this? (perhaps spotbugs telling that an autocloseable object is not getting closed) -- 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: jira-unsubscr...@kafka.apache.org For queries about this service, please contact Infrastructure at: us...@infra.apache.org