On Wed, 23 Aug 2023 17:16:15 GMT, Daniel Fuchs <dfu...@openjdk.org> wrote:

> We could create a singleton instance of TemporaryLoggerFinder in the 
> TemporaryLoggerFinder class and return that.

I think the disadvantage is that this singleton instance will never be GCed 
(till `LoggerFinderLoader` class itself is unloaded) unlike just using a new 
instance at the call site. Having said that, not being GCed doesn't make a huge 
difference given what this singleton instance does or holds on to.

-------------

PR Review Comment: https://git.openjdk.org/jdk/pull/15404#discussion_r1305512530

Reply via email to