How to fix bug Memory Leak in Tomcat server

deployment, java, memory-leaks, tomcat7

Solution

Make sure that you implement a ServletContextListener and clean up any resources (e.g. threads, timers, singletons, hibernate) that may still be active or referenced at the time that contextDestroyed() is called.

Problem

I have a problem about Memory Leak in Tomcat server. When I undeploy and redeploy the error message war appeared as below: The following web applications were stopped (reloaded, undeployed), but their classes from previous runs are still loaded in memory, thus causing a memory leak (use a profiler to confirm): /myWebApplication How can I fix it and deploy as normally If anyone known that , please help me . Thank you very much !

Original source

Related problems