Uploaded image for project: 'Groovy'
  1. Groovy
  2. GROOVY-7913

ClassInfo.globalClassValue lead to GroovyClassLoader can't unload classes

    XMLWordPrintableJSON

    Details

    • Type: Bug
    • Status: Closed
    • Priority: Major
    • Resolution: Fixed
    • Affects Version/s: 2.4.6
    • Fix Version/s: 2.4.8
    • Component/s: class generator
    • Labels:
      None

      Description

      org.codehaus.groovy.reflection.ClassInfo:

      private static final GroovyClassValue<ClassInfo> globalClassValue = GroovyClassValueFactory.createGroovyClassValue(new ComputeValue<ClassInfo>(){
      		@Override
      		public ClassInfo computeValue(Class<?> type) {
      			ClassInfo ret = new ClassInfo(type);
      			globalClassSet.add(ret);
      			return ret;
      		}
      	});
      

      dynamic load groovy classes will be cached in globalClassValue
      can't unload classes
      cause java.lang.OutOfMemoryError: PermGen space

        Attachments

          Issue Links

            Activity

              People

              • Assignee:
                jwagenleitner John Wagenleitner
                Reporter:
                chenxiaojie chenxiaojie
              • Votes:
                0 Vote for this issue
                Watchers:
                2 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved: