The Profiling Guy
I used to be on a team that maintained a complicated web application that was leaking huge amounts of memory. Even when set to 2 gigabytes, the heap would run low on space, which slowed performance to a crawl as the garbage collector furiously ate up CPU cycles. Eventually an OutOfMemoryError would occur, which slowed performance all the way to a stop.
To diagnose the problem I ended up using JFluid, which at the time was an experimental profiling technology developed by Misha Dmitriev. I was impressed enough with JFluid that I wrote an article about it for Java Developerâ€™s Journal. After the article was put online I sent the URL to a former colleague who had worked on that complicated web application.
He sent back a one sentence response: â€œCool â€“ Iâ€™ll forward this to our profiling guy.â€ His response stopped me in my tracks: isnâ€™t everyone a profiling guy (or gal)?
I realize part of my reaction is personal preference: I enjoy making code run faster and use less memory. Not everyone, however, finds this task terribly rewarding. And on projects where resources are limited the goal of â€œget it rightâ€ must come before â€œmake it fast and efficient.â€ Frequently the â€œmake it fast and efficientâ€ task never gets started, much less completed.
But there is more at play here than personal preference and limited resources. Historically, Java profiling tools have been less than friendly. Some of them are hard to configure/use, others are underpowered, quite a few impose significant runtime overhead, and some are commercial products that are fairly expensive. JFluid, however, was different. It was easy to use, had the features I needed, provided control over the runtime overhead it imposed, and was available for free.
As a standalone tool it was perfect for someone like me who seeks out such tools. To reach a wider audience, however, profiling has to be integrated into the developerâ€™s edit-compile-debug-test workflow. Toward that end, the JFluid technology has been put into NetBeans as its profiler. Thereâ€™s even a tutorial available.
As a result, I have hope that someday everyone will be a profiling guy (or gal).