JavaMelody can monitor Java or Java EE application servers and display them in charts: Java memory and Java CPU usage, number of user sessions, number of JDBC connections, and http requests, sql requests, jsp pages and business interface methods (EJB3, Spring, Guice) execution number, average execution time, error percentage, etc. Charts can be viewed by day, week, month, year or a custom time period.
The configuration is as follows
1. Download the corresponding zip package 2. Unzip and copy javamelody.war to the Tomcat release directory 3. Add the following code to the monitored project web.xml <filter> <filter-name>monitoring</filter-name > <filter-class>net.bull.javamelody.MonitoringFilter</filter-class> </filter> <filter-mapping> <filter-name>monitoring</filter-name> <url-pattern>/*</url-pattern> </filter-mapping> <listener> <listener-class>net.bull.javamelody.SessionListener</listener-class> </listener> 4. Change javamelody.jar Copy to the LIB directory of the monitored project 5. Start the Tomcat application server and access the javamelody application, such as http://localhost:8080/javamelody6. Make the following settings according to the actual situation 7. Click the Add button