Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Yanel should shut down all threads #58

Open
michaelwechner opened this issue Jun 5, 2013 · 0 comments
Open

Yanel should shut down all threads #58

michaelwechner opened this issue Jun 5, 2013 · 0 comments
Assignees
Labels

Comments

@michaelwechner
Copy link
Member

Looking at local/apache-tomcat-7.0.25/logs/catalina.out while shutting down Yanel reveals that not all
threads are being stopped:

05.06.2013 23:18:32 org.apache.catalina.core.StandardServer awaitINFO: A valid shutdown command was received via the shutdown port. Stopping the Server instance.05.06.2013 23:18:32 org.apache.coyote.AbstractProtocol pauseINFO: Pausing ProtocolHandler ["http-bio-8080"]
05.06.2013 23:18:32 org.apache.coyote.AbstractProtocol pause
INFO: Pausing ProtocolHandler ["ajp-bio-8009"]05.06.2013 23:18:32 org.apache.catalina.core.StandardService stopInternalINFO: Stopping service Catalina05.06.2013 23:18:32 org.apache.catalina.loader.WebappClassLoader clearReferencesThreads
SCHWERWIEGEND: The web application [/yanel] appears to have started a thread named [MyScheduler_Worker-1] but has failed to stop it. This is very likely to cr
eate a memory leak.
05.06.2013 23:18:32 org.apache.catalina.loader.WebappClassLoader clearReferencesThreads
SCHWERWIEGEND: The web application [/yanel] appears to have started a thread named [MyScheduler_Worker-2] but has failed to stop it. This is very likely to cr
eate a memory leak.
05.06.2013 23:18:32 org.apache.catalina.loader.WebappClassLoader clearReferencesThreads
SCHWERWIEGEND: The web application [/yanel] appears to have started a thread named [MyScheduler_Worker-3] but has failed to stop it. This is very likely to cr
eate a memory leak.
05.06.2013 23:18:32 org.apache.catalina.loader.WebappClassLoader checkThreadLocalMapForLeaks
SCHWERWIEGEND: The web application [/yanel] created a ThreadLocal with key of type [org.apache.axis.utils.XMLUtils.ThreadLocalDocumentBuilder](value [org.apache.axis.utils.XMLUtils$ThreadLocalDocumentBuilder@3f29cfbb]) and a value of type [org.apache.xerces.jaxp.DocumentBuilderImpl](value [org.apache.xerces.jaxp.DocumentBuilderImpl@52051e62]) 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.
05.06.2013 23:18:32 org.apache.catalina.loader.WebappClassLoader checkThreadLocalMapForLeaks
SCHWERWIEGEND: The web application [/yanel] created a ThreadLocal with key of type [org.apache.axis.utils.XMLUtils.ThreadLocalDocumentBuilder](value [org.apache.axis.utils.XMLUtils$ThreadLocalDocumentBuilder@3f29cfbb]) and a value of type [org.apache.xerces.jaxp.DocumentBuilderImpl](value [org.apache.xerces.jaxp.DocumentBuilderImpl@4e0dddff]) 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.
05.06.2013 23:18:32 org.apache.coyote.AbstractProtocol stop
INFO: Stopping ProtocolHandler ["http-bio-8080"]
05.06.2013 23:18:32 org.apache.coyote.AbstractProtocol stop
INFO: Stopping ProtocolHandler ["ajp-bio-8009"]
05.06.2013 23:18:32 org.apache.coyote.AbstractProtocol destroy
INFO: Destroying ProtocolHandler ["http-bio-8080"]
05.06.2013 23:18:32 org.apache.coyote.AbstractProtocol destroy
INFO: Destroying ProtocolHandler ["ajp-bio-8009"]

Inside src/webapp/src/java/org/wyona/yanel/servlet/YanelServlet.java#destroy() we should make sure that all threads are being stopped, because otherwise the Tomcat process might keep hanging!

@ghost ghost assigned michaelwechner Jun 5, 2013
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

1 participant