YourKit Java Profiler 7.0 Review

Like most developers, I like free software and open source software both for it’s freedom and it’s price. But once in a while there are some software you can’t avoid but to pay for. I was involved in a project recently where I had to profile some Java memory leak in a tight deadline. The code base for the project is compiled to Java 1.4 bytecode and the team uses Eclipse 3.1. I don’t know of any good profiler for Eclipse so without skipping a beat or thinking twice about it I downloaded a free 15-day trial version of YourKit Java Profiler.

It was just drop dead simple to manually enable YourKit to profile our JBoss 3.2.x based application even though we highly customized the start batch script. Once profiling is enabled, I was able to connect to our application from YourKit to have it start profiling, monitor, inspecting the leaky architecture in the application.

It took me just a few hours to get familiar with the YourKit screens and memory snapshots views. Within a day I was able to track down a ThreadLocal object that was keeping a HashMap instance that in turn collected a large hierarchy of objects in memory. Clearing the value of the ThreadLocal did the job.

YourKit Java Profiler 7.0

Again, I choose YourKit mostly because of the environment and JVM I was using. I do understand that NetBeans 5.5 has a nice profiler for Java, which I have not tried myself. I would have opted for that if I was already using NetBeans or if it was the first result when I googled ‘java profiler.’ Unfortunately I was not able to find what seemed like a good or reliable profiler for Eclipse. For this reason alone I recommended YouKit Java Profiler to my boss. Although to be completely honest, since YourKit worked so well for me I thought of just getting another trial version next time I am ever in a bind and need to profile a Java application.

Technorati Tags: , , , , , , , ,


Leave a Reply