|Summary:||Add display of PermGen memory pool usage to the Status page of the Manager webapp|
|Product:||Tomcat 7||Reporter:||Konstantin Kolinko <knst.kolinko>|
|Component:||Manager||Assignee:||Tomcat Developers Mailing List <dev>|
Description Konstantin Kolinko 2012-11-13 22:39:44 UTC
It would be nice to add display of the PermGen memory pool usage to the Status page of the Manager webapp. This is because OutOfMemoryError's caused by PermGen pool exhaustion are fatal for the server and are hard to predict, as they are are not visible from the simple Free/Max/Total Heap statistics. Technically speaking, the information is provided by "MemoryPool" MBeans. It is easier to display all memory pools at once rather than to search for specific one. The beans could be obtained via a query, e.g. , but it is much easier to use standard API that is available in Java SE .  http://localhost:8080/manager/jmxproxy/?qry=java.lang%3Atype%3DMemoryPool%2C*  http://docs.oracle.com/javase/6/docs/api/java/lang/management/MemoryPoolMXBean.html I have an implementation ready and will commit it shortly. A small question is whether it is suitable for the simple "Server Status" page or is better for the "Complete Server Status" one. I think it is OK on the simple page, as this information is important.
Comment 2 Konstantin Kolinko 2014-12-02 15:14:27 UTC
Created attachment 32252 [details] 2014-12-02_tc6_54143_v1.patch Patch for Tomcat 6 Add display of memory pools. Update and fix XSL style and schema. Backport of r1409014, r1453106, r1453119, r1348992 from tomcat/tc7.0.x/trunk. <add> <bug>54143</bug>: Add display of the memory pools usage (including PermGen) to the Status page of the Manager web application. (kkolinko) </add> <fix> Fix several issues with <code>status.xsd</code> schema in Manager web application, testing it against actual output of StatusTransformer class. (kkolinko) </fix> To test the schema, one can save output of /manager/status?XML=true command and add the following attributes to the root <status> element: xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="status.xsd"