Description of problem:
If the webapp is deployed multiple times (eg during development), it causes a PermGen leak, eventually leading to java.lang.OutOfMemoryError: PermGen space
Version-Release number of selected component (if applicable):
Steps to Reproduce:
1. Deploy zanata.war [touch zanata.war.dodeploy and wait about 25 sec]
2. Undeploy zanata.war [touch zanata.war.undeploy and wait about 5 sec]
3. Generate a thread dump using Ctrl-\ 4. Repeat 5 or 6 times
Thread dump shows "log4j mail appender" and "GWTEventService-UserActivityScheduler" still running after each undeploy.
After about 5 iterations: java.lang.OutOfMemoryError: PermGen space, server unresponsive
Thread dump does not show "log4j mail appender" and "GWTEventService-UserActivityScheduler" running.
https://github.com/mjiderhamn/classloader-leak-prevention looks promising