Performance is a factor of prime importance for any software. We all want the best results from the applications that we work on .Especially the ones that we deal with on a daily basis. This is possible when we and our team work keeping this aspect in mind.
Here’s a tool that can help out Java Developers to monitor the performance of their product in a very systematic manner –JvisualVM. Yes, it’s again a product from the renowned Sun Microsystems (Comes with the latest release of the Java Platform).
Double click the utility at the following location and enter a world of you might have dreamt of while programming before.
JDK_INSTALLATION_DIRECTORY/bin/jvisualvm.exe.
The welcome screen looks like this :
Fig.1 : Welcome Screen of the JVisualVM
Now when a program runs (Shown below is a swing application), its shown as illustrated below :
Fig.2. A swing application running.
Fig.3. The swing application listed with its PID.
Double click on the icon to gather a pretty good score of information regarding the application you are running. The following snaps gives you a cool walkthrough of the same(Information is classified under tabs).
Fig.4.The Overview tab.
Fig.5.The Monitor tab.
Fig.6.The Threads tab.
The Profiler:
You have CPU and Memory options under Profiler.
CPU :
On clicking the CPU option , the following details are displayed.
Fig.7.The Profiler tab.(CPU)
Memory:
The memory button gives you the following details.
Fig.8.The Profiler tab.(Memory)
Using the stop button makes the application to stop computing these details.
You can actually run this on a client reporting performance issues, and find out where exactly the application takes time. Any part of your product causing execution overheads can be found out and tuned.
These are few aspects of the utility I came across. I am too a pioneer in this, hence, request you all to share your experiences as well. Any corrections or additions can be the best possible that can come to me at this point.
I am sure that the utility will really fascinate you by its dynamic reporting ability. As and when you execute operations on the application, the utilization is reflected and the computed statistics are updated with no need for a manual refresh. You can actually turn a java doctor doing a health check of applications. These lively graphics will keep you interested.
Pretty cool ..pretty useful …
As usual …Java Rocks!!..
There would be more than a million angles to look at a 'object suspended in space' and we happen to look at just one angle i.e from our humany eyes. Similarly, there are multiple ways to see interpret your article, so I'll restrict myself a management and commercial perspective.
ReplyDeleteNeither Macintosh nor Windows were the original GUI concepts in computers. It was invented by the guys at XEROX in a machine called as ALTO. The point I am putting is that the best of technologies need to justify their commercial application or else perish into anonymity. A sprinkling of commercial benefits or citation of convincing stastics would enable you drive home the point before management, in case you wish to get it implemented in your organisation. All in all, I really appreciate your keen interest in your keeping yourself ahead of the curve and thinking out of the box. Good Job !!! - Ravi Kishore.
ReplyDelete