CPU and memory profiling has never been easier and smarter at the same time with using YourKit in NetBeans IDE. YourKit Java Profiler brings new functionality to NetBeans and adds the ability to profile complex Java EE and desktop applications with just a single click. YourKit Java Profiler adds a new Profile action in all places where you usually find Run or Debug within the NetBeans environment.
After installation of the plugin, you'll see the Profile actions visible in the main toolbar:
and in the context menus of the editor:
You can profile any kind of Java application: Java SE, Java EE, WebStart, applet etc.
To configure profiling parameters in NetBeans use Tools | Options, section YourKit Profiler:
The Profile action starts the profiled application, connects to it the profiler UI (if opposite behavior is not configured). The output of the profiled application appears in the normal NetBeans output console the same as it would from the normal Run action within the environment.
To make developer's life comfortable and easier the YourKit Java Profiler provides quick navigation from profiling results right into NetBeans source editor.
Unlike other solutions that force you to tell the profiler where the source code of your application is located and then merely show the code in a feature-restricted self-made editor surrogate, YourKit provides an alternative approach. Simply select a method, class or field in the profiler UI, and then use Tools | Open in IDE (F7), to automatically open underlying source code in the NetBeans editor.