blackdrag commented on issue #968: Fixed the Reference of the metaclass in ClassInfo.java to use a Weak… URL: https://github.com/apache/groovy/pull/968#issuecomment-511848762 From my POV this is no solution. We are using soft references, because in the past a weak reference gave the class free too fast leading to the runtime constantly recreating the meta class and thus to horrible performance. Also just using a SoftReference is not supposed to prevent the class to be unloaded. There are JVM configurations that behave like this though. Of course @NecOnIce is fully right when he says that the current configuration leads the JVM to use up all memory before anything is freed. Better would be a system in which we count how often we create the meta class and then maybe go with the strategy of creating first a weak reference and after a threshold has been reached to change it to a soft reference... just as an idea
---------------------------------------------------------------- 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. For queries about this service, please contact Infrastructure at: us...@infra.apache.org With regards, Apache Git Services