Details
Description
When creating a simple Grails application and deploying the WAR file on a tomcat, the tomcat logs report memory leaks of threads and ThreadLocal variables when the application is undeployed or the server is shut down.
The sample application (created with 'grails bug-report') is attached to this bug report.
Related issues:
Excerpt of the catalina.out log file:
... 22-May-2012 17:25:21 org.apache.catalina.core.StandardService stopInternal INFO: Stopping service Catalina 22-May-2012 17:25:21 org.apache.catalina.loader.WebappClassLoader clearReferencesThreads SEVERE: The web application [/SecExTest-0.1] appears to have started a thread named [Timer-1] but has failed to stop it. This is very likely to create a memory leak. 22-May-2012 17:25:21 org.apache.catalina.loader.WebappClassLoader checkThreadLocalMapForLeaks SEVERE: The web application [/SecExTest-0.1] created a ThreadLocal with key of type [org.codehaus.groovy.grails.orm.hibernate.metaclass.AbstractSavePersistentMethod$1] (value [org.codehaus.groovy.grails.orm.hibernate.metaclass.AbstractSavePersistentMethod$1@4f46c96c]) and a value of type [java.util.HashSet] (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. 22-May-2012 17:25:21 org.apache.catalina.loader.WebappClassLoader checkThreadLocalMapForLeaks SEVERE: The web application [/SecExTest-0.1] created a ThreadLocal with key of type [org.codehaus.groovy.grails.orm.hibernate.metaclass.AbstractSavePersistentMethod$1] (value [org.codehaus.groovy.grails.orm.hibernate.metaclass.AbstractSavePersistentMethod$1@4f46c96c]) and a value of type [java.util.HashSet] (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. 22-May-2012 17:25:21 org.apache.catalina.loader.WebappClassLoader checkThreadLocalMapForLeaks SEVERE: The web application [/SecExTest-0.1] 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@3051fa1d]) and a value of type [java.lang.Boolean] (value [false]) 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. 22-May-2012 17:25:21 org.apache.catalina.loader.WebappClassLoader checkThreadLocalMapForLeaks SEVERE: The web application [/SecExTest-0.1] created a ThreadLocal with key of type [org.codehaus.groovy.grails.orm.hibernate.metaclass.AbstractSavePersistentMethod$1] (value [org.codehaus.groovy.grails.orm.hibernate.metaclass.AbstractSavePersistentMethod$1@4f46c96c]) and a value of type [java.util.HashSet] (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. 22-May-2012 17:25:21 org.apache.catalina.loader.WebappClassLoader checkThreadLocalMapForLeaks SEVERE: The web application [/SecExTest-0.1] created a ThreadLocal with key of type [org.codehaus.groovy.grails.orm.hibernate.support.HibernatePersistenceContextInterceptor$3] (value [org.codehaus.groovy.grails.orm.hibernate.support.HibernatePersistenceContextInterceptor$3@55fb9eb3]) and a value of type [java.lang.Integer] (value [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. 22-May-2012 17:25:21 org.apache.catalina.loader.WebappClassLoader checkThreadLocalMapForLeaks SEVERE: The web application [/SecExTest-0.1] 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@3051fa1d]) and a value of type [java.lang.Boolean] (value [false]) 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. 22-May-2012 17:25:21 org.apache.catalina.loader.WebappClassLoader checkThreadLocalMapForLeaks SEVERE: The web application [/SecExTest-0.1] created a ThreadLocal with key of type [org.codehaus.groovy.grails.orm.hibernate.metaclass.AbstractSavePersistentMethod$1] (value [org.codehaus.groovy.grails.orm.hibernate.metaclass.AbstractSavePersistentMethod$1@4f46c96c]) and a value of type [java.util.HashSet] (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. 22-May-2012 17:25:21 org.apache.catalina.loader.WebappClassLoader checkThreadLocalMapForLeaks SEVERE: The web application [/SecExTest-0.1] created a ThreadLocal with key of type [org.codehaus.groovy.grails.orm.hibernate.support.HibernatePersistenceContextInterceptor$3] (value [org.codehaus.groovy.grails.orm.hibernate.support.HibernatePersistenceContextInterceptor$3@55fb9eb3]) and a value of type [java.lang.Integer] (value [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. 22-May-2012 17:25:21 org.apache.catalina.loader.WebappClassLoader checkThreadLocalMapForLeaks SEVERE: The web application [/SecExTest-0.1] created a ThreadLocal with key of type [org.codehaus.groovy.grails.orm.hibernate.metaclass.AbstractSavePersistentMethod$1] (value [org.codehaus.groovy.grails.orm.hibernate.metaclass.AbstractSavePersistentMethod$1@4f46c96c]) and a value of type [java.util.HashSet] (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. 22-May-2012 17:25:21 org.apache.catalina.loader.WebappClassLoader checkThreadLocalMapForLeaks SEVERE: The web application [/SecExTest-0.1] 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@3051fa1d]) and a value of type [java.lang.Boolean] (value [false]) 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. 22-May-2012 17:25:21 org.apache.catalina.loader.WebappClassLoader checkThreadLocalMapForLeaks SEVERE: The web application [/SecExTest-0.1] created a ThreadLocal with key of type [org.codehaus.groovy.grails.orm.hibernate.metaclass.AbstractSavePersistentMethod$1] (value [org.codehaus.groovy.grails.orm.hibernate.metaclass.AbstractSavePersistentMethod$1@4f46c96c]) and a value of type [java.util.HashSet] (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. 22-May-2012 17:25:21 org.apache.catalina.loader.WebappClassLoader checkThreadLocalMapForLeaks SEVERE: The web application [/SecExTest-0.1] created a ThreadLocal with key of type [org.codehaus.groovy.grails.orm.hibernate.support.HibernatePersistenceContextInterceptor$3] (value [org.codehaus.groovy.grails.orm.hibernate.support.HibernatePersistenceContextInterceptor$3@55fb9eb3]) and a value of type [java.lang.Integer] (value [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. 22-May-2012 17:25:21 org.apache.catalina.loader.WebappClassLoader checkThreadLocalMapForLeaks SEVERE: The web application [/SecExTest-0.1] 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@3051fa1d]) and a value of type [java.lang.Boolean] (value [false]) 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. 22-May-2012 17:25:21 org.apache.catalina.loader.WebappClassLoader checkThreadLocalMapForLeaks SEVERE: The web application [/SecExTest-0.1] created a ThreadLocal with key of type [org.codehaus.groovy.grails.orm.hibernate.metaclass.AbstractSavePersistentMethod$1] (value [org.codehaus.groovy.grails.orm.hibernate.metaclass.AbstractSavePersistentMethod$1@4f46c96c]) and a value of type [java.util.HashSet] (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. 22-May-2012 17:25:21 org.apache.catalina.loader.WebappClassLoader checkThreadLocalMapForLeaks SEVERE: The web application [/SecExTest-0.1] created a ThreadLocal with key of type [org.codehaus.groovy.grails.orm.hibernate.support.HibernatePersistenceContextInterceptor$3] (value [org.codehaus.groovy.grails.orm.hibernate.support.HibernatePersistenceContextInterceptor$3@55fb9eb3]) and a value of type [java.lang.Integer] (value [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. 22-May-2012 17:25:21 org.apache.catalina.loader.WebappClassLoader checkThreadLocalMapForLeaks SEVERE: The web application [/SecExTest-0.1] 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@3051fa1d]) and a value of type [java.lang.Boolean] (value [false]) 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. 22-May-2012 17:25:21 org.apache.catalina.loader.WebappClassLoader checkThreadLocalMapForLeaks SEVERE: The web application [/SecExTest-0.1] created a ThreadLocal with key of type [org.codehaus.groovy.grails.orm.hibernate.metaclass.AbstractSavePersistentMethod$1] (value [org.codehaus.groovy.grails.orm.hibernate.metaclass.AbstractSavePersistentMethod$1@4f46c96c]) and a value of type [java.util.HashSet] (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. 22-May-2012 17:25:21 org.apache.catalina.loader.WebappClassLoader checkThreadLocalMapForLeaks SEVERE: The web application [/SecExTest-0.1] created a ThreadLocal with key of type [org.codehaus.groovy.grails.orm.hibernate.support.HibernatePersistenceContextInterceptor$3] (value [org.codehaus.groovy.grails.orm.hibernate.support.HibernatePersistenceContextInterceptor$3@55fb9eb3]) and a value of type [java.lang.Integer] (value [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. 22-May-2012 17:25:21 org.apache.catalina.loader.WebappClassLoader checkThreadLocalMapForLeaks SEVERE: The web application [/SecExTest-0.1] 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@3051fa1d]) and a value of type [java.lang.Boolean] (value [false]) 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. 22-May-2012 17:25:21 org.apache.catalina.loader.WebappClassLoader checkThreadLocalMapForLeaks SEVERE: The web application [/SecExTest-0.1] created a ThreadLocal with key of type [org.codehaus.groovy.grails.orm.hibernate.metaclass.AbstractSavePersistentMethod$1] (value [org.codehaus.groovy.grails.orm.hibernate.metaclass.AbstractSavePersistentMethod$1@4f46c96c]) and a value of type [java.util.HashSet] (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. 22-May-2012 17:25:21 org.apache.catalina.loader.WebappClassLoader checkThreadLocalMapForLeaks SEVERE: The web application [/SecExTest-0.1] created a ThreadLocal with key of type [org.codehaus.groovy.grails.orm.hibernate.support.HibernatePersistenceContextInterceptor$3] (value [org.codehaus.groovy.grails.orm.hibernate.support.HibernatePersistenceContextInterceptor$3@55fb9eb3]) and a value of type [java.lang.Integer] (value [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. 22-May-2012 17:25:21 org.apache.catalina.loader.WebappClassLoader checkThreadLocalMapForLeaks SEVERE: The web application [/SecExTest-0.1] 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@3051fa1d]) and a value of type [java.lang.Boolean] (value [false]) 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. 22-May-2012 17:25:21 org.apache.catalina.loader.WebappClassLoader checkThreadLocalMapForLeaks SEVERE: The web application [/SecExTest-0.1] created a ThreadLocal with key of type [org.codehaus.groovy.grails.orm.hibernate.metaclass.AbstractSavePersistentMethod$1] (value [org.codehaus.groovy.grails.orm.hibernate.metaclass.AbstractSavePersistentMethod$1@4f46c96c]) and a value of type [java.util.HashSet] (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. 22-May-2012 17:25:21 org.apache.catalina.loader.WebappClassLoader checkThreadLocalMapForLeaks SEVERE: The web application [/SecExTest-0.1] created a ThreadLocal with key of type [org.codehaus.groovy.grails.orm.hibernate.support.HibernatePersistenceContextInterceptor$3] (value [org.codehaus.groovy.grails.orm.hibernate.support.HibernatePersistenceContextInterceptor$3@55fb9eb3]) and a value of type [java.lang.Integer] (value [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. ...
Activity
- All
- Comments
- Work Log
- History
- Activity
- Git Commits
duplicates
GRAILS-5823