Friday, December 18, 2009

Java Melody : monitoring of JavaEE applications

I came across this tool http://code.google.com/p/javamelody/ which involves monitoring a Java/J2EE application by adding couple of JAR files and a few lines of code in web.xml. This allows us to monitor various aspects of application performance, session details, logging information etc in Testing and even Production environment. The information can be viewed in day/week/month format and also can be configured to send a weekly email report to the admin/developer about the application performance.

This does not perform any profiling or stores into database, so is considered lightweight i.e. should not degrade a lot performance-wise. ( http://groups.google.com/group/javamelody/browse_thread/thread/dfdb7101217ffcbc )

I decided to use it in my application which is a Struts based application in Test environment. I gave it a try by installing the required jars and modifying the web.xml Then I deployed the application and logged in to the application. I was not able to login due to some error. So I decided to check if the Java Melody page shows up. To access this I simply had to use http://server:9090/appname/monitoring and I was able to see the page. Then I scrolled down the different graphs to see a section Statistics System Error Log which shows me the SQL executed!!

So this gave me the error I would have otherwise searched in my log file. After fixing the error (database synonym grant issue), I played with the application and turned back to monitoring page. It gave me pretty good http and sql statistics. I also liked the way it can drill down to all SQL queries


You can check out the monitoring page at http://server:9090/appname/monitoring . You can click various graphs and also hit the Details to get more detailed information.

It can be used it to monitor application with respect to their performance, logging data etc. in real-time.

in reference to:

"monitoring of JavaEE applications"
- javamelody - Project Hosting on Google Code (view on Google Sidewiki)

2 comments:

  1. looks familiar...

    ReplyDelete
  2. Yes it was your entry and my bookmark! :-)

    ReplyDelete

Thank you for your feedback