In my catalina.out log, I see the following: I refuse the grails application:
INFO: Closing Spring root WebApplicationContext Jun 18, 2014 5:23:48 PM org.apache.catalina.loader.WebappClassLoader clearReferencesThreads SEVERE: The web application [/appName] appears to have started a thread named [PoolCleaner[935209663:1403137427048]] but has failed to stop it. This is very likely to create a memory leak. Jun 18, 2014 5:23:48 PM org.apache.catalina.loader.WebappClassLoader checkThreadLocalMapForLeaks SEVERE: The web application [/appName] created a ThreadLocal with key of type [org.codehaus.groovy.grails.orm.hibernate.support.HibernatePersistenceContextInterceptor$1] (value [org.codehaus.groovy.grails .orm.hibernate.support.HibernatePersistenceContextInterceptor$1@ 7b50a485]) and a value of type [java.util.HashMap] (value [{}]) but failed to remove it when the web application was stopped. Threads are going to be renewed over time to try and avoid a probable memory leak. Jun 18, 2014 5:23:48 PM org.apache.catalina.loader.WebappClassLoader checkThreadLocalMapForLeaks SEVERE: The web application [/appName] created a ThreadLocal with key of type [org.codehaus.groovy.grails.orm.hibernate.support.HibernatePersistenceContextInterceptor$2] (value [org.codehaus.groovy.grails .orm.hibernate.support.HibernatePersistenceContextInterceptor$2@ 6b615702]) and a value of type [java.util.HashMap] (value [{DEFAULT=0}]) but failed to remove it when the web application was stopped. Threads are going to be renewed over time to try and avoid a probable memory leak. Jun 18, 2014 5:23:48 PM org.apache.catalina.loader.WebappClassLoader checkThreadLocalMapForLeaks SEVERE: The web application [/appName] created a ThreadLocal with key of type [org.codehaus.groovy.grails.orm.hibernate.support.HibernatePersistenceContextInterceptor$1] (value [org.codehaus.groovy.grails .orm.hibernate.support.HibernatePersistenceContextInterceptor$1@ 7b50a485]) and a value of type [java.util.HashMap] (value [{}]) but failed to remove it when the web application was stopped. Threads are going to be renewed over time to try and avoid a probable memory leak. Jun 18, 2014 5:23:48 PM org.apache.catalina.loader.WebappClassLoader checkThreadLocalMapForLeaks SEVERE: The web application [/appName] created a ThreadLocal with key of type [org.codehaus.groovy.grails.orm.hibernate.support.HibernatePersistenceContextInterceptor$2] (value [org.codehaus.groovy.grails .orm.hibernate.support.HibernatePersistenceContextInterceptor$2@ 6b615702]) and a value of type [java.util.HashMap] (value [{DEFAULT=0}]) but failed to remove it when the web application was stopped. Threads are going to be renewed over time to try and avoid a probable memory leak.
In fact, I see more than 100 sleeping. It looks like there was a memory leak related to domain classes, which was fixed in Grails 2.0, but I'm using 2.35. If this is most likely something in my application that causes these leaks, I would like to know how to fix them. Thanks...
source share